staging/sm7xxfb: Convert to SIMPLE_DEV_PM_OPS
authorPeter Huewe <peterhuewe@gmx.de>
Mon, 18 Feb 2013 23:12:48 +0000 (00:12 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 11 Mar 2013 16:23:43 +0000 (09:23 -0700)
Instead of assigning the pm_ops fields individually we can simply use
SIMPLE_DEV_PM_OPS.

Signed-off-by: Peter Huewe <peterhuewe@gmx.de>
Acked-by: Javier Muñoz <jmunhoz@igalia.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/sm7xxfb/sm7xxfb.c

index 0764bbbfd497d78696f139e10d99e588cb2da431..8add64b1cb0940f69d783083588d65994c5c0e5c 100644 (file)
@@ -1006,15 +1006,7 @@ static int smtcfb_pci_resume(struct device *device)
        return 0;
 }
 
-static const struct dev_pm_ops sm7xx_pm_ops = {
-       .suspend = smtcfb_pci_suspend,
-       .resume = smtcfb_pci_resume,
-       .freeze = smtcfb_pci_suspend,
-       .thaw = smtcfb_pci_resume,
-       .poweroff = smtcfb_pci_suspend,
-       .restore = smtcfb_pci_resume,
-};
-
+static SIMPLE_DEV_PM_OPS(sm7xx_pm_ops, smtcfb_pci_suspend, smtcfb_pci_resume);
 #define SM7XX_PM_OPS (&sm7xx_pm_ops)
 
 #else  /* !CONFIG_PM */