]> git.baikalelectronics.ru Git - uboot.git/commit
xilinx: common: change bootm_size to not go beyond ram_top
authorRicardo Salveti <ricardo@foundries.io>
Thu, 20 Jan 2022 19:17:30 +0000 (16:17 -0300)
committerMichal Simek <michal.simek@xilinx.com>
Tue, 1 Feb 2022 16:11:33 +0000 (17:11 +0100)
commit14dbf73d488034481ca313028ffb750baeef2fab
tree4bf9defb3491bf0e8455fb7f8ec79c2081c6221a
parent7dfd59c568c2e78703ca2b8ac64851694ec5ca8e
xilinx: common: change bootm_size to not go beyond ram_top

The available ram can be limited by ram_top as that depends on the
reserved memory nodes provided by the device-tree (via
board_get_usable_ram_top), so make sure to respect ram_top when setting
up bootm_size to avoid overlapping reserved memory regions (e.g. memory
used by OP-TEE).

The same logic is available in env_get_bootm_size when bootm_size is
not defined by the default environment.

Signed-off-by: Ricardo Salveti <ricardo@foundries.io>
Link: https://lore.kernel.org/r/20220120191730.2009270-1-ricardo@foundries.io
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
board/xilinx/common/board.c