mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] rtc: palmas: init wakeup before device register
@ 2013-06-26 10:05 Wei Ni
  0 siblings, 0 replies; only message in thread
From: Wei Ni @ 2013-06-26 10:05 UTC (permalink / raw)
  To: a.zummo, ldewangan; +Cc: rtc-linux, linux-kernel, Wei Ni

Enable dev as wakeup device before calling rtc_device_register(),
so that it can create the "wakealarm" sysfs.

Signed-off-by: Wei Ni <wni@nvidia.com>
Acked-by: Laxman Dewangan <ldewangan@nvidia.com>
---
 drivers/rtc/rtc-palmas.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/rtc/rtc-palmas.c b/drivers/rtc/rtc-palmas.c
index 50204d4..a1fecc8 100644
--- a/drivers/rtc/rtc-palmas.c
+++ b/drivers/rtc/rtc-palmas.c
@@ -265,6 +265,7 @@ static int palmas_rtc_probe(struct platform_device *pdev)
 
 	palmas_rtc->irq = platform_get_irq(pdev, 0);
 
+	device_init_wakeup(&pdev->dev, 1);
 	palmas_rtc->rtc = devm_rtc_device_register(&pdev->dev, pdev->name,
 				&palmas_rtc_ops, THIS_MODULE);
 	if (IS_ERR(palmas_rtc->rtc)) {
@@ -283,7 +284,6 @@ static int palmas_rtc_probe(struct platform_device *pdev)
 		return ret;
 	}
 
-	device_set_wakeup_capable(&pdev->dev, 1);
 	return 0;
 }
 
-- 
1.7.9.5


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

only message in thread, other threads:[~2013-06-26 10:07 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-06-26 10:05 [PATCH] rtc: palmas: init wakeup before device register Wei Ni

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®