[net-next,09/10] igb: Replace rmb in Tx cleanup with read_barrier_depends

Submitted by Jeff Kirsher on Jan. 19, 2013, 1:14 p.m.


Message ID 1358601299-10404-10-git-send-email-jeffrey.t.kirsher@intel.com
State Accepted
Delegated to: David Miller
Headers show

Commit Message

Jeff Kirsher Jan. 19, 2013, 1:14 p.m.
From: Alexander Duyck <alexander.h.duyck@intel.com>

The rmb in the Tx cleanup path is a much stronger barrier than we really need.
All that is really needed is a read_barrier_depends since the location of the
EOP descriptor is dependent on the eop_desc value.

Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Tested-by: Aaron Brown <aaron.f.brown@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
 drivers/net/ethernet/intel/igb/igb_main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/drivers/net/ethernet/intel/igb/igb_main.c b/drivers/net/ethernet/intel/igb/igb_main.c
index c9e438b..7835404 100644
--- a/drivers/net/ethernet/intel/igb/igb_main.c
+++ b/drivers/net/ethernet/intel/igb/igb_main.c
@@ -5930,7 +5930,7 @@  static bool igb_clean_tx_irq(struct igb_q_vector *q_vector)
 		/* prevent any other reads prior to eop_desc */
-		rmb();
+		read_barrier_depends();
 		/* if DD is not set pending work has not been completed */
 		if (!(eop_desc->wb.status & cpu_to_le32(E1000_TXD_STAT_DD)))