lwtunnel: Pass encap and encap type attributes to lwtunnel_fill_encap
authorDavid Ahern <dsahern@gmail.com>
Tue, 23 Apr 2019 15:23:41 +0000 (08:23 -0700)
committerDavid S. Miller <davem@davemloft.net>
Wed, 24 Apr 2019 02:42:29 +0000 (19:42 -0700)
commitffa8ce54be3aaf6b15abae3bbd08282b867d3a4f
tree73a06ba0a651afeb65f19a4ee93e296e45bfe849
parent0a5d329ffd1be394e3e4176eb11ca51dfde03c40
lwtunnel: Pass encap and encap type attributes to lwtunnel_fill_encap

Currently, lwtunnel_fill_encap hardcodes the encap and encap type
attributes as RTA_ENCAP and RTA_ENCAP_TYPE, respectively. The nexthop
objects want to re-use this code but the encap attributes passed to
userspace as NHA_ENCAP and NHA_ENCAP_TYPE. Since that is the only
difference, change lwtunnel_fill_encap to take the attribute type as
an input.

Signed-off-by: David Ahern <dsahern@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/lwtunnel.h
net/core/lwtunnel.c
net/ipv4/fib_semantics.c