diff options
author | Jacob Stiffler <j-stiffler@ti.com> | 2019-08-30 22:32:47 +0000 |
---|---|---|
committer | Denys Dmytriyenko <denys@ti.com> | 2019-08-30 21:30:43 +0000 |
commit | 2b0a156938869de25b4a2cb34e3e043e53139a3f (patch) | |
tree | 078589764608ba5aeeb3a1c26f8b9d715e791ea7 /recipes-kernel | |
parent | bd699060d5ba886cdc44ff7a10ff8b7cac539a3c (diff) | |
download | meta-ti-2b0a156938869de25b4a2cb34e3e043e53139a3f.tar.gz |
jailhouse: use ramfs for linux-demo
* Configure the linux-demo to use a ramfs for the linux inmate.
* Using JH_RAMFS_IMAGE, this can be set in some global conf.
Signed-off-by: Jacob Stiffler <j-stiffler@ti.com>
Signed-off-by: Denys Dmytriyenko <denys@ti.com>
Diffstat (limited to 'recipes-kernel')
-rw-r--r-- | recipes-kernel/jailhouse/jailhouse_git.bb | 21 |
1 files changed, 17 insertions, 4 deletions
diff --git a/recipes-kernel/jailhouse/jailhouse_git.bb b/recipes-kernel/jailhouse/jailhouse_git.bb index 546f1545..0b52ecba 100644 --- a/recipes-kernel/jailhouse/jailhouse_git.bb +++ b/recipes-kernel/jailhouse/jailhouse_git.bb | |||
@@ -58,8 +58,10 @@ JH_SYSCONFIG_CELL ?= "" | |||
58 | JH_SYSCONFIG_CELL_am65xx ?= "k3-am654-idk.cell" | 58 | JH_SYSCONFIG_CELL_am65xx ?= "k3-am654-idk.cell" |
59 | JH_SYSCONFIG_CELL_j7-evm ?= "k3-j721e-evm.cell" | 59 | JH_SYSCONFIG_CELL_j7-evm ?= "k3-j721e-evm.cell" |
60 | 60 | ||
61 | JH_RAMFS_IMAGE ?= "${INITRAMFS_IMAGE}" | ||
62 | |||
61 | JH_CMDLINE ?= "" | 63 | JH_CMDLINE ?= "" |
62 | JH_CMDLINE_k3 ?= "console=ttyS1,115200n8 root=/dev/mmcblk0p2 rw rootfstype=ext4 rootwait" | 64 | JH_CMDLINE_k3 ?= "console=ttyS1,115200n8" |
63 | 65 | ||
64 | do_configure() { | 66 | do_configure() { |
65 | if [ -d ${STAGING_DIR_HOST}/${CELLCONF_DIR} ]; | 67 | if [ -d ${STAGING_DIR_HOST}/${CELLCONF_DIR} ]; |
@@ -101,6 +103,16 @@ do_install() { | |||
101 | install -m 0644 ${B}/inmates/demos/${JH_ARCH}/*.bin ${D}${INMATES_DIR} | 103 | install -m 0644 ${B}/inmates/demos/${JH_ARCH}/*.bin ${D}${INMATES_DIR} |
102 | 104 | ||
103 | install -d ${D}/boot | 105 | install -d ${D}/boot |
106 | if [ -n "${JH_RAMFS_IMAGE}" ] | ||
107 | then | ||
108 | if [ -f ${DEPLOY_DIR_IMAGE}/${JH_RAMFS_IMAGE}-${MACHINE}.cpio ] | ||
109 | then | ||
110 | install -m 0644 ${DEPLOY_DIR_IMAGE}/${JH_RAMFS_IMAGE}-${MACHINE}.cpio ${D}/boot | ||
111 | else | ||
112 | bberror "Could not find JH_RAMFS_IMAGE (${JH_RAMFS_IMAGE}-${MACHINE}.cpio)!" | ||
113 | bberror "Please make sure that \"cpio\" is in IMAGE_FSTYPES." | ||
114 | fi | ||
115 | fi | ||
104 | 116 | ||
105 | if [ -n "${JH_INMATE_DTB}" -a -n "${JH_LINUX_DEMO_CELL}" ]; then | 117 | if [ -n "${JH_INMATE_DTB}" -a -n "${JH_LINUX_DEMO_CELL}" ]; then |
106 | cd ${TOOLS_SRC_DIR} | 118 | cd ${TOOLS_SRC_DIR} |
@@ -110,6 +122,7 @@ do_install() { | |||
110 | ./jailhouse-cell-linux -w ${D}${JH_DATADIR}/${JH_INMATE_DTB} \ | 122 | ./jailhouse-cell-linux -w ${D}${JH_DATADIR}/${JH_INMATE_DTB} \ |
111 | -a ${JH_ARCH} -c "${JH_CMDLINE}" \ | 123 | -a ${JH_ARCH} -c "${JH_CMDLINE}" \ |
112 | -d ../configs/${JH_ARCH}/dts/${JH_INMATE_DTB} \ | 124 | -d ../configs/${JH_ARCH}/dts/${JH_INMATE_DTB} \ |
125 | -i ${D}/boot/${JH_RAMFS_IMAGE}-${MACHINE}.cpio \ | ||
113 | ${D}${CELL_DIR}/${JH_LINUX_DEMO_CELL} \ | 126 | ${D}${CELL_DIR}/${JH_LINUX_DEMO_CELL} \ |
114 | ${DEPLOY_DIR_IMAGE}/Image \ | 127 | ${DEPLOY_DIR_IMAGE}/Image \ |
115 | | tr -cd '\11\12\15\40-\176' \ | 128 | | tr -cd '\11\12\15\40-\176' \ |
@@ -143,9 +156,9 @@ CELLS = "" | |||
143 | 156 | ||
144 | python __anonymous () { | 157 | python __anonymous () { |
145 | d.appendVarFlag('do_install', 'depends', ' virtual/kernel:do_deploy') | 158 | d.appendVarFlag('do_install', 'depends', ' virtual/kernel:do_deploy') |
146 | initrd = d.getVar('INITRAMFS_IMAGE', True) | 159 | ramfs = d.getVar('JH_RAMFS_IMAGE', True) |
147 | if initrd: | 160 | if ramfs: |
148 | d.appendVarFlag('do_install', 'depends', ' ${INITRAMFS_IMAGE}:do_image_complete') | 161 | d.appendVarFlag('do_install', 'depends', ' ${JH_RAMFS_IMAGE}:do_image_complete') |
149 | 162 | ||
150 | # Setup DEPENDS and RDEPENDS to included cells | 163 | # Setup DEPENDS and RDEPENDS to included cells |
151 | cells = d.getVar('CELLS', True) or "" | 164 | cells = d.getVar('CELLS', True) or "" |