#!/bin/sh
# Script for maintaining power status of Sony Vaio laptop devices
# across sleep/resume
#
# Part of the vaiopower suite http://vaio-utils.org/power/
#
# To be placed in /etc/pm/sleep.d/ or a similar location depending on
# distribution.

[ -x /usr/sbin/vaiopower ] || exit $NA

case "$1" in
	hibernate|suspend)
		/usr/sbin/vaiopower sleep on
		;;
	thaw|resume)
		/usr/sbin/vaiopower sleep off
		;;
	*)
		exit $NA
		;;
esac
