aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSaul Wold <sgw@linux.intel.com>2014-05-01 11:57:24 -0700
committerPaul Eggleton <paul.eggleton@linux.intel.com>2014-05-09 18:19:36 +0100
commit3250f7092fa63027dd2b2a9f6443accea16fa6c1 (patch)
tree48d60ed43330137a2be7eb6324338ef0febf795b
parent60b176f615fc178b9cc186333f0c05aaae2c7d85 (diff)
downloadmeta-intel-quark-3250f7092fa63027dd2b2a9f6443accea16fa6c1.tar.gz
meta-intel-quark-3250f7092fa63027dd2b2a9f6443accea16fa6c1.tar.bz2
meta-intel-quark-3250f7092fa63027dd2b2a9f6443accea16fa6c1.zip
quark-init: Add from v1.0.0
(meta-clanton rev: 45df415361ae60f5113e97533584ef17e1f5a1c1) Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
-rw-r--r--recipes-kernel/quark-init/files/galileo.conf23
-rwxr-xr-xrecipes-kernel/quark-init/files/quark-init.sh24
-rw-r--r--recipes-kernel/quark-init/quark-init_0.1.bb23
3 files changed, 70 insertions, 0 deletions
diff --git a/recipes-kernel/quark-init/files/galileo.conf b/recipes-kernel/quark-init/files/galileo.conf
new file mode 100644
index 0000000..2a7dba9
--- /dev/null
+++ b/recipes-kernel/quark-init/files/galileo.conf
@@ -0,0 +1,23 @@
+pch-udc
+g-serial vendor=0x8086 product=0xBABE
+stmmac
+ehci_hcd
+ohci_hcd
+ehci-pci
+usb_storage
+gpio_sch
+intel_qrk_gip
+cy8c9540a
+at24
+i2c_dev
+spidev
+spi-pxa2xx-pci
+spi-pxa2xx
+industrialio
+ad7298
+iwlwifi
+btusb
+usbhid
+evdev
+sdhci-pci
+mmc-block
diff --git a/recipes-kernel/quark-init/files/quark-init.sh b/recipes-kernel/quark-init/files/quark-init.sh
new file mode 100755
index 0000000..e03f454
--- /dev/null
+++ b/recipes-kernel/quark-init/files/quark-init.sh
@@ -0,0 +1,24 @@
+#!/bin/sh
+
+load_drivers()
+{
+ while IFS= read -r line; do
+ modprobe $line
+ done < "/etc/modules-load.quark/$1.conf"
+}
+
+do_board()
+{
+ type dmidecode > /dev/null 2>&1 || die "dmidecode not installed"
+ board=$(dmidecode -s baseboard-product-name)
+ case "$board" in *"Galileo" ) load_drivers "galileo" ;; esac
+}
+
+die()
+{
+ exit 1
+}
+
+do_board
+exit 0
+
diff --git a/recipes-kernel/quark-init/quark-init_0.1.bb b/recipes-kernel/quark-init/quark-init_0.1.bb
new file mode 100644
index 0000000..65fa039
--- /dev/null
+++ b/recipes-kernel/quark-init/quark-init_0.1.bb
@@ -0,0 +1,23 @@
+DESCRIPTION = "List of drivers to be auto-loaded"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
+
+SRC_URI = "file://quark-init.sh \
+ file://galileo.conf"
+
+INSTALLDIR = "/etc/modules-load.quark"
+FILES_${PN} += "${INSTALLDIR}"
+FILES_${PN}-dbg += "${INSTALLDIR}/.debug"
+
+do_install() {
+ install -d ${D}${INSTALLDIR}
+ install -m 0755 ${WORKDIR}/galileo.conf ${D}${INSTALLDIR}/
+ install -d ${D}${sysconfdir}/init.d
+ install -m 0755 ${WORKDIR}/quark-init.sh ${D}${sysconfdir}/init.d
+}
+
+inherit update-rc.d
+
+INITSCRIPT_NAME = "quark-init.sh"
+INITSCRIPT_PARAMS = "start 75 5 ."
+