From: Jan Kiszka <[email protected]>

This pulls the needed blobs (yeah...) for the RPi 4 from the official
repo, adds a config that loads ATF prior to starting 64-bit Linux with a
Jailhouse-specific command line, and puts all that into a package for
the assembly by the wic imager.

Signed-off-by: Jan Kiszka <[email protected]>
---
 recipes-bsp/rpi-firmware/files/cmdline.txt          |  1 +
 recipes-bsp/rpi-firmware/files/config.txt           | 11 +++++++++++
 recipes-bsp/rpi-firmware/rpi-firmware_1.20190925.bb | 18 ++++++++++++++++++
 3 files changed, 30 insertions(+)
 create mode 100644 recipes-bsp/rpi-firmware/files/cmdline.txt
 create mode 100644 recipes-bsp/rpi-firmware/files/config.txt
 create mode 100644 recipes-bsp/rpi-firmware/rpi-firmware_1.20190925.bb

diff --git a/recipes-bsp/rpi-firmware/files/cmdline.txt 
b/recipes-bsp/rpi-firmware/files/cmdline.txt
new file mode 100644
index 0000000..2126fb6
--- /dev/null
+++ b/recipes-bsp/rpi-firmware/files/cmdline.txt
@@ -0,0 +1 @@
+console=serial0,115200 root=/dev/mmcblk0p2 rootwait mem=768M
diff --git a/recipes-bsp/rpi-firmware/files/config.txt 
b/recipes-bsp/rpi-firmware/files/config.txt
new file mode 100644
index 0000000..e66fa16
--- /dev/null
+++ b/recipes-bsp/rpi-firmware/files/config.txt
@@ -0,0 +1,11 @@
+dtparam=audio=on
+
+[pi4]
+dtoverlay=vc4-fkms-v3d
+max_framebuffers=2
+
+[all]
+enable_uart=1
+arm_64bit=1
+enable_gic=1
+armstub=bl31.bin
diff --git a/recipes-bsp/rpi-firmware/rpi-firmware_1.20190925.bb 
b/recipes-bsp/rpi-firmware/rpi-firmware_1.20190925.bb
new file mode 100644
index 0000000..5079d5c
--- /dev/null
+++ b/recipes-bsp/rpi-firmware/rpi-firmware_1.20190925.bb
@@ -0,0 +1,18 @@
+inherit dpkg-raw
+
+SRC_URI = " \
+    https://github.com/raspberrypi/firmware/archive/${PV}.tar.gz \
+    file://cmdline.txt \
+    file://config.txt"
+SRC_URI[sha256sum] = 
"b3c5c9d3cda1f77caf317b8d1f0496cd7ca791ddaeec8207a5a1940111483509"
+
+do_install() {
+    install -v -d ${D}/usr/lib/rpi-firmware/overlays
+    install -v -m 644 ${WORKDIR}/firmware-${PV}/boot/bootcode.bin 
${D}/usr/lib/rpi-firmware/
+    install -v -m 644 ${WORKDIR}/firmware-${PV}/boot/LICENCE.broadcom 
${D}/usr/lib/rpi-firmware/
+    install -v -m 644 ${WORKDIR}/firmware-${PV}/boot/*.dat 
${D}/usr/lib/rpi-firmware/
+    install -v -m 644 ${WORKDIR}/firmware-${PV}/boot/*.dtb 
${D}/usr/lib/rpi-firmware/
+    install -v -m 644 ${WORKDIR}/firmware-${PV}/boot/*.elf 
${D}/usr/lib/rpi-firmware/
+    install -v -m 644 ${WORKDIR}/firmware-${PV}/boot/overlays/* 
${D}/usr/lib/rpi-firmware/overlays/
+    install -v -m 644 ${WORKDIR}/*.txt ${D}/usr/lib/rpi-firmware/
+}
-- 
2.16.4

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jailhouse-dev/23358cc1815fefc241f0ed266486411065d8bcb0.1579170887.git.jan.kiszka%40siemens.com.

Reply via email to