Skip to content

Commit

Permalink
net,via-rhine: Fix tx_timeout handling
Browse files Browse the repository at this point in the history
rhine_reset_task() misses to disable the tx scheduler upon reset,
this can lead to a crash if work is still scheduled while we're resetting
the tx queue.

Fixes:
[   93.591707] BUG: unable to handle kernel NULL pointer dereference at 0000004c
[   93.595514] IP: [<c119d10d>] rhine_napipoll+0x491/0x6

Signed-off-by: Richard Weinberger <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
richardweinberger authored and davem330 committed Jan 15, 2014
1 parent 51bb352 commit a926592
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/net/ethernet/via/via-rhine.c
Original file line number Diff line number Diff line change
Expand Up @@ -1618,6 +1618,7 @@ static void rhine_reset_task(struct work_struct *work)
goto out_unlock;

napi_disable(&rp->napi);
netif_tx_disable(dev);
spin_lock_bh(&rp->lock);

/* clear all descriptors */
Expand Down

0 comments on commit a926592

Please sign in to comment.