Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

e1000: fix wrong queue idx calculation

tx_ring and adapter->tx_ring are already of type "struct
e1000_tx_ring *"

Signed-off-by: Hong Zhiguo <zhiguohong@tencent.com>
Tested-by: Aaron Brown <aaron.f.brown@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>

authored by

Hong Zhiguo and committed by
Jeff Kirsher
49a45a06 ba486502

+1 -2
+1 -2
drivers/net/ethernet/intel/e1000/e1000_main.c
··· 3917 3917 " next_to_watch <%x>\n" 3918 3918 " jiffies <%lx>\n" 3919 3919 " next_to_watch.status <%x>\n", 3920 - (unsigned long)((tx_ring - adapter->tx_ring) / 3921 - sizeof(struct e1000_tx_ring)), 3920 + (unsigned long)(tx_ring - adapter->tx_ring), 3922 3921 readl(hw->hw_addr + tx_ring->tdh), 3923 3922 readl(hw->hw_addr + tx_ring->tdt), 3924 3923 tx_ring->next_to_use,