Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 327865
b: refs/heads/master
c: 5744dd9
h: refs/heads/master
i:
  327863: 6db4ee7
v: v3
  • Loading branch information
Li RongQing authored and David S. Miller committed Sep 13, 2012
1 parent 77a4c8e commit bd90bd8
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 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: fb0af4c74f200e3c4846d91d8f2f8b265450bba7
refs/heads/master: 5744dd9b71c6b9df944c6a32a000d4a564a2abd7
4 changes: 2 additions & 2 deletions trunk/net/ipv6/addrconf.c
Original file line number Diff line number Diff line change
Expand Up @@ -1708,7 +1708,7 @@ static struct rt6_info *addrconf_get_prefix_route(const struct in6_addr *pfx,
if (table == NULL)
return NULL;

write_lock_bh(&table->tb6_lock);
read_lock_bh(&table->tb6_lock);
fn = fib6_locate(&table->tb6_root, pfx, plen, NULL, 0);
if (!fn)
goto out;
Expand All @@ -1723,7 +1723,7 @@ static struct rt6_info *addrconf_get_prefix_route(const struct in6_addr *pfx,
break;
}
out:
write_unlock_bh(&table->tb6_lock);
read_unlock_bh(&table->tb6_lock);
return rt;
}

Expand Down
8 changes: 4 additions & 4 deletions trunk/net/ipv6/route.c
Original file line number Diff line number Diff line change
Expand Up @@ -1837,7 +1837,7 @@ static struct rt6_info *rt6_get_route_info(struct net *net,
if (!table)
return NULL;

write_lock_bh(&table->tb6_lock);
read_lock_bh(&table->tb6_lock);
fn = fib6_locate(&table->tb6_root, prefix ,prefixlen, NULL, 0);
if (!fn)
goto out;
Expand All @@ -1853,7 +1853,7 @@ static struct rt6_info *rt6_get_route_info(struct net *net,
break;
}
out:
write_unlock_bh(&table->tb6_lock);
read_unlock_bh(&table->tb6_lock);
return rt;
}

Expand Down Expand Up @@ -1896,7 +1896,7 @@ struct rt6_info *rt6_get_dflt_router(const struct in6_addr *addr, struct net_dev
if (!table)
return NULL;

write_lock_bh(&table->tb6_lock);
read_lock_bh(&table->tb6_lock);
for (rt = table->tb6_root.leaf; rt; rt=rt->dst.rt6_next) {
if (dev == rt->dst.dev &&
((rt->rt6i_flags & (RTF_ADDRCONF | RTF_DEFAULT)) == (RTF_ADDRCONF | RTF_DEFAULT)) &&
Expand All @@ -1905,7 +1905,7 @@ struct rt6_info *rt6_get_dflt_router(const struct in6_addr *addr, struct net_dev
}
if (rt)
dst_hold(&rt->dst);
write_unlock_bh(&table->tb6_lock);
read_unlock_bh(&table->tb6_lock);
return rt;
}

Expand Down

0 comments on commit bd90bd8

Please sign in to comment.