summaryrefslogtreecommitdiffstats
path: root/meta-xilinx-core
diff options
context:
space:
mode:
authorSandeep Gundlupet Raju <sandeep.gundlupet-raju@amd.com>2024-10-05 22:41:53 -0600
committerMark Hatle <mark.hatle@amd.com>2024-10-09 08:34:47 -0500
commit7bfb30fb0312e400931c8df675bef357fcae925d (patch)
tree2ff4d410668788d9360dd34ada175823cf2f13c4 /meta-xilinx-core
parent362515c4087f7f60804dcbde2806ef6e17a7c32f (diff)
downloadmeta-xilinx-7bfb30fb0312e400931c8df675bef357fcae925d.tar.gz
device-tree.bb: Rename EXTRA_OVERLAYS to EXTRA_DT_INCLUDE_FILES
Rename EXTRA_OVERLAYS to EXTRA_DT_INCLUDE_FILES as these variables add extra files to DT_FILES_PATH and add a #include for each to the BASE_DTS, it access 1..n dtsi files and adds to SRC_URI. Signed-off-by: Sandeep Gundlupet Raju <sandeep.gundlupet-raju@amd.com> Signed-off-by: Mark Hatle <mark.hatle@amd.com>
Diffstat (limited to 'meta-xilinx-core')
-rw-r--r--meta-xilinx-core/recipes-bsp/device-tree/device-tree.bb16
1 files changed, 8 insertions, 8 deletions
diff --git a/meta-xilinx-core/recipes-bsp/device-tree/device-tree.bb b/meta-xilinx-core/recipes-bsp/device-tree/device-tree.bb
index 970fa171..fbe85f96 100644
--- a/meta-xilinx-core/recipes-bsp/device-tree/device-tree.bb
+++ b/meta-xilinx-core/recipes-bsp/device-tree/device-tree.bb
@@ -34,12 +34,12 @@ EXTRA_DTFILES_BUNDLE ?= ""
34UBOOT_DT_FILES ?= "" 34UBOOT_DT_FILES ?= ""
35UBOOT_DTFILE_PREFIX ?= "system-top" 35UBOOT_DTFILE_PREFIX ?= "system-top"
36UBOOT_DTFILES_BUNDLE ?= "" 36UBOOT_DTFILES_BUNDLE ?= ""
37EXTRA_OVERLAYS ?= "" 37EXTRA_DT_INCLUDE_FILES ?= ""
38 38
39SYSTEM_DTFILE[doc] = "System Device Tree which accepts at 0...1 dts file" 39SYSTEM_DTFILE[doc] = "System Device Tree which accepts at 0...1 dts file"
40CONFIG_DTFILE[doc] = "Domain Specific Device Tree which accepts 0...1 dts file" 40CONFIG_DTFILE[doc] = "Domain Specific Device Tree which accepts 0...1 dts file"
41EXTRA_DT_FILES[doc] = "Add extra files to DT_FILES_PATH, it accepts 1...n dtsi files and adds to SRC_URI" 41EXTRA_DT_FILES[doc] = "Add extra files to DT_FILES_PATH, it accepts 1...n dtsi files and adds to SRC_URI"
42EXTRA_OVERLAYS[doc] = "Add extra files to DT_FILES_PATH and adds a #include for each to the BASE_DTS, it access 1..n dtsi files and adds to SRC_URI" 42EXTRA_DT_INCLUDE_FILES[doc] = "Add extra files to DT_FILES_PATH and adds a #include for each to the BASE_DTS, it access 1..n dtsi files and adds to SRC_URI"
43 43
44# There should only be ONE CONFIG_DTFILE listed 44# There should only be ONE CONFIG_DTFILE listed
45# These need to be passed in from global, not from a bbappend 45# These need to be passed in from global, not from a bbappend
@@ -47,7 +47,7 @@ FILESEXTRAPATHS:prepend := "${@'%s:' % os.path.dirname(d.getVar('CONFIG_DTFILE')
47SRC_URI:append := " ${@'file://%s' % os.path.basename(d.getVar('CONFIG_DTFILE') or '') if (d.getVar('CONFIG_DTFILE')) else ''}" 47SRC_URI:append := " ${@'file://%s' % os.path.basename(d.getVar('CONFIG_DTFILE') or '') if (d.getVar('CONFIG_DTFILE')) else ''}"
48 48
49SRC_URI:append = " ${@" ".join(["file://%s" % f for f in (d.getVar('EXTRA_DT_FILES') or "").split()])}" 49SRC_URI:append = " ${@" ".join(["file://%s" % f for f in (d.getVar('EXTRA_DT_FILES') or "").split()])}"
50SRC_URI:append = " ${@" ".join(["file://%s" % f for f in (d.getVar('EXTRA_OVERLAYS') or "").split()])}" 50SRC_URI:append = " ${@" ".join(["file://%s" % f for f in (d.getVar('EXTRA_DT_INCLUDE_FILES') or "").split()])}"
51 51
52COMPATIBLE_MACHINE:zynq = ".*" 52COMPATIBLE_MACHINE:zynq = ".*"
53COMPATIBLE_MACHINE:zynqmp = ".*" 53COMPATIBLE_MACHINE:zynqmp = ".*"
@@ -65,7 +65,7 @@ DTB_FILE_NAME ?= "${BASE_DTS}.dtb"
65 65
66DTB_BASE_NAME ?= "${MACHINE}-system${IMAGE_VERSION_SUFFIX}" 66DTB_BASE_NAME ?= "${MACHINE}-system${IMAGE_VERSION_SUFFIX}"
67 67
68# Copy the EXTRA_DT_FILES and EXTRA_OVERLAYS files in prepend operation so that 68# Copy the EXTRA_DT_FILES and EXTRA_DT_INCLUDE_FILES files in prepend operation so that
69# it can be preprocessed. 69# it can be preprocessed.
70do_configure:prepend () { 70do_configure:prepend () {
71 # Create DT_FILES_PATH directory if doesn't exist during prepend operation. 71 # Create DT_FILES_PATH directory if doesn't exist during prepend operation.
@@ -73,7 +73,7 @@ do_configure:prepend () {
73 mkdir -p ${DT_FILES_PATH} 73 mkdir -p ${DT_FILES_PATH}
74 fi 74 fi
75 75
76 for f in ${EXTRA_DT_FILES} ${EXTRA_OVERLAYS}; do 76 for f in ${EXTRA_DT_FILES} ${EXTRA_DT_INCLUDE_FILES}; do
77 if [ "$(realpath ${WORKDIR}/${f})" != "$(realpath ${DT_FILES_PATH}/`basename ${f}`)" ]; then 77 if [ "$(realpath ${WORKDIR}/${f})" != "$(realpath ${DT_FILES_PATH}/`basename ${f}`)" ]; then
78 cp ${WORKDIR}/${f} ${DT_FILES_PATH}/ 78 cp ${WORKDIR}/${f} ${DT_FILES_PATH}/
79 fi 79 fi
@@ -81,12 +81,12 @@ do_configure:prepend () {
81} 81}
82 82
83do_configure:append () { 83do_configure:append () {
84 for f in ${EXTRA_OVERLAYS}; do 84 for f in ${EXTRA_DT_INCLUDE_FILES}; do
85 if [ ! -e ${DT_FILES_PATH}/${BASE_DTS}.dts ]; then 85 if [ ! -e ${DT_FILES_PATH}/${BASE_DTS}.dts ]; then
86 if [ -e ${DT_FILES_PATH}/${BASE_DTS}.dtb ]; then 86 if [ -e ${DT_FILES_PATH}/${BASE_DTS}.dtb ]; then
87 bberror "Unable to find ${BASE_DTS}.dts, to use EXTRA_OVERLAYS you must use a 'dts' and not 'dtb' in CONFIG_DTFILE" 87 bberror "Unable to find ${BASE_DTS}.dts, to use EXTRA_DT_INCLUDE_FILES you must use a 'dts' and not 'dtb' in CONFIG_DTFILE"
88 else 88 else
89 bberror "Unable to find ${BASE_DTS}.dts, to use EXTRA_OVERLAYS you must set a valid CONFIG_DTFILE or use system-top.dts" 89 bberror "Unable to find ${BASE_DTS}.dts, to use EXTRA_DT_INCLUDE_FILES you must set a valid CONFIG_DTFILE or use system-top.dts"
90 fi 90 fi
91 exit 1 91 exit 1
92 fi 92 fi