]> git.baikalelectronics.ru Git - kernel.git/commit
staging: sm750fb: use generic power management
authorVaibhav Gupta <vaibhavgupta40@gmail.com>
Tue, 28 Jul 2020 12:33:49 +0000 (18:03 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 29 Jul 2020 12:01:37 +0000 (14:01 +0200)
commit5930f8ccfacebb10b168a80e5ab6692ae0c78e1e
tree4d13eb6f876b901ea9dbc844942729279d6601d8
parent44b067f2e18c817e69ed0ea48851f74d315345fb
staging: sm750fb: use generic power management

Drivers using legacy power management .suspen()/.resume() callbacks
have to manage PCI states and device's PM states themselves. They also
need to take care of standard configuration registers.

Switch to generic power management framework using a single
"struct dev_pm_ops" variable to take the unnecessary load from the driver.
This also avoids the need for the driver to directly call most of the PCI
helper functions and device power state control functions, as through
the generic framework PCI Core takes care of the necessary operations,
and drivers are required to do only device-specific jobs.

Signed-off-by: Vaibhav Gupta <vaibhavgupta40@gmail.com>
Link: https://lore.kernel.org/r/20200728123349.1331679-1-vaibhavgupta40@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/sm750fb/sm750.c