From: Henrik Rydberg Date: Tue, 22 Sep 2009 00:04:50 +0000 (-0700) Subject: hwmon: applesmc: restore accelerometer and keyboard backlight on resume X-Git-Tag: v2.6.32-rc1~417 X-Git-Url: http://ftp.safe.ca/?a=commitdiff_plain;h=a976f150a6953da5ccbd40fa6dba3bd7d56f9f67;hp=a976f150a6953da5ccbd40fa6dba3bd7d56f9f67;p=safe%2Fjmp%2Flinux-2.6 hwmon: applesmc: restore accelerometer and keyboard backlight on resume On resume from suspend, the driver currently resets the logical state as if it was brought up from halt. This patch uses the dev_pm_ops.resume/restore methods to synchronize the hardware with the memorized logical state, in effect bringing back the accelerometer and backlight to the state prior to suspend. Works for both suspend to ram and hibernation. The patch has zero effect on the running state. Signed-off-by: Henrik Rydberg Cc: Nicolas Boichat Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds ---