aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging/rtl8192e/rtl8192e/rtl_pm.h
diff options
context:
space:
mode:
authorVaibhav Gupta <vaibhavgupta40@gmail.com>2020-06-29 13:58:17 +0530
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-07-01 15:39:20 +0200
commit0c90789ad0377490a4e5937d96f364f055e1f3c7 (patch)
treec5efddd9b2afd19684891af9131acf29a5e6ecd0 /drivers/staging/rtl8192e/rtl8192e/rtl_pm.h
parentstaging: rtl8188eu: include: odm.h: fixed a blank space coding style issue. (diff)
downloadlinux-dev-0c90789ad0377490a4e5937d96f364f055e1f3c7.tar.xz
linux-dev-0c90789ad0377490a4e5937d96f364f055e1f3c7.zip
staging: rtl8192e: use generic power management
The structure of working of PM hooks for source files is: drivers/staging/rtl8192e/rtl8192e/rtl_pm.h : callbacks declared drivers/staging/rtl8192e/rtl8192e/rtl_pm.c : callbacks defined drivers/staging/rtl8192e/rtl8192e/rtl_core.c : callbacks used Drivers should not use legacy power management as they have to manage power states and related operations, for the device, themselves. This driver was handling them with the help of PCI helper functions like pci_save/restore_state(), pci_enable/disable_device(), etc. With generic PM, all essentials will be handled by the PCI core. Driver needs to do only device-specific operations. The driver was also using pci_enable_wake(...,..., 0) to disable wake. Use device_wakeup_disable() instead. Use device_set_wakeup_enable() where WOL is decided by the value of a variable during runtime. Compile-tested only. Signed-off-by: Vaibhav Gupta <vaibhavgupta40@gmail.com> Link: https://lore.kernel.org/r/20200629082819.216405-3-vaibhavgupta40@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to '')
-rw-r--r--drivers/staging/rtl8192e/rtl8192e/rtl_pm.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_pm.h b/drivers/staging/rtl8192e/rtl8192e/rtl_pm.h
index e58f2bcdb1dd..fd8611495975 100644
--- a/drivers/staging/rtl8192e/rtl8192e/rtl_pm.h
+++ b/drivers/staging/rtl8192e/rtl8192e/rtl_pm.h
@@ -10,7 +10,7 @@
#include <linux/types.h>
#include <linux/pci.h>
-int rtl92e_suspend(struct pci_dev *dev, pm_message_t state);
-int rtl92e_resume(struct pci_dev *dev);
+int rtl92e_suspend(struct device *dev_d);
+int rtl92e_resume(struct device *dev_d);
#endif