bdinfo: Don't print out empty DRAM banks
There is no sense in printing out DRAM banks of size 0 since this means they are empty. Skip them. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
This commit is contained in:
parent
c2147e26d9
commit
ddd917b8fa
@ -98,9 +98,11 @@ static inline void print_bi_dram(const bd_t *bd)
|
||||
int i;
|
||||
|
||||
for (i = 0; i < CONFIG_NR_DRAM_BANKS; ++i) {
|
||||
print_num("DRAM bank", i);
|
||||
print_num("-> start", bd->bi_dram[i].start);
|
||||
print_num("-> size", bd->bi_dram[i].size);
|
||||
if (bd->bi_dram[i].size) {
|
||||
print_num("DRAM bank", i);
|
||||
print_num("-> start", bd->bi_dram[i].start);
|
||||
print_num("-> size", bd->bi_dram[i].size);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user