diff options
author | Josh Cartwright <joshc@codeaurora.org> | 2014-03-13 17:36:36 -0400 |
---|---|---|
committer | Grant Likely <grant.likely@linaro.org> | 2014-03-15 08:38:22 -0400 |
commit | 2040b52768ebab6e7bd73af0dc63703269c62f17 (patch) | |
tree | 3f9600db68fc26ef56b775956d7fbe1c7d4b8aa9 /drivers/of/fdt.c | |
parent | 708b7eef12f945a510ba5ac3b4007d7ae4796d55 (diff) |
of: only scan for reserved mem when fdt present
When the reserved memory patches hit -next, several legacy (non-DT) boot
failures were detected and bisected down to that commit. There needs to
be some sanity checking whether a DT is even present before parsing the
reserved ranges.
Reported-by: Kevin Hilman <khilman@linaro.org>
Signed-off-by: Josh Cartwright <joshc@codeaurora.org>
Tested-by: Kevin Hilman <khilman@linaro.org>
Signed-off-by: Grant Likely <grant.likely@linaro.org>
Diffstat (limited to 'drivers/of/fdt.c')
-rw-r--r-- | drivers/of/fdt.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/of/fdt.c b/drivers/of/fdt.c index 510c0d8de8a0..501bc83f8cdf 100644 --- a/drivers/of/fdt.c +++ b/drivers/of/fdt.c | |||
@@ -557,6 +557,9 @@ static int __init __fdt_scan_reserved_mem(unsigned long node, const char *uname, | |||
557 | */ | 557 | */ |
558 | void __init early_init_fdt_scan_reserved_mem(void) | 558 | void __init early_init_fdt_scan_reserved_mem(void) |
559 | { | 559 | { |
560 | if (!initial_boot_params) | ||
561 | return; | ||
562 | |||
560 | of_scan_flat_dt(__fdt_scan_reserved_mem, NULL); | 563 | of_scan_flat_dt(__fdt_scan_reserved_mem, NULL); |
561 | fdt_init_reserved_mem(); | 564 | fdt_init_reserved_mem(); |
562 | } | 565 | } |