netlink: implement nla_put_in_addr and nla_put_in6_addr
authorJiri Benc <jbenc@redhat.com>
Sun, 29 Mar 2015 14:59:25 +0000 (16:59 +0200)
committerDavid S. Miller <davem@davemloft.net>
Tue, 31 Mar 2015 17:58:35 +0000 (13:58 -0400)
commit930345ea630405aa6e6f42efcb149c3f360a6b67
treec88d0858785c246038fddac3ca51571b371416b0
parent15e318bdc6dfb82914c82fb7ad00badaa8387d8e
netlink: implement nla_put_in_addr and nla_put_in6_addr

IP addresses are often stored in netlink attributes. Add generic functions
to do that.

For nla_put_in_addr, it would be nicer to pass struct in_addr but this is
not used universally throughout the kernel, in way too many places __be32 is
used to store IPv4 address.

Signed-off-by: Jiri Benc <jbenc@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
29 files changed:
drivers/net/vxlan.c
include/linux/netfilter/ipset/ip_set.h
include/net/netlink.h
net/ipv4/devinet.c
net/ipv4/fib_rules.c
net/ipv4/fib_semantics.c
net/ipv4/ip_gre.c
net/ipv4/ip_vti.c
net/ipv4/ipip.c
net/ipv4/ipmr.c
net/ipv4/netfilter/nf_conntrack_l3proto_ipv4.c
net/ipv4/route.c
net/ipv4/tcp_metrics.c
net/ipv6/addrconf.c
net/ipv6/addrlabel.c
net/ipv6/fib6_rules.c
net/ipv6/ip6_gre.c
net/ipv6/ip6_tunnel.c
net/ipv6/ip6_vti.c
net/ipv6/ip6mr.c
net/ipv6/ndisc.c
net/ipv6/netfilter/nf_conntrack_l3proto_ipv6.c
net/ipv6/route.c
net/ipv6/sit.c
net/l2tp/l2tp_netlink.c
net/netlabel/netlabel_mgmt.c
net/netlabel/netlabel_unlabeled.c
net/openvswitch/flow_netlink.c
net/wireless/nl80211.c