linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Input: matrix_keypad - depend on CONFIG_PM_SLEEP for suspend/resume functions
@ 2010-05-29 22:23 Tobias Doerffel
  0 siblings, 0 replies; only message in thread
From: Tobias Doerffel @ 2010-05-29 22:23 UTC (permalink / raw)
  To: linux-input; +Cc: Tobias Doerffel

When building a kernel with CONFIG_PM=y but neither suspend nor
hibernate support, the compiler complains about the static functions
matrix_keypad_suspend() and matrix_keypad_resume() not being used:

drivers/input/keyboard/matrix_keypad.c:219:12: warning: ‘matrix_keypad_suspend’ defined but not used
drivers/input/keyboard/matrix_keypad.c:242:12: warning: ‘matrix_keypad_resume’ defined but not used

Depending on CONFIG_PM_SLEEP rather than CONFIG_PM fixes the issue.

Signed-off-by: Tobias Doerffel <tobias.doerffel@gmail.com>
---
 drivers/input/keyboard/matrix_keypad.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/input/keyboard/matrix_keypad.c b/drivers/input/keyboard/matrix_keypad.c
index b443e08..139a3bc 100644
--- a/drivers/input/keyboard/matrix_keypad.c
+++ b/drivers/input/keyboard/matrix_keypad.c
@@ -215,7 +215,7 @@ static void matrix_keypad_stop(struct input_dev *dev)
 	disable_row_irqs(keypad);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int matrix_keypad_suspend(struct device *dev)
 {
 	struct platform_device *pdev = to_platform_device(dev);
@@ -440,7 +440,7 @@ static struct platform_driver matrix_keypad_driver = {
 	.driver		= {
 		.name	= "matrix-keypad",
 		.owner	= THIS_MODULE,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 		.pm	= &matrix_keypad_pm_ops,
 #endif
 	},
-- 
1.7.0.4

--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2010-05-29 22:50 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-05-29 22:23 [PATCH] Input: matrix_keypad - depend on CONFIG_PM_SLEEP for suspend/resume functions Tobias Doerffel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).