summaryrefslogtreecommitdiffstats
path: root/dynamic-layers
diff options
context:
space:
mode:
Diffstat (limited to 'dynamic-layers')
-rw-r--r--dynamic-layers/arm-toolchain/recipes-bsp/imx-oei/imx-oei.inc55
-rw-r--r--dynamic-layers/arm-toolchain/recipes-bsp/imx-oei/imx-oei_1.0.0.bb64
2 files changed, 63 insertions, 56 deletions
diff --git a/dynamic-layers/arm-toolchain/recipes-bsp/imx-oei/imx-oei.inc b/dynamic-layers/arm-toolchain/recipes-bsp/imx-oei/imx-oei.inc
new file mode 100644
index 000000000..f279544ed
--- /dev/null
+++ b/dynamic-layers/arm-toolchain/recipes-bsp/imx-oei/imx-oei.inc
@@ -0,0 +1,55 @@
1INHIBIT_DEFAULT_DEPS = "1"
2DEPENDS = "gcc-arm-none-eabi-native"
3
4S = "${WORKDIR}/git"
5
6inherit deploy
7
8PACKAGE_ARCH = "${MACHINE_ARCH}"
9
10OEI_CONFIGS ?= "UNDEFINED"
11OEI_CORE ?= "UNDEFINED"
12OEI_SOC ?= "UNDEFINED"
13OEI_BOARD ?= "UNDEFINED"
14OEI_DDRCONFIG ?= ""
15
16LDFLAGS[unexport] = "1"
17
18EXTRA_OEMAKE = "\
19 board=${OEI_BOARD} \
20 DEBUG=1 \
21 OEI_CROSS_COMPILE=arm-none-eabi-"
22
23EXTRA_OEMAKE:append:mx95-generic-bsp = " r=${IMX_SOC_REV}"
24EXTRA_OEMAKE:append = " ${@' DDR_CONFIG=${OEI_DDRCONFIG}' if d.getVar('OEI_DDRCONFIG') else ''}"
25
26do_configure() {
27 for oei_config in ${OEI_CONFIGS}; do
28 oe_runmake clean oei=$oei_config
29 done
30}
31
32do_compile() {
33 for oei_config in ${OEI_CONFIGS}; do
34 oe_runmake oei=$oei_config
35 done
36}
37
38do_install() {
39 install -d ${D}/firmware
40 for oei_config in ${OEI_CONFIGS}; do
41 install -m 0644 ${B}/build/${OEI_BOARD}/$oei_config/oei-*.bin ${D}/firmware
42 done
43}
44
45addtask deploy after do_install
46do_deploy() {
47 cp -rf ${D}/firmware/* ${DEPLOYDIR}/
48}
49
50FILES:${PN} = "/firmware"
51SYSROOT_DIRS += "/firmware"
52
53PROVIDES += "virtual/imx-oei"
54
55COMPATIBLE_MACHINE = "(mx95-generic-bsp)"
diff --git a/dynamic-layers/arm-toolchain/recipes-bsp/imx-oei/imx-oei_1.0.0.bb b/dynamic-layers/arm-toolchain/recipes-bsp/imx-oei/imx-oei_1.0.0.bb
index f98ad6a40..29a58ed08 100644
--- a/dynamic-layers/arm-toolchain/recipes-bsp/imx-oei/imx-oei_1.0.0.bb
+++ b/dynamic-layers/arm-toolchain/recipes-bsp/imx-oei/imx-oei_1.0.0.bb
@@ -1,65 +1,17 @@
1SUMMARY = "i.MX Optional Execution Image" 1SUMMARY = "i.MX Optional Execution Image"
2 2DESCRIPTION = "\
3The Optional Executable Image (OEI) is an optional plugin loaded and executed \
4by Cortex-M processor ROM on many NXP i.MX processors. The Cortex-M is the \
5boot core, runs the boot ROM which loads the OEI, and then branches to the \
6OEI. The OEI then configures some aspects of the hardware such as DDR config, \
7init TCM ECC, etc. There could be multiple OEI images in the boot container. \
8After execution of OEI, the processor returns to ROM execution."
3LICENSE = "BSD-3-Clause" 9LICENSE = "BSD-3-Clause"
4LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=b66f32a90f9577a5a3255c21d79bc619" 10LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=b66f32a90f9577a5a3255c21d79bc619"
5 11
6INHIBIT_DEFAULT_DEPS = "1"
7DEPENDS = "gcc-arm-none-eabi-native"
8
9SRC_URI = "${IMX_OEI_SRC};branch=${SRCBRANCH}" 12SRC_URI = "${IMX_OEI_SRC};branch=${SRCBRANCH}"
10IMX_OEI_SRC ?= "git://github.com/nxp-imx/imx-oei.git;protocol=https" 13IMX_OEI_SRC ?= "git://github.com/nxp-imx/imx-oei.git;protocol=https"
11SRCBRANCH = "master" 14SRCBRANCH = "master"
12SRCREV = "ca91ce798b2f3a2a0bab8c0f835f4bea88c9b080" 15SRCREV = "ca91ce798b2f3a2a0bab8c0f835f4bea88c9b080"
13 16
14S = "${WORKDIR}/git" 17require imx-oei.inc
15
16inherit deploy
17
18PACKAGE_ARCH = "${MACHINE_ARCH}"
19
20OEI_CONFIGS ?= "UNDEFINED"
21OEI_CORE ?= "UNDEFINED"
22OEI_SOC ?= "UNDEFINED"
23OEI_BOARD ?= "UNDEFINED"
24OEI_DDRCONFIG ?= ""
25
26LDFLAGS[unexport] = "1"
27
28EXTRA_OEMAKE = "\
29 board=${OEI_BOARD} \
30 DEBUG=1 \
31 OEI_CROSS_COMPILE=arm-none-eabi-"
32
33EXTRA_OEMAKE:append:mx95-generic-bsp = " r=${IMX_SOC_REV}"
34EXTRA_OEMAKE:append = " ${@' DDR_CONFIG=${OEI_DDRCONFIG}' if d.getVar('OEI_DDRCONFIG') else ''}"
35
36do_configure() {
37 for oei_config in ${OEI_CONFIGS}; do
38 oe_runmake clean oei=$oei_config
39 done
40}
41
42do_compile() {
43 for oei_config in ${OEI_CONFIGS}; do
44 oe_runmake oei=$oei_config
45 done
46}
47
48do_install() {
49 install -d ${D}/firmware
50 for oei_config in ${OEI_CONFIGS}; do
51 install -m 0644 ${B}/build/${OEI_BOARD}/$oei_config/oei-*.bin ${D}/firmware
52 done
53}
54
55addtask deploy after do_install
56do_deploy() {
57 cp -rf ${D}/firmware/* ${DEPLOYDIR}/
58}
59
60FILES:${PN} = "/firmware"
61SYSROOT_DIRS += "/firmware"
62
63PROVIDES += "virtual/imx-oei"
64
65COMPATIBLE_MACHINE = "(mx95-generic-bsp)"