Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 266865
b: refs/heads/master
c: 850a545
h: refs/heads/master
i:
  266863: bbecfcb
v: v3
  • Loading branch information
Eric W. Biederman authored and David S. Miller committed Oct 19, 2011
1 parent dadb451 commit c2f7030
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 06a59ecb921de1d44efcf2cdf543bc689fe2e0d8
refs/heads/master: 850a545bd8a41648445bfc5541afe36ca105b0b8
8 changes: 7 additions & 1 deletion trunk/net/core/dev.c
Original file line number Diff line number Diff line change
Expand Up @@ -5235,7 +5235,7 @@ static void rollback_registered_many(struct list_head *head)
dev = list_first_entry(head, struct net_device, unreg_list);
call_netdevice_notifiers(NETDEV_UNREGISTER_BATCH, dev);

rcu_barrier();
synchronize_net();

list_for_each_entry(dev, head, unreg_list)
dev_put(dev);
Expand Down Expand Up @@ -5748,6 +5748,12 @@ void netdev_run_todo(void)

__rtnl_unlock();

/* Wait for rcu callbacks to finish before attempting to drain
* the device list. This usually avoids a 250ms wait.
*/
if (!list_empty(&list))
rcu_barrier();

while (!list_empty(&list)) {
struct net_device *dev
= list_first_entry(&list, struct net_device, todo_list);
Expand Down

0 comments on commit c2f7030

Please sign in to comment.