1
0
mirror of https://git.yoctoproject.org/meta-ti synced 2026-05-07 03:49:20 +00:00

gadget-init: adjust for kernel 3.2 based sysfs layout

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
This commit is contained in:
Koen Kooi
2012-01-31 16:34:00 +01:00
parent 4a759de7bb
commit f244d42300
4 changed files with 7 additions and 16 deletions
+5 -5
View File
@@ -1,6 +1,6 @@
DESCRIPTION = "Units to initialize usb gadgets"
PR = "r13"
PR = "r16"
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58"
@@ -12,8 +12,6 @@ SRC_URI = "file://storage-gadget-init.service \
file://network-gadget-init.service \
file://udhcpd.service \
file://udhcpd.conf \
file://99-hokey-pokey.rules \
file://hokey-pokey.sh \
file://bone-gmass-eject.rules \
file://udhcpd.rules \
file://g-storage-reinsert.sh \
@@ -37,12 +35,14 @@ do_install() {
install -d ${D}${bindir}
install -m 0755 ${WORKDIR}/*.sh ${D}${bindir}
install -d ${D}${sysconfdir}/tmpfiles.d
echo "w /sys/class/pwm/ehrpwm.1:0/polarity - - - - 1" > ${D}${sysconfdir}/tmpfiles.d/lcd7.conf
}
PACKAGES =+ "${PN}-storage ${PN}-network ${PN}-udhcpd"
FILES_${PN} = "${sysconfdir}/udev/rules.d/99-hokey-pokey.rules \
${bindir}/hokey-pokey.sh \"
FILES_${PN} = "${sysconfdir}/tmpfiles.d"
FILES_${PN}-storage = "${base_libdir}/systemd/system/storage-gadget-init.service \
${base_libdir}/systemd/system/basic.target.wants/storage-gadget-init.service \
@@ -1,2 +0,0 @@
ACTION=="remove", DEVPATH=="/devices/platform/omap/ti81xx-usbss/musb-hdrc.1/usb1/1-1", RUN+="/usr/bin/hokey-pokey.sh"
@@ -1,7 +1,7 @@
#!/bin/sh
if [ -a /sys/devices/platform/omap/ti81xx-usbss/musb-hdrc.0/gadget/lun0/file ]
if [ -a /sys/devices/platform/omap/musb-ti81xx/musb-hdrc.0/gadget/lun0/file ]
then
x=$(cat /sys/devices/platform/omap/ti81xx-usbss/musb-hdrc.0/gadget/lun0/file)
x=$(cat /sys/devices/platform/omap/musb-ti81xx/musb-hdrc.0/gadget/lun0/file)
if [ -z "$x" ]
then
/bin/systemctl stop storage-gadget-init.service
@@ -1,7 +0,0 @@
#!/bin/sh
sleep 1
echo F > /proc/driver/musb_hdrc.1
sleep 1
echo F > /proc/driver/musb_hdrc.1