summaryrefslogtreecommitdiffstats
path: root/net/bridge/br_private.h
diff options
context:
space:
mode:
authorNikolay Aleksandrov <nikolay@cumulusnetworks.com>2016-07-14 06:10:01 +0300
committerDavid S. Miller <davem@davemloft.net>2016-07-16 19:57:38 -0700
commitb35c5f632b630183396a2ea2e2247ff8bbf2c94f (patch)
treed3f99f73c088ec6360fdfa2331d9ba25d1127efa /net/bridge/br_private.h
parente151aab9b5b3fae96b0fcd6cbe3a7f952d6cb8f8 (diff)
downloadlinux-b35c5f632b630183396a2ea2e2247ff8bbf2c94f.tar.bz2
net: bridge: drop skb2/skb0 variables and use a local_rcv boolean
Currently if the packet is going to be received locally we set skb0 or sometimes called skb2 variables to the original skb. This can get confusing and also we can avoid one conditional on the fast path by simply using a boolean and passing it around. Thanks to Roopa for the name suggestion. Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/bridge/br_private.h')
-rw-r--r--net/bridge/br_private.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/net/bridge/br_private.h b/net/bridge/br_private.h
index 40f200947ddc..4d6cdf459e57 100644
--- a/net/bridge/br_private.h
+++ b/net/bridge/br_private.h
@@ -507,12 +507,12 @@ int br_fdb_external_learn_del(struct net_bridge *br, struct net_bridge_port *p,
/* br_forward.c */
void br_deliver(const struct net_bridge_port *to, struct sk_buff *skb);
int br_dev_queue_push_xmit(struct net *net, struct sock *sk, struct sk_buff *skb);
-void br_forward(const struct net_bridge_port *to,
- struct sk_buff *skb, struct sk_buff *skb0);
+void br_forward(const struct net_bridge_port *to, struct sk_buff *skb,
+ bool local_rcv);
int br_forward_finish(struct net *net, struct sock *sk, struct sk_buff *skb);
void br_flood_deliver(struct net_bridge *br, struct sk_buff *skb, bool unicast);
void br_flood_forward(struct net_bridge *br, struct sk_buff *skb,
- struct sk_buff *skb2, bool unicast);
+ bool local_rcv, bool unicast);
/* br_if.c */
void br_port_carrier_check(struct net_bridge_port *p);
@@ -563,7 +563,7 @@ void br_multicast_dev_del(struct net_bridge *br);
void br_multicast_deliver(struct net_bridge_mdb_entry *mdst,
struct sk_buff *skb);
void br_multicast_forward(struct net_bridge_mdb_entry *mdst,
- struct sk_buff *skb, struct sk_buff *skb2);
+ struct sk_buff *skb, bool local_rcv);
int br_multicast_set_router(struct net_bridge *br, unsigned long val);
int br_multicast_set_port_router(struct net_bridge_port *p, unsigned long val);
int br_multicast_toggle(struct net_bridge *br, unsigned long val);
@@ -698,7 +698,7 @@ static inline void br_multicast_deliver(struct net_bridge_mdb_entry *mdst,
static inline void br_multicast_forward(struct net_bridge_mdb_entry *mdst,
struct sk_buff *skb,
- struct sk_buff *skb2)
+ bool local_rcv)
{
}
static inline bool br_multicast_is_router(struct net_bridge *br)