aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
Diffstat (limited to 'net')
-rw-r--r--net/bridge/br_device.c2
-rw-r--r--net/bridge/br_forward.c5
2 files changed, 5 insertions, 2 deletions
diff --git a/net/bridge/br_device.c b/net/bridge/br_device.c
index 1a99c4e04e85..be356293caa1 100644
--- a/net/bridge/br_device.c
+++ b/net/bridge/br_device.c
@@ -26,6 +26,8 @@ netdev_tx_t br_dev_xmit(struct sk_buff *skb, struct net_device *dev)
26 const unsigned char *dest = skb->data; 26 const unsigned char *dest = skb->data;
27 struct net_bridge_fdb_entry *dst; 27 struct net_bridge_fdb_entry *dst;
28 28
29 BR_INPUT_SKB_CB(skb)->brdev = dev;
30
29 dev->stats.tx_packets++; 31 dev->stats.tx_packets++;
30 dev->stats.tx_bytes += skb->len; 32 dev->stats.tx_bytes += skb->len;
31 33
diff --git a/net/bridge/br_forward.c b/net/bridge/br_forward.c
index 6cd50c6e57cf..2e1cb434f6cd 100644
--- a/net/bridge/br_forward.c
+++ b/net/bridge/br_forward.c
@@ -111,6 +111,7 @@ static void br_flood(struct net_bridge *br, struct sk_buff *skb,
111{ 111{
112 struct net_bridge_port *p; 112 struct net_bridge_port *p;
113 struct net_bridge_port *prev; 113 struct net_bridge_port *prev;
114 struct net_device *dev = BR_INPUT_SKB_CB(skb)->brdev;
114 115
115 prev = NULL; 116 prev = NULL;
116 117
@@ -120,7 +121,7 @@ static void br_flood(struct net_bridge *br, struct sk_buff *skb,
120 struct sk_buff *skb2; 121 struct sk_buff *skb2;
121 122
122 if ((skb2 = skb_clone(skb, GFP_ATOMIC)) == NULL) { 123 if ((skb2 = skb_clone(skb, GFP_ATOMIC)) == NULL) {
123 br->dev->stats.tx_dropped++; 124 dev->stats.tx_dropped++;
124 goto out; 125 goto out;
125 } 126 }
126 127
@@ -137,7 +138,7 @@ static void br_flood(struct net_bridge *br, struct sk_buff *skb,
137 if (skb0) { 138 if (skb0) {
138 skb = skb_clone(skb, GFP_ATOMIC); 139 skb = skb_clone(skb, GFP_ATOMIC);
139 if (!skb) { 140 if (!skb) {
140 br->dev->stats.tx_dropped++; 141 dev->stats.tx_dropped++;
141 goto out; 142 goto out;
142 } 143 }
143 } 144 }