Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 171107
b: refs/heads/master
c: c148fc2
h: refs/heads/master
i:
  171105: 1c6768b
  171103: 765f465
v: v3
  • Loading branch information
Eric Dumazet authored and David S. Miller committed Nov 2, 2009
1 parent c8208f1 commit 4225ea3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 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: 9fdce099bb72df534daa6193318feaec177998fc
refs/heads/master: c148fc2e30c988f7e3ac91738b2c03f1cef44849
7 changes: 4 additions & 3 deletions trunk/net/ipv4/devinet.c
Original file line number Diff line number Diff line change
Expand Up @@ -405,11 +405,12 @@ struct in_device *inetdev_by_index(struct net *net, int ifindex)
{
struct net_device *dev;
struct in_device *in_dev = NULL;
read_lock(&dev_base_lock);
dev = __dev_get_by_index(net, ifindex);

rcu_read_lock();
dev = dev_get_by_index_rcu(net, ifindex);
if (dev)
in_dev = in_dev_get(dev);
read_unlock(&dev_base_lock);
rcu_read_unlock();
return in_dev;
}

Expand Down

0 comments on commit 4225ea3

Please sign in to comment.