• David S. Miller's avatar
    [TG3]: Eliminate all hw IRQ handler spinlocks. · f47c11ee
    David S. Miller authored
    Move all driver spinlocks to be taken at sw IRQ
    context only.
    
    This fixes the skb_copy() we were doing with hw
    IRQs disabled (which is illegal and triggers a
    BUG() with HIGHMEM enabled).  It also simplifies
    the locking all over the driver tremendously.
    
    We accomplish this feat by creating a special
    sequence to synchronize with the hw IRQ handler
    using a binary state and synchronize_irq().
    This idea is from Herbert Xu.
    
    Thanks to Michael Chan for helping to track down
    all of the race conditions in initial versions
    of this code.
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    f47c11ee
tg3.c 291 KB