]> git.baikalelectronics.ru Git - kernel.git/commit
ixgbe: use generic power management
authorVaibhav Gupta <vaibhavgupta40@gmail.com>
Mon, 29 Jun 2020 09:29:41 +0000 (14:59 +0530)
committerTony Nguyen <anthony.l.nguyen@intel.com>
Thu, 30 Jul 2020 15:39:41 +0000 (08:39 -0700)
commitf7b37340cb97428039a1f9d1554ba0deff054a6a
treec27875519996896cdbf28dbc02730373cfbb8726
parent9fa67d848b924f0d61692c62372e7551f6575b51
ixgbe: use generic power management

With legacy PM hooks, it was the responsibility of a driver to manage PCI
states and also the device's power state. The generic approach is to let
PCI core handle the work.

ixgbe_suspend() calls __ixgbe_shutdown() to perform intermediate tasks.
__ixgbe_shutdown() modifies the value of "wake" (device should be wakeup
enabled or not), responsible for controlling the flow of legacy PM.

Since, PCI core has no idea about the value of "wake", new code for generic
PM may produce unexpected results. Thus, use "device_set_wakeup_enable()"
to wakeup-enable the device accordingly.

Compile-tested only.

Signed-off-by: Vaibhav Gupta <vaibhavgupta40@gmail.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
drivers/net/ethernet/intel/ixgbe/ixgbe_main.c