summaryrefslogtreecommitdiffstats
path: root/meta-agl-bsp
diff options
context:
space:
mode:
authorYuya Ono <Ono.Yuya@ap.MitsubishiElectric.co.jp>2018-11-14 16:36:31 +0900
committerYuya Ono <Ono.Yuya@ap.MitsubishiElectric.co.jp>2018-11-14 16:47:26 +0900
commitfca78543657d33047df35d115ed2fb4b7f7f899a (patch)
treeed74606b9d748a14711a47ae928cc0e31667edc8 /meta-agl-bsp
parent4a17dd7bc0114a8a6baffa27c5e5b2659093fa75 (diff)
dragonboard-410c: change init sequence of the qcom kernel module
Since db410c's DSP is enabled from the rocko branch, an error occurs at boot time. This patch is workaround by change init sequence of kernel module on booted with reference to the following discussion. (https://lkml.org/lkml/2018/10/31/440) Change-Id: I5e1b94a7b17889610b3beecccd3e99f4bc445226 Signed-off-by: Yuya Ono <Ono.Yuya@ap.MitsubishiElectric.co.jp>
Diffstat (limited to 'meta-agl-bsp')
-rw-r--r--meta-agl-bsp/conf/include/agl_dragonboard-410c.inc3
-rw-r--r--meta-agl-bsp/meta-qcom/recipes-bsp/q6v5-pil/files/qcom-q6v5-pil.service12
-rw-r--r--meta-agl-bsp/meta-qcom/recipes-bsp/q6v5-pil/q6v5-pil.bb20
3 files changed, 34 insertions, 1 deletions
diff --git a/meta-agl-bsp/conf/include/agl_dragonboard-410c.inc b/meta-agl-bsp/conf/include/agl_dragonboard-410c.inc
index f74d703fa..f66265369 100644
--- a/meta-agl-bsp/conf/include/agl_dragonboard-410c.inc
+++ b/meta-agl-bsp/conf/include/agl_dragonboard-410c.inc
@@ -1,2 +1,3 @@
# Install 96boards-tools for resizing partition
-IMAGE_INSTALL_append = " 96boards-tools"
+# Add systemd unit file for the qcom_q6v5_pil kernel module
+IMAGE_INSTALL_append = " 96boards-tools q6v5-pil"
diff --git a/meta-agl-bsp/meta-qcom/recipes-bsp/q6v5-pil/files/qcom-q6v5-pil.service b/meta-agl-bsp/meta-qcom/recipes-bsp/q6v5-pil/files/qcom-q6v5-pil.service
new file mode 100644
index 000000000..3d9cd24bb
--- /dev/null
+++ b/meta-agl-bsp/meta-qcom/recipes-bsp/q6v5-pil/files/qcom-q6v5-pil.service
@@ -0,0 +1,12 @@
+[Unit]
+Description=Qualcomm Hexagon PIL setup
+After=rmtfs.service
+Requires=rmtfs.service
+
+[Service]
+Type=oneshot
+RemainAfterExit=yes
+ExecStart=/sbin/modprobe -q qcom_q6v5_pil
+
+[Install]
+WantedBy=multi-user.target
diff --git a/meta-agl-bsp/meta-qcom/recipes-bsp/q6v5-pil/q6v5-pil.bb b/meta-agl-bsp/meta-qcom/recipes-bsp/q6v5-pil/q6v5-pil.bb
new file mode 100644
index 000000000..19f0760ac
--- /dev/null
+++ b/meta-agl-bsp/meta-qcom/recipes-bsp/q6v5-pil/q6v5-pil.bb
@@ -0,0 +1,20 @@
+inherit systemd
+
+SUMMARY = "Systemd unit file for the delay loading Hexagon PIL kernel module"
+SECTION = "misc"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
+
+SRC_URI += "file://qcom-q6v5-pil.service"
+
+do_install() {
+ install -d ${D}${systemd_unitdir}/system/
+ install -m 0644 ${WORKDIR}/qcom-q6v5-pil.service ${D}${systemd_unitdir}/system
+
+ # Blacklist qcom_q6v5_pil to prevent modules autoload
+ # qcom-q6v5-pil.service will do the work after rmtfs done.
+ install -d ${D}/${sysconfdir}/modprobe.d
+ echo "blacklist qcom_q6v5_pil" > ${D}/${sysconfdir}/modprobe.d/qcom_q6v5_pil.conf
+}
+
+SYSTEMD_SERVICE_${PN} = "qcom-q6v5-pil.service"