]> git.baikalelectronics.ru Git - kernel.git/commit
fdt: Update CRC check for rng-seed
authorHsin-Yi Wang <hsinyi@chromium.org>
Tue, 27 Aug 2019 10:33:53 +0000 (18:33 +0800)
committerWill Deacon <will@kernel.org>
Tue, 27 Aug 2019 11:27:07 +0000 (12:27 +0100)
commit1e61835821ddbbe2148c45308f2d5b1492e7268c
tree40ea14a72f4888128dd8b31133e8db566e94f2a2
parent7ef33fdf009868933f291f25d7327a3f8aee187c
fdt: Update CRC check for rng-seed

Commit ae6988528d6c ("fdt: add support for rng-seed") moves of_fdt_crc32
from early_init_dt_verify() to early_init_dt_scan() since
early_init_dt_scan_chosen() may modify fdt to erase rng-seed.

However, arm and some other arch won't call early_init_dt_scan(), they
call early_init_dt_verify() then early_init_dt_scan_nodes().

Restore of_fdt_crc32 to early_init_dt_verify() then update it in
early_init_dt_scan_chosen() if fdt if updated.

Fixes: ae6988528d6c ("fdt: add support for rng-seed")
Reported-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Hsin-Yi Wang <hsinyi@chromium.org>
Tested-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Will Deacon <will@kernel.org>
drivers/of/fdt.c