]> git.ipfire.org Git - people/ms/linux.git/commit
ixgbe: fix qv_lock_napi call in ixgbe_napi_disable_all
authorJacob Keller <jacob.e.keller@intel.com>
Sat, 21 Sep 2013 05:05:44 +0000 (05:05 +0000)
committerJiri Slaby <jslaby@suse.cz>
Tue, 26 Aug 2014 12:12:12 +0000 (14:12 +0200)
commit0a021a10f8f791971ab795bac74e10529d41e8a6
treeda7c1e6e7e0ba20bc0335d9efe8027e341ebb352
parent5ad438f9fa0cbc611e7851d6154833e6c0a692e1
ixgbe: fix qv_lock_napi call in ixgbe_napi_disable_all

commit 27d9ce4fd0e2e75c2907f6d3dc0487012a3e4298 upstream.

ixgbe_napi_disable_all calls napi_disable on each queue, however the busy
polling code introduced a local_bh_disable()d context around the napi_disable.
The original author did not realize that napi_disable might sleep, which would
cause a sleep while atomic BUG. In addition, on a single processor system, the
ixgbe_qv_lock_napi loop shouldn't have to mdelay. This patch adds an
ixgbe_qv_disable along with a new IXGBE_QV_STATE_DISABLED bit, which it uses to
indicate to the poll and napi routines that the q_vector has been disabled. Now
the ixgbe_napi_disable_all function will wait until all pending work has been
finished and prevent any future work from being started.

Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Cc: Eliezer Tamir <eliezer.tamir@linux.intel.com>
Cc: Alexander Duyck <alexander.duyck@intel.com>
Cc: Hyong-Youb Kim <hykim@myri.com>
Cc: Amir Vadai <amirv@mellanox.com>
Cc: Dmitry Kravkov <dmitry@broadcom.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
drivers/net/ethernet/intel/ixgbe/ixgbe.h
drivers/net/ethernet/intel/ixgbe/ixgbe_main.c