This increases build coverage and allows to drop an #ifdef.
Signed-off-by: Bastien Nocera <hadess@hadess.net>
---
drivers/hid/hid-lenovo.c | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/drivers/hid/hid-lenovo.c b/drivers/hid/hid-lenovo.c
index 9cc3e029e9f6..a6b73e03c16b 100644
--- a/drivers/hid/hid-lenovo.c
+++ b/drivers/hid/hid-lenovo.c
@@ -1422,7 +1422,6 @@ static int lenovo_probe(struct hid_device *hdev,
return ret;
}
-#ifdef CONFIG_PM
static int lenovo_reset_resume(struct hid_device *hdev)
{
switch (hdev->product) {
@@ -1438,7 +1437,6 @@ static int lenovo_reset_resume(struct hid_device *hdev)
return 0;
}
-#endif
static void lenovo_remove_tpkbd(struct hid_device *hdev)
{
@@ -1570,9 +1568,7 @@ static struct hid_driver lenovo_driver = {
.raw_event = lenovo_raw_event,
.event = lenovo_event,
.report_fixup = lenovo_report_fixup,
-#ifdef CONFIG_PM
- .reset_resume = lenovo_reset_resume,
-#endif
+ .reset_resume = pm_ptr(lenovo_reset_resume),
};
module_hid_driver(lenovo_driver);
--
2.52.0