diff options
Diffstat (limited to 'drivers/net/strip.c')
-rw-r--r-- | drivers/net/strip.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/strip.c b/drivers/net/strip.c index 862a13370..32c02b4f0 100644 --- a/drivers/net/strip.c +++ b/drivers/net/strip.c @@ -891,7 +891,7 @@ static void strip_unlock(struct strip *strip_info) */ strip_info->idle_timer.expires = jiffies + HZ; add_timer(&strip_info->idle_timer); - if (!clear_bit(0, (void *)&strip_info->dev.tbusy)) + if (!test_and_clear_bit(0, (void *)&strip_info->dev.tbusy)) printk(KERN_ERR "%s: trying to unlock already unlocked device!\n", strip_info->dev.name); } @@ -1745,7 +1745,7 @@ static int strip_xmit(struct sk_buff *skb, struct device *dev) printk(KERN_ERR "%s: xmit call when iface is down\n", dev->name); return(1); } - if (set_bit(0, (void *) &strip_info->dev.tbusy)) return(1); + if (test_and_set_bit(0, (void *) &strip_info->dev.tbusy)) return(1); del_timer(&strip_info->idle_timer); /* See if someone has been ifconfigging */ |