summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSandeep Gundlupet Raju <sandeep.gundlupet-raju@amd.com>2023-08-18 16:48:50 -0600
committerMark Hatle <mark.hatle@amd.com>2023-08-19 19:21:18 -0500
commitd9d1860dcd94a03ce3398cbd6fc7a71847204b18 (patch)
tree83e9110362ba34b40d749d54973ccfabced59e3a
parentc4f4cbc48ee3acb770788bd0b38a84a72e6cd44f (diff)
downloadmeta-xilinx-d9d1860dcd94a03ce3398cbd6fc7a71847204b18.tar.gz
u-boot-xlnx-scr: Refactor boot scr variables to make it easier to override
With the previous version by default xen variables are included in non xen use case, it would have been possible for kernel and devicetree offset can be override from meta-virtualization layer. With the new version add variables as addendum. Signed-off-by: Sandeep Gundlupet Raju <sandeep.gundlupet-raju@amd.com> Signed-off-by: Mark Hatle <mark.hatle@amd.com>
-rw-r--r--meta-xilinx-core/recipes-bsp/u-boot/u-boot-xlnx-scr.bb18
1 files changed, 3 insertions, 15 deletions
diff --git a/meta-xilinx-core/recipes-bsp/u-boot/u-boot-xlnx-scr.bb b/meta-xilinx-core/recipes-bsp/u-boot/u-boot-xlnx-scr.bb
index 5fe663d2..6410fc25 100644
--- a/meta-xilinx-core/recipes-bsp/u-boot/u-boot-xlnx-scr.bb
+++ b/meta-xilinx-core/recipes-bsp/u-boot/u-boot-xlnx-scr.bb
@@ -169,14 +169,8 @@ NAND_FIT_IMAGE_OFFSET ??= "0x4180000"
169NAND_FIT_IMAGE_OFFSET:zynq ??= "0x1080000" 169NAND_FIT_IMAGE_OFFSET:zynq ??= "0x1080000"
170NAND_FIT_IMAGE_SIZE ??= "0x6400000" 170NAND_FIT_IMAGE_SIZE ??= "0x6400000"
171 171
172# Xen boot script variables. Define here and set it from meta-virtualization 172# Add variables as addendum.
173XEN_OFFSET ??= "0xBA00000" 173SCRIPT_SED_ADDENDUM = ""
174XEN_LOAD_ADDRESS ?= "${@append_baseaddr(d,d.getVar('XEN_OFFSET'))}"
175XEN_IMAGE_NAME ??= "xen"
176DOM0_MEM ??= "1500M"
177XEN_SERIAL_CONSOLES ??= "serial0"
178XEN_CMDLINE_APPEND ??= ""
179DOM0_MAX_VCPUS ??= "1"
180 174
181# Default to booting with the rootfs device being partition 2 for SD/eMMC 175# Default to booting with the rootfs device being partition 2 for SD/eMMC
182PARTNUM ?= "2" 176PARTNUM ?= "2"
@@ -254,13 +248,7 @@ do_compile() {
254 -e 's:@@KERNEL_ROOT_SD@@:${KERNEL_ROOT_SD}:' \ 248 -e 's:@@KERNEL_ROOT_SD@@:${KERNEL_ROOT_SD}:' \
255 -e 's:@@KERNEL_ROOT_RAMDISK@@:${KERNEL_ROOT_RAMDISK}:' \ 249 -e 's:@@KERNEL_ROOT_RAMDISK@@:${KERNEL_ROOT_RAMDISK}:' \
256 -e 's:@@KERNEL_COMMAND_APPEND@@:${KERNEL_COMMAND_APPEND}:' \ 250 -e 's:@@KERNEL_COMMAND_APPEND@@:${KERNEL_COMMAND_APPEND}:' \
257 -e 's/@@XEN_IMAGE_NAME@@/${XEN_IMAGE_NAME}/' \ 251 ${SCRIPT_SED_ADDENDUM} \
258 -e 's/@@XEN_OFFSET@@/${XEN_OFFSET}/' \
259 -e 's/@@XEN_LOAD_ADDRESS@@/${XEN_LOAD_ADDRESS}/' \
260 -e 's/@@DOM0_MEM@@/${DOM0_MEM}/' \
261 -e 's/@@DOM0_MAX_VCPUS@@/${DOM0_MAX_VCPUS}/' \
262 -e 's:@@XEN_SERIAL_CONSOLES@@:${XEN_SERIAL_CONSOLES}:' \
263 -e 's:@@XEN_CMDLINE_APPEND@@:${XEN_CMDLINE_APPEND}:' \
264 "${WORKDIR}/boot.cmd.${BOOTMODE}${BOOTFILE_EXT}" > "${WORKDIR}/boot.cmd" 252 "${WORKDIR}/boot.cmd.${BOOTMODE}${BOOTFILE_EXT}" > "${WORKDIR}/boot.cmd"
265 253
266 mkimage -A arm -T script -C none -n "Boot script" -d "${WORKDIR}/boot.cmd" boot.scr 254 mkimage -A arm -T script -C none -n "Boot script" -d "${WORKDIR}/boot.cmd" boot.scr