1999-07-10 19:02:42 +01:00
|
|
|
#!/bin/sh
|
|
|
|
#
|
1999-08-28 00:37:10 +01:00
|
|
|
# $FreeBSD$
|
1999-07-10 19:02:42 +01:00
|
|
|
#
|
|
|
|
# sample run command file for APM Suspend Event
|
|
|
|
|
1999-09-13 16:44:20 +01:00
|
|
|
if [ -r /var/run/rc.suspend.pid ]; then
|
1999-07-10 19:02:42 +01:00
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
echo $$ > /var/run/rc.suspend.pid
|
|
|
|
|
|
|
|
# If you have troubles on suspending with PC-CARD modem, try this.
|
|
|
|
# See also contrib/pccardq.c (Only for PAO users).
|
1999-09-13 16:44:20 +01:00
|
|
|
# pccardq | awk -F '~' '$5 == "filled" && $4 ~ /sio/ \
|
1999-07-10 19:02:42 +01:00
|
|
|
# { printf("pccardc power %d 0", $1); }' | sh
|
|
|
|
|
|
|
|
logger -t apmd suspend at `date +'%Y%m%d %H:%M:%S'`
|
|
|
|
sync && sync && sync
|
|
|
|
sleep 3
|
|
|
|
|
|
|
|
rm -f /var/run/rc.suspend.pid
|
|
|
|
zzz
|
|
|
|
|
|
|
|
exit 0
|