diff options
Diffstat (limited to 'common')
-rw-r--r-- | common/fdt_support.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/common/fdt_support.c b/common/fdt_support.c index bd0478d..b148536 100644 --- a/common/fdt_support.c +++ b/common/fdt_support.c @@ -447,6 +447,13 @@ int fdt_fixup_memory_banks(void *blob, u64 start[], u64 size[], int banks) return err; } + for (i = 0; i < banks; i++) { + if (start[i] == 0 && size[i] == 0) + break; + } + + banks = i; + if (!banks) return 0; |