public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] mfd: cros_ec_spi: set wakeup capability
@ 2014-06-16 21:12 Doug Anderson
  2014-06-18  9:20 ` Lee Jones
  0 siblings, 1 reply; 7+ messages in thread
From: Doug Anderson @ 2014-06-16 21:12 UTC (permalink / raw)
  To: Lee Jones
  Cc: broonie, Andrew Bresticker, swarren, olof, Sonny Rao,
	linux-samsung-soc, Prathyush K, Doug Anderson, sameo,
	linux-kernel

From: Prathyush K <prathyush.k@samsung.com>

Set the device as wakeup capable and register the wakeup source.

Note: Though it makes more sense to have the SPI framework do this,
(either via device tree or by board_info)
this change is as per an existing mail chain:
https://lkml.org/lkml/2009/8/27/291

Signed-off-by: Prathyush K <prathyush.k@samsung.com>
Signed-off-by: Doug Anderson <dianders@chromium.org>
---
Note that I don't have suspend/resume actually working upstream, but I
see that /sys/bus/spi/drivers/cros-ec-spi/spi2.0/power/wakeup exists
with this patch and doesn't exist without it.

 drivers/mfd/cros_ec_spi.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/mfd/cros_ec_spi.c b/drivers/mfd/cros_ec_spi.c
index 0b8d328..ef22dd5 100644
--- a/drivers/mfd/cros_ec_spi.c
+++ b/drivers/mfd/cros_ec_spi.c
@@ -385,6 +385,8 @@ static int cros_ec_spi_probe(struct spi_device *spi)
 		return err;
 	}
 
+	device_init_wakeup(&spi->dev, true);
+
 	return 0;
 }
 
-- 
2.0.0.526.g5318336


^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2014-06-27 15:20 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-06-16 21:12 [PATCH] mfd: cros_ec_spi: set wakeup capability Doug Anderson
2014-06-18  9:20 ` Lee Jones
     [not found]   ` <CAD=FV=UiA=bsvune6A=wq+zKFq1+pkem0gTa-utxmBB6tKYM=A@mail.gmail.com>
2014-06-23  9:26     ` Lee Jones
2014-06-23 15:17       ` Doug Anderson
2014-06-27  0:28       ` Olof Johansson
2014-06-27  8:16         ` Lee Jones
2014-06-27 15:19           ` Doug Anderson

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