]> git.baikalelectronics.ru Git - kernel.git/commit
netxen: fix tx ring accounting
authorDhananjay Phadke <dhananjay@netxen.com>
Wed, 17 Jun 2009 17:27:25 +0000 (17:27 +0000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 18 Jun 2009 07:46:14 +0000 (00:46 -0700)
commitb4f3799c5b0bbb04dbe694188d301755c9a9ffde
treedd04fda143a4a7d71b32b79b508a0566450c22c6
parentce5a151f55b09ce4065e68ca8a77fd31516689fe
netxen: fix tx ring accounting

This forces every update of tx ring producer to check for
availability of space for next full TSO command. Earlier
firmware control commands didn't care to pause tx queue.

Stop the tx queue if there's not enough space to transmit one full
LSO command left on the tx ring after current transmit. This avoids
returning NETDEV_TX_BUSY after checking distance between producer
and consumer on every cpu.

Restart the tx queue only if we have cleaned up enough tx
descriptors.

Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/netxen/netxen_nic.h
drivers/net/netxen/netxen_nic_hw.c
drivers/net/netxen/netxen_nic_init.c
drivers/net/netxen/netxen_nic_main.c