ipv4: introduce __ip_dev_find()
authorEric Dumazet <eric.dumazet@gmail.com>
Thu, 30 Sep 2010 03:31:56 +0000 (03:31 +0000)
committerDavid S. Miller <davem@davemloft.net>
Fri, 1 Oct 2010 04:16:05 +0000 (21:16 -0700)
commit82efee1499a27c06f5afb11b07db384fdb3f7004
treec329e037ddf4e13cd824c131eab3bd3a2e67a0fc
parent828bac87bb074f3366621724fdfbe314f98ccc7e
ipv4: introduce __ip_dev_find()

ip_dev_find(net, addr) finds a device given an IPv4 source address and
takes a reference on it.

Introduce __ip_dev_find(), taking a third argument, to optionally take
the device reference. Callers not asking the reference to be taken
should be in an rcu_read_lock() protected section.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/linux/inetdevice.h
net/ipv4/fib_frontend.c