diff options
| author | Alex Kiernan <alex.kiernan@gmail.com> | 2018-06-16 09:28:52 +0000 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2018-06-18 11:07:57 +0100 |
| commit | 430774e4596290307e9452fcf2ce97da48632e9f (patch) | |
| tree | 760afca9d6a5cab575c9a8d423d410c45536c37a | |
| parent | 3c3545ec78f27868551e6add048e0373eebc5a20 (diff) | |
| download | poky-430774e4596290307e9452fcf2ce97da48632e9f.tar.gz | |
kernel-fitimage: Allow setting of DTB/DTBO relocation address
Introduce UBOOT_DTB_LOADADDRESS and UBOOT_DTBO_LOADADDRESS so that you
can set where U-Boot loads full and overlay DTBs. This is required when
using bootm's overlay support to construct the final DTB.
(From OE-Core rev: 05d2230db1d7379494814407fc0d79d7e755d89e)
Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
| -rw-r--r-- | meta/classes/kernel-fitimage.bbclass | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/meta/classes/kernel-fitimage.bbclass b/meta/classes/kernel-fitimage.bbclass index 50a91e1990..f3c2ff0a30 100644 --- a/meta/classes/kernel-fitimage.bbclass +++ b/meta/classes/kernel-fitimage.bbclass | |||
| @@ -135,6 +135,15 @@ fitimage_emit_section_dtb() { | |||
| 135 | 135 | ||
| 136 | dtb_csum="sha1" | 136 | dtb_csum="sha1" |
| 137 | 137 | ||
| 138 | dtb_loadline="" | ||
| 139 | dtb_ext=${DTB##*.} | ||
| 140 | if [ "${dtb_ext}" = "dtbo" ]; then | ||
| 141 | if [ -n "${UBOOT_DTBO_LOADADDRESS}" ]; then | ||
| 142 | dtb_loadline="load = <${UBOOT_DTBO_LOADADDRESS}>;" | ||
| 143 | fi | ||
| 144 | elif [ -n "${UBOOT_DTB_LOADADDRESS}" ]; then | ||
| 145 | dtb_loadline="load = <${UBOOT_DTB_LOADADDRESS}>;" | ||
| 146 | fi | ||
| 138 | cat << EOF >> ${1} | 147 | cat << EOF >> ${1} |
| 139 | fdt@${2} { | 148 | fdt@${2} { |
| 140 | description = "Flattened Device Tree blob"; | 149 | description = "Flattened Device Tree blob"; |
| @@ -142,6 +151,7 @@ fitimage_emit_section_dtb() { | |||
| 142 | type = "flat_dt"; | 151 | type = "flat_dt"; |
| 143 | arch = "${UBOOT_ARCH}"; | 152 | arch = "${UBOOT_ARCH}"; |
| 144 | compression = "none"; | 153 | compression = "none"; |
| 154 | ${dtb_loadline} | ||
| 145 | hash@1 { | 155 | hash@1 { |
| 146 | algo = "${dtb_csum}"; | 156 | algo = "${dtb_csum}"; |
| 147 | }; | 157 | }; |
