[PATCH v8 00/10] Remove CONFIG_NR_DRAM_BANKS option and bi_memstart/memsize from bd_info

Stefan Roese sr at denx.de
Mon Aug 24 12:59:41 CEST 2020


This patchset is an extension of the previous single patch
"CONFIG_NR_DRAM_BANKS: Remove unreferenced code as its always defined".
With a split into separate patches, its hopefully easier to understand,
what is changed.

The earlier patch versions tried a simple search and replace of the
bi_memstart / bi_memsize values with bi_dram[].start/.size. This did
not work. This patchset now removes some of the assignments and changes
in most cases to gd->ram_base/ram_size instead, which seems a better
choice.

Successful Azure build report:
https://dev.azure.com/sr0718/u-boot/_build/results?buildId=39

Thanks,
Stefan

Changes in v8:
- Add Reviewed-by tag from Bin
- Rebased on latest TOT
- Add Reviewed-by tag from Simon
- Add Reviewed-by tag from Simon
- Add Reviewed-by tag from Simon
- Add Reviewed-by tag from Simon
- Add Reviewed-by tag from Simon

Changes in v7:
- Add Reviewe-by tag from Ovidiu
- Reword commit text as suggested by Wolfgang
- Add Reviewe-by tag from Ovidiu
- Add Reviewe-by tag from Ovidiu
- Add Reviewe-by tag from Ovidiu

Changes in v6:
- Simplify dram_init_banksize() even more as suggested by Daniel

Changes in v5:
- Add Reviewed-by tag from Pali & Andy
- Move "bd" assignment as suggested by Andy
- Use PHYSADDR() for xtensa, as the bi_memstart value was originally
  defined this way
- New patch to fix the failing "test.py xtfpga" CI test
- Add Tested-by tag from Oleksandr & Michael

Changes in v4:
- Only remove dead code with CONFIG_NR_DRAM_BANKS always defined
- New patch
- New patch
- New patch
- New patch
- New patch
- New patch
- New patch
- New patch

Stefan Roese (10):
  CONFIG_NR_DRAM_BANKS: Remove unreferenced code as its always defined
  image: Use gd->ram_base/_size in env_get_bootm_size()
  board_f: Add default values for bi_dram[] in dram_init_banksize()
  global: Move from bi_memstart/memsize -> gd->ram_base/ram_size
  xtensa: Remove arch_setup_bdinfo()
  xtensa: Remove local no-op dram_init_banksize()
  video: cfb_console.c: Use bi_dram[] values on all platforms
  powerpc: Remove bi_memstart & bi_memsize assignments in spl.c
  cmd: bdinfo: Remove print of superseeded bi_memstart / bi_memsize
    values
  asm-generic/u-boot.h: Remove bi_memstart & bi_memsize from bd_info

 api/api_platform-mips.c               |  3 +--
 api/api_platform-powerpc.c            |  2 +-
 arch/mips/lib/boot.c                  |  2 +-
 arch/mips/lib/bootm.c                 |  2 +-
 arch/powerpc/cpu/mpc83xx/fdt.c        |  2 +-
 arch/powerpc/cpu/mpc83xx/traps.c      |  2 +-
 arch/powerpc/cpu/mpc85xx/fdt.c        |  4 ++--
 arch/powerpc/cpu/mpc85xx/traps.c      |  2 +-
 arch/powerpc/cpu/mpc86xx/fdt.c        |  4 +++-
 arch/powerpc/cpu/mpc86xx/traps.c      |  2 +-
 arch/powerpc/cpu/mpc8xx/fdt.c         |  2 +-
 arch/powerpc/lib/bootm.c              |  4 ++--
 arch/x86/cpu/broadwell/cpu_from_spl.c |  2 --
 arch/xtensa/lib/Makefile              |  2 +-
 arch/xtensa/lib/bdinfo.c              | 22 ------------------
 arch/xtensa/lib/bootm.c               |  5 ++--
 board/Arcturus/ucp1020/spl.c          |  2 --
 board/cadence/xtfpga/xtfpga.c         |  5 ----
 board/freescale/p1010rdb/spl.c        |  2 --
 board/freescale/p1_p2_rdb_pc/spl.c    |  2 --
 board/freescale/t102xrdb/spl.c        |  2 --
 board/freescale/t104xrdb/spl.c        |  2 --
 board/freescale/t208xqds/spl.c        |  2 --
 board/freescale/t208xrdb/spl.c        |  2 --
 board/freescale/t4rdb/spl.c           |  2 --
 board/xilinx/zynqmp/zynqmp.c          |  2 --
 cmd/bdinfo.c                          | 10 --------
 cmd/bedbug.c                          |  2 +-
 common/board_f.c                      | 12 +---------
 common/image.c                        | 10 ++------
 common/init/handoff.c                 | 33 +++++++++++----------------
 drivers/pci/pci-uclass.c              | 18 ++-------------
 drivers/video/cfb_console.c           |  8 +------
 include/asm-generic/u-boot.h          |  4 ----
 include/handoff.h                     |  2 --
 lib/fdtdec.c                          |  5 ----
 lib/lmb.c                             |  9 ++------
 37 files changed, 41 insertions(+), 157 deletions(-)
 delete mode 100644 arch/xtensa/lib/bdinfo.c

-- 
2.28.0



More information about the U-Boot mailing list