diff options
author | Masahiro Yamada <yamada.masahiro@socionext.com> | 2018-07-19 16:28:24 +0900 |
---|---|---|
committer | Masahiro Yamada <yamada.masahiro@socionext.com> | 2018-07-25 08:47:53 +0900 |
commit | e9687153027f4e1adbe17d6bd9da381c23235061 (patch) | |
tree | eebc1690a877d0b998e6bef6a4de39ec7f6f6085 /arch | |
parent | b35fb6ace67202b6f668f744f958a5ef66665151 (diff) |
ARM: uniphier: clean-up ft_board_setup()
The 'bd' is passed in ft_board_setup() as the second argument.
Replace 'gd->bd' with 'bd'.
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/mach-uniphier/dram_init.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/arm/mach-uniphier/dram_init.c b/arch/arm/mach-uniphier/dram_init.c index 2eb4836256..8aa3f81cfc 100644 --- a/arch/arm/mach-uniphier/dram_init.c +++ b/arch/arm/mach-uniphier/dram_init.c @@ -279,11 +279,11 @@ int ft_board_setup(void *fdt, bd_t *bd) if (uniphier_get_soc_id() != UNIPHIER_LD20_ID) return 0; - for (i = 0; i < ARRAY_SIZE(gd->bd->bi_dram); i++) { - if (!gd->bd->bi_dram[i].size) + for (i = 0; i < ARRAY_SIZE(bd->bi_dram); i++) { + if (!bd->bi_dram[i].size) continue; - rsv_addr = gd->bd->bi_dram[i].start + gd->bd->bi_dram[i].size; + rsv_addr = bd->bi_dram[i].start + bd->bi_dram[i].size; rsv_addr -= rsv_size; ret = fdt_add_mem_rsv(fdt, rsv_addr, rsv_size); |