mfd: cros_ec_spi: Set wakeup capability
authorPrathyush K <prathyush.k@samsung.com>
Mon, 16 Jun 2014 21:12:23 +0000 (14:12 -0700)
committerLee Jones <lee.jones@linaro.org>
Wed, 9 Jul 2014 13:58:06 +0000 (14:58 +0100)
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>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
drivers/mfd/cros_ec_spi.c

index 0cbc3dbeb37fc53de29eb7c6c33d3fc319e75991..1fcc65ecad0e3a8a00f71859bc269c1aa4fb3680 100644 (file)
@@ -381,6 +381,8 @@ static int cros_ec_spi_probe(struct spi_device *spi)
                return err;
        }
 
+       device_init_wakeup(&spi->dev, true);
+
        return 0;
 }