netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: netif_tx_disable and lockless TX
@ 2006-05-31  4:51 Michael Chan
  2006-05-31  4:58 ` Herbert Xu
  0 siblings, 1 reply; 36+ messages in thread
From: Michael Chan @ 2006-05-31  4:51 UTC (permalink / raw)
  To: Herbert Xu, David Miller; +Cc: jgarzik, netdev

Herbert Xu wrote:

> On Tue, May 30, 2006 at 09:13:22PM -0700, David Miller wrote:
> > As per the bug, I always keep thinking about changing how we
> > do the lockless stuff by simply making xmit_lock a pointer.
> > Drivers like tg3 can make it point to their local driver lock.
> 
> This is equivalent to just using the xmit_lock in the driver, right?
> IIRC the problem was with IRQ disabling vs. BH disabling.

For drivers that always take a private tx lock between tx completion
and hard_start_xmit on top of the xmit_lock, getting rid of the
xmit_lock using LLTX is a net gain.

For drivers that don't need a private tx lock or rarely need it between
tx completion and hard_start_xmit, it makes little difference whether
you use xmit_lock or private lock with LLTX.

> 
> That's why I suggest that every NIC that uses this feature be forced
> to do what TG3 does so only BH disabling is needed.  Once that's done
> they can just use xmit_lock and everyone will be happy again.
> 

As long as the tx completion is all done in NAPI, it can use BH
disabling
without irq disabling.

TG3 uses LLTX with a private tx_lock. BNX2 uses xmit_lock with a private
tx_lock that is rarely used. Both drivers use BH disabling. The profiles
of the 2 drivers are very similar.


^ permalink raw reply	[flat|nested] 36+ messages in thread

end of thread, other threads:[~2006-06-14 12:55 UTC | newest]

Thread overview: 36+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-05-31  4:51 netif_tx_disable and lockless TX Michael Chan
2006-05-31  4:58 ` Herbert Xu
2006-05-31  5:11   ` David Miller
2006-05-31  5:14     ` Herbert Xu
2006-05-31  6:26       ` David Miller
2006-05-31  6:31         ` Herbert Xu
2006-05-31  7:08           ` David Miller
2006-05-31 12:06             ` Herbert Xu
2006-05-31 12:36               ` jamal
2006-05-31 12:40                 ` Herbert Xu
2006-05-31 13:03                   ` jamal
2006-05-31 17:52                 ` Robert Olsson
2006-06-02  3:25                   ` Stephen Hemminger
2006-06-02 10:46                     ` Robert Olsson
2006-06-14 12:52                   ` jamal
2006-05-31 21:20     ` Michael Chan
2006-06-01  0:09       ` David Miller
2006-06-01  0:25         ` Herbert Xu
2006-05-31 23:01           ` Michael Chan
2006-06-01  0:42             ` Herbert Xu
2006-06-01  0:27               ` Michael Chan
2006-06-01  2:27                 ` Herbert Xu
2006-06-01 11:15           ` [NET]: Add netif_tx_lock Herbert Xu
2006-06-06  4:32             ` David Miller
2006-06-06  4:44               ` Roland Dreier
2006-06-06  4:50                 ` Roland Dreier
2006-06-06  4:57                   ` Roland Dreier
2006-06-06  5:10                     ` David Miller
2006-06-06  6:01                       ` Roland Dreier
2006-06-06  4:58                   ` David Miller
2006-06-06  5:04                     ` Roland Dreier
2006-06-06  5:09                       ` David Miller
2006-06-06  4:57                 ` David Miller
2006-06-06 10:22               ` Herbert Xu
2006-06-09  5:48             ` Herbert Xu
2006-06-09 19:21               ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).