mirror of
https://github.com/adulau/aha.git
synced 2025-01-03 14:43:17 +00:00
Input: pcspkr - switch driver to dev_pm_ops
Gets rid of the following warning: Platform driver 'pcspkr' needs updating - please use dev_pm_ops Signed-off-by: Frans Pop <elendil@planet.nl> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
This commit is contained in:
parent
70a6f2e6d6
commit
35db715bfd
1 changed files with 6 additions and 2 deletions
|
@ -113,7 +113,7 @@ static int __devexit pcspkr_remove(struct platform_device *dev)
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int pcspkr_suspend(struct platform_device *dev, pm_message_t state)
|
static int pcspkr_suspend(struct device *dev)
|
||||||
{
|
{
|
||||||
pcspkr_event(NULL, EV_SND, SND_BELL, 0);
|
pcspkr_event(NULL, EV_SND, SND_BELL, 0);
|
||||||
|
|
||||||
|
@ -126,14 +126,18 @@ static void pcspkr_shutdown(struct platform_device *dev)
|
||||||
pcspkr_event(NULL, EV_SND, SND_BELL, 0);
|
pcspkr_event(NULL, EV_SND, SND_BELL, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static struct dev_pm_ops pcspkr_pm_ops = {
|
||||||
|
.suspend = pcspkr_suspend,
|
||||||
|
};
|
||||||
|
|
||||||
static struct platform_driver pcspkr_platform_driver = {
|
static struct platform_driver pcspkr_platform_driver = {
|
||||||
.driver = {
|
.driver = {
|
||||||
.name = "pcspkr",
|
.name = "pcspkr",
|
||||||
.owner = THIS_MODULE,
|
.owner = THIS_MODULE,
|
||||||
|
.pm = &pcspkr_pm_ops,
|
||||||
},
|
},
|
||||||
.probe = pcspkr_probe,
|
.probe = pcspkr_probe,
|
||||||
.remove = __devexit_p(pcspkr_remove),
|
.remove = __devexit_p(pcspkr_remove),
|
||||||
.suspend = pcspkr_suspend,
|
|
||||||
.shutdown = pcspkr_shutdown,
|
.shutdown = pcspkr_shutdown,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue