diff options
author | Herbert Xu <herbert@gondor.apana.org.au> | 2010-02-27 19:41:42 (GMT) |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-02-28 08:48:44 (GMT) |
commit | 6088a539d8d1666dca6979b5759bf966ee9124ef (patch) | |
tree | 84adf98d3efb8dc71563c2b717b8aa1b781bb560 /net/bridge/br_device.c | |
parent | b33084be192ee1e347d98bb5c9e38a53d98d35e2 (diff) | |
download | linux-fsl-qoriq-6088a539d8d1666dca6979b5759bf966ee9124ef.tar.xz |
bridge: Use BR_INPUT_SKB_CB on xmit path
this patch makes BR_INPUT_SKB_CB available on the xmit path so
that we could avoid passing the br pointer around for the purpose
of collecting device statistics.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/bridge/br_device.c')
-rw-r--r-- | net/bridge/br_device.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/net/bridge/br_device.c b/net/bridge/br_device.c index 1a99c4e..be35629 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) const unsigned char *dest = skb->data; struct net_bridge_fdb_entry *dst; + BR_INPUT_SKB_CB(skb)->brdev = dev; + dev->stats.tx_packets++; dev->stats.tx_bytes += skb->len; |