mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
input: sh_keysc suspend can use to_platform_device()
This patch changes sh_keysc to use to_platform_device() for suspend. Thanks to Trilok Soni for this suggestion. Signed-off-by: Magnus Damm <[email protected]> Reviewed-by: Trilok Soni <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
This commit is contained in:
parent
4a55026fd7
commit
49976927de
1 changed files with 2 additions and 5 deletions
|
|
@ -257,13 +257,10 @@ static int __devexit sh_keysc_remove(struct platform_device *pdev)
|
|||
|
||||
static int sh_keysc_suspend(struct device *dev)
|
||||
{
|
||||
struct platform_device *pdev;
|
||||
struct sh_keysc_priv *priv;
|
||||
struct platform_device *pdev = to_platform_device(dev);
|
||||
struct sh_keysc_priv *priv = platform_get_drvdata(pdev);
|
||||
unsigned short value;
|
||||
|
||||
pdev = container_of(dev, struct platform_device, dev);
|
||||
priv = platform_get_drvdata(pdev);
|
||||
|
||||
value = ioread16(priv->iomem_base + KYCR1_OFFS);
|
||||
|
||||
if (device_may_wakeup(dev))
|
||||
|
|
|
|||
Loading…
Reference in a new issue