]> git.baikalelectronics.ru Git - kernel.git/commit
ixgbe: avoid duplicate code in suspend and stop paths
authorJacob Keller <jacob.e.keller@intel.com>
Fri, 16 May 2014 05:12:29 +0000 (05:12 +0000)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Tue, 27 May 2014 06:53:11 +0000 (23:53 -0700)
commitaf9f6645bcc7982180a6fc2a66b8cd56c06ed6e7
tree9f0448e4af175a64ed87f47a9f5c0a92bc56f178
parentf9a882ff317c7c7d57fc0142cd24bf195c7637b3
ixgbe: avoid duplicate code in suspend and stop paths

Resume path calls .open but suspend path cannot call .stop because
fdirs should not be freed and control over hardware should not be
released until WoL is configured.  To avoid having to duplicate all
changes made in .stop on suspend path split out part of .stop that
is relevant during suspend and call it from .stop and during suspend.

This fix also ensures that ixgbe_ptp_suspend is called during the
suspend path, and helps avoid similar errors. We can't call
ixgbe_ptp_stop, since it will free the PTP clock device, which we
shouldn't be doing during a suspend path.

Signed-off-by: Jakub Kicinski <kubakici@wp.pl>
Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/ixgbe/ixgbe_main.c