aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/watchdog
diff options
context:
space:
mode:
authorKlaus Kurzmann <mok@fluxnetz.de>2010-09-14 17:54:06 +0200
committerKlaus Kurzmann <mok@fluxnetz.de>2010-09-14 17:55:42 +0200
commita54c780914ea4a12c3e14c0aec406f81b8928b14 (patch)
treee0bf876aab5c701f28682e85c5195c7169021778 /recipes/watchdog
parentd374d1c754828f5b983b6b5fbfa60d702719b078 (diff)
downloadopenembedded-a54c780914ea4a12c3e14c0aec406f81b8928b14.tar.gz
watchdog_5.6.bb: add config for the nokia900 machine
Signed-off-by: Klaus Kurzmann <mok@fluxnetz.de>
Diffstat (limited to 'recipes/watchdog')
-rw-r--r--recipes/watchdog/files/nokia900/init34
-rw-r--r--recipes/watchdog/files/nokia900/watchdog-omap.conf4
-rw-r--r--recipes/watchdog/files/nokia900/watchdog.conf4
-rw-r--r--recipes/watchdog/watchdog_5.6.bb10
4 files changed, 52 insertions, 0 deletions
diff --git a/recipes/watchdog/files/nokia900/init b/recipes/watchdog/files/nokia900/init
new file mode 100644
index 0000000000..9d07871a63
--- /dev/null
+++ b/recipes/watchdog/files/nokia900/init
@@ -0,0 +1,34 @@
+#!/bin/sh
+DAEMON="/usr/sbin/watchdog"
+NAME="watchdog"
+DESC="watchdog daemon"
+OPTIONS=""
+
+test -f $DAEMON || exit 0
+
+case "$1" in
+ start)
+ echo -n "Starting $DESC: $NAME... "
+ start-stop-daemon -S -x $DAEMON -- $OPTIONS
+ /usr/sbin/wd_keepalive -c /etc/watchdog-omap.conf &
+ echo "done."
+ ;;
+ stop)
+ echo -n "Stopping $DESC: $NAME... "
+ start-stop-daemon -K -x $DAEMON
+ echo "done."
+ ;;
+ restart)
+ echo "Restarting $DESC: $NAME... "
+ $0 stop
+ sleep 1
+ $0 start
+ echo "done."
+ ;;
+ *)
+ echo "Usage: $0 {start|stop|restart}"
+ exit 1
+ ;;
+esac
+
+exit 0
diff --git a/recipes/watchdog/files/nokia900/watchdog-omap.conf b/recipes/watchdog/files/nokia900/watchdog-omap.conf
new file mode 100644
index 0000000000..43c5896942
--- /dev/null
+++ b/recipes/watchdog/files/nokia900/watchdog-omap.conf
@@ -0,0 +1,4 @@
+watchdog-device = /dev/watchdog
+interval = 10
+realtime = yes
+priority = 1
diff --git a/recipes/watchdog/files/nokia900/watchdog.conf b/recipes/watchdog/files/nokia900/watchdog.conf
new file mode 100644
index 0000000000..48855ab2e8
--- /dev/null
+++ b/recipes/watchdog/files/nokia900/watchdog.conf
@@ -0,0 +1,4 @@
+watchdog-device = /dev/twl4030_wdt
+interval = 10
+realtime = yes
+priority = 1
diff --git a/recipes/watchdog/watchdog_5.6.bb b/recipes/watchdog/watchdog_5.6.bb
index 8c0845f0d7..569a1b2429 100644
--- a/recipes/watchdog/watchdog_5.6.bb
+++ b/recipes/watchdog/watchdog_5.6.bb
@@ -1,9 +1,14 @@
DESCRIPTION = "System watchdog daemon"
LICENSE = "GPL"
+PR = "r1"
SRC_URI = "http://www.ibiblio.org/pub/Linux/system/daemons/watchdog/${PN}-${PV}.tar.gz \
file://init"
+SRC_URI_append_nokia900 = " \
+ file://watchdog.conf \
+ file://watchdog-omap.conf"
+
inherit autotools update-rc.d
INITSCRIPT_NAME = "watchdog"
@@ -14,6 +19,11 @@ do_install_append() {
install -m 0755 ${WORKDIR}/init ${D}${sysconfdir}/init.d/watchdog
}
+do_install_append_nokia900() {
+ install -m 0644 ${WORKDIR}/watchdog.conf ${D}${sysconfdir}/watchdog.conf
+ install -m 0644 ${WORKDIR}/watchdog-omap.conf ${D}${sysconfdir}/watchdog-omap.conf
+}
+
SRC_URI[md5sum] = "6df285569dd1d85528b983c98c9b2b7c"
SRC_URI[sha256sum] = "a2c7d6726e092315dbb047211b754528e4532521678a30e16f60a31bb86a7f74"