aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input/touchscreen/st1232.c
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2012-04-03 11:30:28 -0700
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2012-04-04 09:25:40 -0700
commitb3571400395e318306165eabbfbe05a4c3e4366c (patch)
treeafc928164984dce6ad653e9012a006c9072b30f9 /drivers/input/touchscreen/st1232.c
parente6293d2f8a6cd427a1ef4ddecb16b1d5ae1929cd (diff)
downloadkernel_goldelico_gta04-b3571400395e318306165eabbfbe05a4c3e4366c.zip
kernel_goldelico_gta04-b3571400395e318306165eabbfbe05a4c3e4366c.tar.gz
kernel_goldelico_gta04-b3571400395e318306165eabbfbe05a4c3e4366c.tar.bz2
Input: st1232 - switch to using SIMPLE_DEV_PM_OPS
Acked-by: Rafael J. Wysocki <rjw@sisk.pl> Reviewed-by: Simon Horman <horms@verge.net.au> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers/input/touchscreen/st1232.c')
-rw-r--r--drivers/input/touchscreen/st1232.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/drivers/input/touchscreen/st1232.c b/drivers/input/touchscreen/st1232.c
index 216fabb..6cb68a1 100644
--- a/drivers/input/touchscreen/st1232.c
+++ b/drivers/input/touchscreen/st1232.c
@@ -218,7 +218,7 @@ static int __devexit st1232_ts_remove(struct i2c_client *client)
return 0;
}
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
static int st1232_ts_suspend(struct device *dev)
{
struct i2c_client *client = to_i2c_client(dev);
@@ -243,12 +243,11 @@ static int st1232_ts_resume(struct device *dev)
return 0;
}
-static const struct dev_pm_ops st1232_ts_pm_ops = {
- .suspend = st1232_ts_suspend,
- .resume = st1232_ts_resume,
-};
#endif
+static SIMPLE_DEV_PM_OPS(st1232_ts_pm_ops,
+ st1232_ts_suspend, st1232_ts_resume);
+
static const struct i2c_device_id st1232_ts_id[] = {
{ ST1232_TS_NAME, 0 },
{ }
@@ -271,9 +270,7 @@ static struct i2c_driver st1232_ts_driver = {
.name = ST1232_TS_NAME,
.owner = THIS_MODULE,
.of_match_table = of_match_ptr(st1232_ts_dt_ids),
-#ifdef CONFIG_PM
.pm = &st1232_ts_pm_ops,
-#endif
},
};