ip_tunnels: convert the mode field of ip_tunnel_info to flags
The mode field holds a single bit of information only (whether the ip_tunnel_info struct is for rx or tx). Change the mode field to bit flags. This allows more mode flags to be added. Signed-off-by: Jiri Benc <jbenc@redhat.com> Acked-by: Alexei Starovoitov <ast@plumgrid.com> Acked-by: Thomas Graf <tgraf@suug.ch> Acked-by: Pravin B Shelar <pshelar@nicira.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
f6d3c19274
commit
46fa062ad6
@@ -623,7 +623,7 @@ static netdev_tx_t geneve_xmit(struct sk_buff *skb, struct net_device *dev)
|
||||
|
||||
if (geneve->collect_md) {
|
||||
info = skb_tunnel_info(skb);
|
||||
if (unlikely(info && info->mode != IP_TUNNEL_INFO_TX)) {
|
||||
if (unlikely(info && !(info->mode & IP_TUNNEL_INFO_TX))) {
|
||||
netdev_dbg(dev, "no tunnel metadata\n");
|
||||
goto tx_error;
|
||||
}
|
||||
|
Reference in New Issue
Block a user