summaryrefslogtreecommitdiff
path: root/packages/apmd
diff options
context:
space:
mode:
authorDmitry Baryshkov <dbaryshkov@gmail.com>2008-12-02 18:57:17 +0300
committerDmitry Baryshkov <dbaryshkov@gmail.com>2008-12-04 16:58:48 +0300
commitea9fbdbb541ae878c31750f46d40a61a20f35d84 (patch)
treeff418ed516464747bfeb63e267c151b70e3d3989 /packages/apmd
parent4759f5627ad4d6eb4a8daf75dac724bed87fea51 (diff)
apm-tosa-suspendfix: tosa-specific suspend w/around
add tosa-specific suspend workaround, that will unbind ohci-hcd before entering suspend and rebind it again after resuming. Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Diffstat (limited to 'packages/apmd')
-rw-r--r--packages/apmd/apm-tosa-suspendfix_0.1.bb10
-rw-r--r--packages/apmd/files/50-tmio-ohci-unbind19
2 files changed, 29 insertions, 0 deletions
diff --git a/packages/apmd/apm-tosa-suspendfix_0.1.bb b/packages/apmd/apm-tosa-suspendfix_0.1.bb
new file mode 100644
index 0000000000..ad223c1959
--- /dev/null
+++ b/packages/apmd/apm-tosa-suspendfix_0.1.bb
@@ -0,0 +1,10 @@
+DESCRIPTION = "Workaround for bug 2134 (Tosa Angstrom x11 image suspend/resume failure)"
+AUTHOR = "Dmitry Baryshkov"
+PR = "r0"
+
+SRC_URI = "file://50-tmio-ohci-unbind"
+
+do_install() {
+ install -d ${D}${sysconfdir}/apm/event.d
+ install -m 0755 ${WORKDIR}/50-tmio-ohci-unbind ${D}${sysconfdir}/apm/event.d
+}
diff --git a/packages/apmd/files/50-tmio-ohci-unbind b/packages/apmd/files/50-tmio-ohci-unbind
new file mode 100644
index 0000000000..f65e0b37d3
--- /dev/null
+++ b/packages/apmd/files/50-tmio-ohci-unbind
@@ -0,0 +1,19 @@
+#!/bin/sh
+
+TOPATH=/sys/bus/platform/drivers/tmio-ohci
+
+case "$1" in
+ suspend)
+ if [ -d $TOPATH ]
+ then
+ echo -n tmio-ohci > $TOPATH/unbind
+ fi
+ ;;
+ resume)
+ if [ -d $TOPATH ]
+ then
+ echo -n tmio-ohci > $TOPATH/bind
+ fi
+ ;;
+esac
+