diff options
author | Denys Dmytriyenko <denys@ti.com> | 2017-02-02 04:04:06 +0000 |
---|---|---|
committer | Denys Dmytriyenko <denys@ti.com> | 2017-02-02 18:34:37 -0500 |
commit | 5021fec8b9799a805c9c3bdad30d34f99c97aeb8 (patch) | |
tree | f27349f44fce307c14cb69c19191af58c6033fd5 /recipes-bsp/u-boot | |
parent | 06b068fb14d7d24dca57a58cbe6b8dfde7bd59c8 (diff) | |
download | meta-ti-5021fec8b9799a805c9c3bdad30d34f99c97aeb8.tar.gz |
u-boot: move common settings and code to u-boot-ti.inc
Signed-off-by: Denys Dmytriyenko <denys@ti.com>
Diffstat (limited to 'recipes-bsp/u-boot')
-rw-r--r-- | recipes-bsp/u-boot/u-boot-ti-staging_2016.05.bb | 108 | ||||
-rw-r--r-- | recipes-bsp/u-boot/u-boot-ti.inc | 126 |
2 files changed, 113 insertions, 121 deletions
diff --git a/recipes-bsp/u-boot/u-boot-ti-staging_2016.05.bb b/recipes-bsp/u-boot/u-boot-ti-staging_2016.05.bb index 4998d685..fa15569f 100644 --- a/recipes-bsp/u-boot/u-boot-ti-staging_2016.05.bb +++ b/recipes-bsp/u-boot/u-boot-ti-staging_2016.05.bb | |||
@@ -1,113 +1,7 @@ | |||
1 | require u-boot-ti.inc | 1 | require u-boot-ti.inc |
2 | 2 | ||
3 | # u-boot needs devtree compiler to parse dts files | ||
4 | DEPENDS += "dtc-native" | ||
5 | |||
6 | DESCRIPTION = "u-boot bootloader for TI devices" | ||
7 | |||
8 | LIC_FILES_CHKSUM = "file://Licenses/README;md5=a2c678cfd4a4d97135585cad908541c6" | ||
9 | |||
10 | PR = "r30" | 3 | PR = "r30" |
11 | PV_append = "+git${SRCPV}" | ||
12 | 4 | ||
13 | SRC_URI = "git://git.ti.com/ti-u-boot/ti-u-boot.git;protocol=git;branch=${BRANCH}" | 5 | BRANCH = "ti-u-boot-2016.05" |
14 | |||
15 | BRANCH ?= "ti-u-boot-2016.05" | ||
16 | 6 | ||
17 | SRCREV = "4db46a6bbde46e4587b77e14763787f66c292701" | 7 | SRCREV = "4db46a6bbde46e4587b77e14763787f66c292701" |
18 | |||
19 | # Support for secure devices - detailed info is in doc/README.ti-secure | ||
20 | TI_SECURE_DEV_PKG ?= "" | ||
21 | export TI_SECURE_DEV_PKG | ||
22 | |||
23 | SPL_BINARY = "MLO" | ||
24 | SPL_BINARY_k2e-hs-evm = "" | ||
25 | SPL_UART_BINARY = "u-boot-spl.bin" | ||
26 | |||
27 | # Keystone specifics | ||
28 | UBOOT_SUFFIX_keystone = "bin" | ||
29 | SPL_UART_BINARY_keystone = "" | ||
30 | |||
31 | # SPI NOR Flash binaries | ||
32 | UBOOT_SPI_SPL_BINARY = "u-boot-spl.bin" | ||
33 | UBOOT_SPI_BINARY = "u-boot.img" | ||
34 | UBOOT_SPI_GPH_BINARY = "u-boot-spi.gph" | ||
35 | |||
36 | # SPI NOR Flash deployed images | ||
37 | UBOOT_SPI_SPL_IMAGE = "u-boot-spl-${MACHINE}-${PV}-${PR}.bin" | ||
38 | UBOOT_SPI_SPL_SYMLINK = "u-boot-spl-${MACHINE}.bin" | ||
39 | UBOOT_SPI_IMAGE = "u-boot-${MACHINE}-${PV}-${PR}.img" | ||
40 | UBOOT_SPI_SYMLINK = "u-boot-${MACHINE}.img" | ||
41 | UBOOT_SPI_GPH_IMAGE = "u-boot-spi-${MACHINE}-${PV}-${PR}.gph" | ||
42 | UBOOT_SPI_GPH_SYMLINK = "u-boot-spi-${MACHINE}.gph" | ||
43 | |||
44 | # HS XLD | ||
45 | UBOOT_HS_XLD_BINARY = "u-boot-spl_HS_X-LOADER" | ||
46 | UBOOT_HS_XLD_IMAGE = "u-boot-spl_HS_X-LOADER-${MACHINE}-${PV}-${PR}" | ||
47 | UBOOT_HS_XLD_SYMLINK = "u-boot-spl_HS_X-LOADER-${MACHINE}" | ||
48 | |||
49 | # HS MLO | ||
50 | UBOOT_HS_MLO_BINARY = "u-boot_HS_MLO" | ||
51 | UBOOT_HS_MLO_IMAGE = "u-boot_HS_MLO-${MACHINE}-${PV}-${PR}" | ||
52 | UBOOT_HS_MLO_SYMLINK = "u-boot_HS_MLO-${MACHINE}" | ||
53 | |||
54 | do_compile_append_am437x-hs-evm () { | ||
55 | if [ -f ${B}/u-boot-spl_HS_ISSW ]; then | ||
56 | rm -rf ${B}/MLO | ||
57 | cp ${B}/u-boot-spl_HS_ISSW ${B}/MLO | ||
58 | fi | ||
59 | } | ||
60 | |||
61 | do_install_append () { | ||
62 | if [ -f ${B}/${UBOOT_HS_XLD_BINARY} ]; then | ||
63 | install ${B}/${UBOOT_HS_XLD_BINARY} ${D}/boot/${UBOOT_HS_XLD_IMAGE} | ||
64 | ln -sf ${UBOOT_HS_XLD_IMAGE} ${D}/boot/${UBOOT_HS_XLD_BINARY} | ||
65 | fi | ||
66 | if [ -f ${B}/${UBOOT_HS_MLO_BINARY} ]; then | ||
67 | install ${B}/${UBOOT_HS_MLO_BINARY} ${D}/boot/${UBOOT_HS_MLO_IMAGE} | ||
68 | ln -sf ${UBOOT_HS_MLO_IMAGE} ${D}/boot/${UBOOT_HS_MLO_BINARY} | ||
69 | fi | ||
70 | } | ||
71 | |||
72 | do_deploy_append () { | ||
73 | if [ -f ${B}/${UBOOT_HS_XLD_BINARY} ]; then | ||
74 | install ${B}/${UBOOT_HS_XLD_BINARY} ${DEPLOYDIR}/${UBOOT_HS_XLD_IMAGE} | ||
75 | rm -f ${UBOOT_HS_XLD_BINARY} ${UBOOT_HS_XLD_SYMLINK} | ||
76 | ln -sf ${UBOOT_HS_XLD_IMAGE} ${UBOOT_HS_XLD_SYMLINK} | ||
77 | ln -sf ${UBOOT_HS_XLD_IMAGE} ${UBOOT_HS_XLD_BINARY} | ||
78 | fi | ||
79 | if [ -f ${B}/${UBOOT_HS_MLO_BINARY} ]; then | ||
80 | install ${B}/${UBOOT_HS_MLO_BINARY} ${DEPLOYDIR}/${UBOOT_HS_MLO_IMAGE} | ||
81 | rm -f ${UBOOT_HS_MLO_BINARY} ${UBOOT_HS_MLO_SYMLINK} | ||
82 | ln -sf ${UBOOT_HS_MLO_IMAGE} ${UBOOT_HS_MLO_SYMLINK} | ||
83 | ln -sf ${UBOOT_HS_MLO_IMAGE} ${UBOOT_HS_MLO_BINARY} | ||
84 | fi | ||
85 | } | ||
86 | |||
87 | do_install_append_keystone () { | ||
88 | install ${B}/spl/${UBOOT_SPI_SPL_BINARY} ${D}/boot/${UBOOT_SPI_SPL_IMAGE} | ||
89 | ln -sf ${UBOOT_SPI_SPL_IMAGE} ${D}/boot/${UBOOT_SPI_SPL_BINARY} | ||
90 | |||
91 | install ${B}/${UBOOT_SPI_BINARY} ${D}/boot/${UBOOT_SPI_IMAGE} | ||
92 | ln -sf ${UBOOT_SPI_IMAGE} ${D}/boot/${UBOOT_SPI_BINARY} | ||
93 | |||
94 | install ${B}/${UBOOT_SPI_GPH_BINARY} ${D}/boot/${UBOOT_SPI_GPH_IMAGE} | ||
95 | ln -sf ${UBOOT_SPI_GPH_IMAGE} ${D}/boot/${UBOOT_SPI_GPH_BINARY} | ||
96 | } | ||
97 | |||
98 | do_deploy_append_keystone () { | ||
99 | install ${B}/spl/${UBOOT_SPI_SPL_BINARY} ${DEPLOYDIR}/${UBOOT_SPI_SPL_IMAGE} | ||
100 | rm -f ${UBOOT_SPI_SPL_BINARY} ${UBOOT_SPI_SPL_SYMLINK} | ||
101 | ln -sf ${UBOOT_SPI_SPL_IMAGE} ${UBOOT_SPI_SPL_SYMLINK} | ||
102 | ln -sf ${UBOOT_SPI_SPL_IMAGE} ${UBOOT_SPI_SPL_BINARY} | ||
103 | |||
104 | install ${B}/${UBOOT_SPI_BINARY} ${DEPLOYDIR}/${UBOOT_SPI_IMAGE} | ||
105 | rm -f ${UBOOT_SPI_BINARY} ${UBOOT_SPI_SYMLINK} | ||
106 | ln -sf ${UBOOT_SPI_IMAGE} ${UBOOT_SPI_SYMLINK} | ||
107 | ln -sf ${UBOOT_SPI_IMAGE} ${UBOOT_SPI_BINARY} | ||
108 | |||
109 | install ${B}/${UBOOT_SPI_GPH_BINARY} ${DEPLOYDIR}/${UBOOT_SPI_GPH_IMAGE} | ||
110 | rm -f ${UBOOT_SPI_GPH_BINARY} ${UBOOT_SPI_GPH_SYMLINK} | ||
111 | ln -sf ${UBOOT_SPI_GPH_IMAGE} ${UBOOT_SPI_GPH_SYMLINK} | ||
112 | ln -sf ${UBOOT_SPI_GPH_IMAGE} ${UBOOT_SPI_GPH_BINARY} | ||
113 | } | ||
diff --git a/recipes-bsp/u-boot/u-boot-ti.inc b/recipes-bsp/u-boot/u-boot-ti.inc index 661f9318..c53689ee 100644 --- a/recipes-bsp/u-boot/u-boot-ti.inc +++ b/recipes-bsp/u-boot/u-boot-ti.inc | |||
@@ -16,8 +16,18 @@ require ${COREBASE}/meta/recipes-bsp/u-boot/u-boot.inc | |||
16 | 16 | ||
17 | FILESEXTRAPATHS_prepend := "${THISDIR}/u-boot:" | 17 | FILESEXTRAPATHS_prepend := "${THISDIR}/u-boot:" |
18 | 18 | ||
19 | SUMMARY = "u-boot bootloader for TI devices" | ||
20 | |||
19 | LICENSE = "GPLv2+" | 21 | LICENSE = "GPLv2+" |
20 | LIC_FILES_CHKSUM = "file://COPYING;md5=1707d6db1d42237583f50183a5651ecb" | 22 | LIC_FILES_CHKSUM = "file://Licenses/README;md5=a2c678cfd4a4d97135585cad908541c6" |
23 | |||
24 | BRANCH ?= "master" | ||
25 | SRC_URI = "git://git.ti.com/ti-u-boot/ti-u-boot.git;protocol=git;branch=${BRANCH}" | ||
26 | |||
27 | PV_append = "+git${SRCPV}" | ||
28 | |||
29 | # u-boot needs devtree compiler to parse dts files | ||
30 | DEPENDS += "dtc-native" | ||
21 | 31 | ||
22 | PACKAGE_ARCH = "${MACHINE_ARCH}" | 32 | PACKAGE_ARCH = "${MACHINE_ARCH}" |
23 | 33 | ||
@@ -28,26 +38,114 @@ PKG_${PN}-dbg = "u-boot-dbg" | |||
28 | 38 | ||
29 | S = "${WORKDIR}/git" | 39 | S = "${WORKDIR}/git" |
30 | 40 | ||
41 | # Support for secure devices - detailed info is in doc/README.ti-secure | ||
42 | TI_SECURE_DEV_PKG ?= "" | ||
43 | export TI_SECURE_DEV_PKG | ||
44 | |||
31 | # SPL (Second Program Loader) to be loaded over UART | 45 | # SPL (Second Program Loader) to be loaded over UART |
32 | SPL_UART_BINARY ?= "" | 46 | SPL_UART_BINARY ?= "" |
33 | SPL_UART_IMAGE ?= "${SPL_UART_BINARY}-${MACHINE}-${PV}-${PR}" | 47 | SPL_UART_IMAGE ?= "${SPL_UART_BINARY}-${MACHINE}-${PV}-${PR}" |
34 | SPL_UART_SYMLINK ?= "${SPL_UART_BINARY}-${MACHINE}" | 48 | SPL_UART_SYMLINK ?= "${SPL_UART_BINARY}-${MACHINE}" |
35 | 49 | ||
50 | SPL_BINARY = "MLO" | ||
51 | SPL_BINARY_k2e-hs-evm = "" | ||
52 | SPL_UART_BINARY = "u-boot-spl.bin" | ||
53 | |||
54 | # Keystone specifics | ||
55 | UBOOT_SUFFIX_keystone = "bin" | ||
56 | SPL_UART_BINARY_keystone = "" | ||
57 | |||
58 | # SPI NOR Flash binaries | ||
59 | UBOOT_SPI_SPL_BINARY = "u-boot-spl.bin" | ||
60 | UBOOT_SPI_BINARY = "u-boot.img" | ||
61 | UBOOT_SPI_GPH_BINARY = "u-boot-spi.gph" | ||
62 | |||
63 | # SPI NOR Flash deployed images | ||
64 | UBOOT_SPI_SPL_IMAGE = "u-boot-spl-${MACHINE}-${PV}-${PR}.bin" | ||
65 | UBOOT_SPI_SPL_SYMLINK = "u-boot-spl-${MACHINE}.bin" | ||
66 | UBOOT_SPI_IMAGE = "u-boot-${MACHINE}-${PV}-${PR}.img" | ||
67 | UBOOT_SPI_SYMLINK = "u-boot-${MACHINE}.img" | ||
68 | UBOOT_SPI_GPH_IMAGE = "u-boot-spi-${MACHINE}-${PV}-${PR}.gph" | ||
69 | UBOOT_SPI_GPH_SYMLINK = "u-boot-spi-${MACHINE}.gph" | ||
70 | |||
71 | # HS XLD | ||
72 | UBOOT_HS_XLD_BINARY = "u-boot-spl_HS_X-LOADER" | ||
73 | UBOOT_HS_XLD_IMAGE = "u-boot-spl_HS_X-LOADER-${MACHINE}-${PV}-${PR}" | ||
74 | UBOOT_HS_XLD_SYMLINK = "u-boot-spl_HS_X-LOADER-${MACHINE}" | ||
75 | |||
76 | # HS MLO | ||
77 | UBOOT_HS_MLO_BINARY = "u-boot_HS_MLO" | ||
78 | UBOOT_HS_MLO_IMAGE = "u-boot_HS_MLO-${MACHINE}-${PV}-${PR}" | ||
79 | UBOOT_HS_MLO_SYMLINK = "u-boot_HS_MLO-${MACHINE}" | ||
80 | |||
81 | do_compile_append_am437x-hs-evm () { | ||
82 | if [ -f ${B}/u-boot-spl_HS_ISSW ]; then | ||
83 | rm -rf ${B}/MLO | ||
84 | cp ${B}/u-boot-spl_HS_ISSW ${B}/MLO | ||
85 | fi | ||
86 | } | ||
87 | |||
36 | do_install_append () { | 88 | do_install_append () { |
37 | if [ "x${SPL_UART_BINARY}" != "x" ] | 89 | if [ "x${SPL_UART_BINARY}" != "x" ]; then |
38 | then | 90 | install ${B}/spl/${SPL_UART_BINARY} ${D}/boot/${SPL_UART_IMAGE} |
39 | install ${B}/spl/${SPL_UART_BINARY} ${D}/boot/${SPL_UART_IMAGE} | 91 | ln -sf ${SPL_UART_IMAGE} ${D}/boot/${SPL_UART_BINARY} |
40 | ln -sf ${SPL_UART_IMAGE} ${D}/boot/${SPL_UART_BINARY} | 92 | fi |
41 | fi | 93 | if [ -f ${B}/${UBOOT_HS_XLD_BINARY} ]; then |
94 | install ${B}/${UBOOT_HS_XLD_BINARY} ${D}/boot/${UBOOT_HS_XLD_IMAGE} | ||
95 | ln -sf ${UBOOT_HS_XLD_IMAGE} ${D}/boot/${UBOOT_HS_XLD_BINARY} | ||
96 | fi | ||
97 | if [ -f ${B}/${UBOOT_HS_MLO_BINARY} ]; then | ||
98 | install ${B}/${UBOOT_HS_MLO_BINARY} ${D}/boot/${UBOOT_HS_MLO_IMAGE} | ||
99 | ln -sf ${UBOOT_HS_MLO_IMAGE} ${D}/boot/${UBOOT_HS_MLO_BINARY} | ||
100 | fi | ||
42 | } | 101 | } |
43 | 102 | ||
44 | do_deploy_append () { | 103 | do_deploy_append () { |
45 | cd ${DEPLOYDIR} | 104 | cd ${DEPLOYDIR} |
46 | if [ "x${SPL_UART_BINARY}" != "x" ] | 105 | if [ "x${SPL_UART_BINARY}" != "x" ]; then |
47 | then | 106 | install ${B}/spl/${SPL_UART_BINARY} ${DEPLOYDIR}/${SPL_UART_IMAGE} |
48 | install ${B}/spl/${SPL_UART_BINARY} ${DEPLOYDIR}/${SPL_UART_IMAGE} | 107 | rm -f ${DEPLOYDIR}/${SPL_UART_BINARY} ${DEPLOYDIR}/${SPL_UART_SYMLINK} |
49 | rm -f ${DEPLOYDIR}/${SPL_UART_BINARY} ${DEPLOYDIR}/${SPL_UART_SYMLINK} | 108 | ln -sf ${SPL_UART_IMAGE} ${DEPLOYDIR}/${SPL_UART_BINARY} |
50 | ln -sf ${SPL_UART_IMAGE} ${DEPLOYDIR}/${SPL_UART_BINARY} | 109 | ln -sf ${SPL_UART_IMAGE} ${DEPLOYDIR}/${SPL_UART_SYMLINK} |
51 | ln -sf ${SPL_UART_IMAGE} ${DEPLOYDIR}/${SPL_UART_SYMLINK} | 110 | fi |
52 | fi | 111 | if [ -f ${B}/${UBOOT_HS_XLD_BINARY} ]; then |
112 | install ${B}/${UBOOT_HS_XLD_BINARY} ${DEPLOYDIR}/${UBOOT_HS_XLD_IMAGE} | ||
113 | rm -f ${UBOOT_HS_XLD_BINARY} ${UBOOT_HS_XLD_SYMLINK} | ||
114 | ln -sf ${UBOOT_HS_XLD_IMAGE} ${UBOOT_HS_XLD_SYMLINK} | ||
115 | ln -sf ${UBOOT_HS_XLD_IMAGE} ${UBOOT_HS_XLD_BINARY} | ||
116 | fi | ||
117 | if [ -f ${B}/${UBOOT_HS_MLO_BINARY} ]; then | ||
118 | install ${B}/${UBOOT_HS_MLO_BINARY} ${DEPLOYDIR}/${UBOOT_HS_MLO_IMAGE} | ||
119 | rm -f ${UBOOT_HS_MLO_BINARY} ${UBOOT_HS_MLO_SYMLINK} | ||
120 | ln -sf ${UBOOT_HS_MLO_IMAGE} ${UBOOT_HS_MLO_SYMLINK} | ||
121 | ln -sf ${UBOOT_HS_MLO_IMAGE} ${UBOOT_HS_MLO_BINARY} | ||
122 | fi | ||
123 | } | ||
124 | |||
125 | do_install_append_keystone () { | ||
126 | install ${B}/spl/${UBOOT_SPI_SPL_BINARY} ${D}/boot/${UBOOT_SPI_SPL_IMAGE} | ||
127 | ln -sf ${UBOOT_SPI_SPL_IMAGE} ${D}/boot/${UBOOT_SPI_SPL_BINARY} | ||
128 | |||
129 | install ${B}/${UBOOT_SPI_BINARY} ${D}/boot/${UBOOT_SPI_IMAGE} | ||
130 | ln -sf ${UBOOT_SPI_IMAGE} ${D}/boot/${UBOOT_SPI_BINARY} | ||
131 | |||
132 | install ${B}/${UBOOT_SPI_GPH_BINARY} ${D}/boot/${UBOOT_SPI_GPH_IMAGE} | ||
133 | ln -sf ${UBOOT_SPI_GPH_IMAGE} ${D}/boot/${UBOOT_SPI_GPH_BINARY} | ||
134 | } | ||
135 | |||
136 | do_deploy_append_keystone () { | ||
137 | install ${B}/spl/${UBOOT_SPI_SPL_BINARY} ${DEPLOYDIR}/${UBOOT_SPI_SPL_IMAGE} | ||
138 | rm -f ${UBOOT_SPI_SPL_BINARY} ${UBOOT_SPI_SPL_SYMLINK} | ||
139 | ln -sf ${UBOOT_SPI_SPL_IMAGE} ${UBOOT_SPI_SPL_SYMLINK} | ||
140 | ln -sf ${UBOOT_SPI_SPL_IMAGE} ${UBOOT_SPI_SPL_BINARY} | ||
141 | |||
142 | install ${B}/${UBOOT_SPI_BINARY} ${DEPLOYDIR}/${UBOOT_SPI_IMAGE} | ||
143 | rm -f ${UBOOT_SPI_BINARY} ${UBOOT_SPI_SYMLINK} | ||
144 | ln -sf ${UBOOT_SPI_IMAGE} ${UBOOT_SPI_SYMLINK} | ||
145 | ln -sf ${UBOOT_SPI_IMAGE} ${UBOOT_SPI_BINARY} | ||
146 | |||
147 | install ${B}/${UBOOT_SPI_GPH_BINARY} ${DEPLOYDIR}/${UBOOT_SPI_GPH_IMAGE} | ||
148 | rm -f ${UBOOT_SPI_GPH_BINARY} ${UBOOT_SPI_GPH_SYMLINK} | ||
149 | ln -sf ${UBOOT_SPI_GPH_IMAGE} ${UBOOT_SPI_GPH_SYMLINK} | ||
150 | ln -sf ${UBOOT_SPI_GPH_IMAGE} ${UBOOT_SPI_GPH_BINARY} | ||
53 | } | 151 | } |