projects
/
GitHub
/
LineageOS
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3776c88
)
[NETNS]: Process inet_select_addr inside a namespace.
author
Denis V. Lunev
<den@openvz.org>
Fri, 29 Feb 2008 04:52:54 +0000
(20:52 -0800)
committer
David S. Miller
<davem@davemloft.net>
Fri, 29 Feb 2008 04:52:54 +0000
(20:52 -0800)
The context is available from a network device passed in.
Signed-off-by: Denis V. Lunev <den@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/devinet.c
patch
|
blob
|
blame
|
history
diff --git
a/net/ipv4/devinet.c
b/net/ipv4/devinet.c
index dfae59bfaa2c73bf96dbd20fd403ddc9bf112fbd..4a10dbbbe0a1a653a6440f37603c39303cb1aa16 100644
(file)
--- a/
net/ipv4/devinet.c
+++ b/
net/ipv4/devinet.c
@@
-872,6
+872,7
@@
__be32 inet_select_addr(const struct net_device *dev, __be32 dst, int scope)
{
__be32 addr = 0;
struct in_device *in_dev;
+ struct net *net = dev->nd_net;
rcu_read_lock();
in_dev = __in_dev_get_rcu(dev);
@@
-900,7
+901,7
@@
no_in_dev:
*/
read_lock(&dev_base_lock);
rcu_read_lock();
- for_each_netdev(
&init_
net, dev) {
+ for_each_netdev(net, dev) {
if ((in_dev = __in_dev_get_rcu(dev)) == NULL)
continue;