Skip to content

Commit

Permalink
FS_ENET: TX stuff should use fep->tx_lock, instead of fep->lock.
Browse files Browse the repository at this point in the history
Signed-off-by: Vitaly Bordug <vitb@kernel.crashing.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
  • Loading branch information
Vitaly Bordug authored and David S. Miller committed Oct 10, 2007
1 parent 1a9e854 commit aa90f50
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions drivers/net/fs_enet/fs_enet-main.c
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ static void fs_enet_tx(struct net_device *dev)
int dirtyidx, do_wake, do_restart;
u16 sc;

spin_lock(&fep->lock);
spin_lock(&fep->tx_lock);
bdp = fep->dirty_tx;

do_wake = do_restart = 0;
Expand Down Expand Up @@ -415,7 +415,7 @@ static void fs_enet_tx(struct net_device *dev)
if (do_restart)
(*fep->ops->tx_restart)(dev);

spin_unlock(&fep->lock);
spin_unlock(&fep->tx_lock);

if (do_wake)
netif_wake_queue(dev);
Expand Down Expand Up @@ -818,7 +818,9 @@ static int fs_enet_close(struct net_device *dev)
phy_stop(fep->phydev);

spin_lock_irqsave(&fep->lock, flags);
spin_lock(&fep->tx_lock);
(*fep->ops->stop)(dev);
spin_unlock(&fep->tx_lock);
spin_unlock_irqrestore(&fep->lock, flags);

/* release any irqs */
Expand Down

0 comments on commit aa90f50

Please sign in to comment.