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.inc53
-rw-r--r--dynamic-layers/arm-toolchain/recipes-bsp/imx-oei/imx-oei_1.0.0.bb62
2 files changed, 61 insertions, 54 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..95f05eab6
--- /dev/null
+++ b/dynamic-layers/arm-toolchain/recipes-bsp/imx-oei/imx-oei.inc
@@ -0,0 +1,53 @@
1INHIBIT_DEFAULT_DEPS = "1"
2DEPENDS = "gcc-arm-none-eabi-native"
3
4inherit deploy
5
6PACKAGE_ARCH = "${MACHINE_ARCH}"
7
8OEI_CONFIGS ?= "UNDEFINED"
9OEI_CORE ?= "UNDEFINED"
10OEI_SOC ?= "UNDEFINED"
11OEI_BOARD ?= "UNDEFINED"
12OEI_DDRCONFIG ?= ""
13
14LDFLAGS[unexport] = "1"
15
16EXTRA_OEMAKE = "\
17 board=${OEI_BOARD} \
18 DEBUG=1 \
19 OEI_CROSS_COMPILE=arm-none-eabi-"
20
21EXTRA_OEMAKE:append:mx95-generic-bsp = " r=${IMX_SOC_REV}"
22EXTRA_OEMAKE:append = " ${@' DDR_CONFIG=${OEI_DDRCONFIG}' if d.getVar('OEI_DDRCONFIG') else ''}"
23
24do_configure() {
25 for oei_config in ${OEI_CONFIGS}; do
26 oe_runmake clean oei=$oei_config
27 done
28}
29
30do_compile() {
31 for oei_config in ${OEI_CONFIGS}; do
32 oe_runmake oei=$oei_config
33 done
34}
35
36do_install() {
37 install -d ${D}/firmware
38 for oei_config in ${OEI_CONFIGS}; do
39 install -m 0644 ${B}/build/${OEI_BOARD}/$oei_config/oei-*.bin ${D}/firmware
40 done
41}
42
43addtask deploy after do_install
44do_deploy() {
45 cp -rf ${D}/firmware/* ${DEPLOYDIR}/
46}
47
48FILES:${PN} = "/firmware"
49SYSROOT_DIRS += "/firmware"
50
51PROVIDES += "virtual/imx-oei"
52
53COMPATIBLE_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 33ec90349..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,63 +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
14inherit deploy 17require imx-oei.inc
15
16PACKAGE_ARCH = "${MACHINE_ARCH}"
17
18OEI_CONFIGS ?= "UNDEFINED"
19OEI_CORE ?= "UNDEFINED"
20OEI_SOC ?= "UNDEFINED"
21OEI_BOARD ?= "UNDEFINED"
22OEI_DDRCONFIG ?= ""
23
24LDFLAGS[unexport] = "1"
25
26EXTRA_OEMAKE = "\
27 board=${OEI_BOARD} \
28 DEBUG=1 \
29 OEI_CROSS_COMPILE=arm-none-eabi-"
30
31EXTRA_OEMAKE:append:mx95-generic-bsp = " r=${IMX_SOC_REV}"
32EXTRA_OEMAKE:append = " ${@' DDR_CONFIG=${OEI_DDRCONFIG}' if d.getVar('OEI_DDRCONFIG') else ''}"
33
34do_configure() {
35 for oei_config in ${OEI_CONFIGS}; do
36 oe_runmake clean oei=$oei_config
37 done
38}
39
40do_compile() {
41 for oei_config in ${OEI_CONFIGS}; do
42 oe_runmake oei=$oei_config
43 done
44}
45
46do_install() {
47 install -d ${D}/firmware
48 for oei_config in ${OEI_CONFIGS}; do
49 install -m 0644 ${B}/build/${OEI_BOARD}/$oei_config/oei-*.bin ${D}/firmware
50 done
51}
52
53addtask deploy after do_install
54do_deploy() {
55 cp -rf ${D}/firmware/* ${DEPLOYDIR}/
56}
57
58FILES:${PN} = "/firmware"
59SYSROOT_DIRS += "/firmware"
60
61PROVIDES += "virtual/imx-oei"
62
63COMPATIBLE_MACHINE = "(mx95-generic-bsp)"