projects
/
cascardo
/
linux.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
bnx2x: Fix the race on bp->stats_pending.
[cascardo/linux.git]
/
drivers
/
net
/
bnx2x
/
bnx2x_stats.c
diff --git
a/drivers/net/bnx2x/bnx2x_stats.c
b/drivers/net/bnx2x/bnx2x_stats.c
index
6e4d9b1
..
bda60d5
100644
(file)
--- a/
drivers/net/bnx2x/bnx2x_stats.c
+++ b/
drivers/net/bnx2x/bnx2x_stats.c
@@
-158,6
+158,11
@@
static void bnx2x_storm_stats_post(struct bnx2x *bp)
spin_lock_bh(&bp->stats_lock);
+ if (bp->stats_pending) {
+ spin_unlock_bh(&bp->stats_lock);
+ return;
+ }
+
ramrod_data.drv_counter = bp->stats_counter++;
ramrod_data.collect_port = bp->port.pmf ? 1 : 0;
for_each_eth_queue(bp, i)