summaryrefslogtreecommitdiff
path: root/tools/linux/hal-dockstation-undock-linux
blob: e85e632b36a4f7e6c383d6ea15df0b0c8e98617b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#!/bin/sh

DOCKED=`cat $HAL_PROP_LINUX_SYSFS_PATH/docked`
if [ "$DOCKED" = "0" ]; then
 	echo "org.freedesktop.Hal.Device.DockStation.NotDocked" >&2
 	echo "System not docked" >&2
	exit 1
fi

RET=`echo 1 > $HAL_PROP_LINUX_SYSFS_PATH/undock`

exit $RET