kernel - fix statistics counters for if_bridge.
authorMatthew Dillon <dillon@apollo.backplane.com>
Wed, 12 Jun 2013 19:10:41 +0000 (12:10 -0700)
committerMatthew Dillon <dillon@apollo.backplane.com>
Wed, 12 Jun 2013 19:10:41 +0000 (12:10 -0700)
commit7b9441903b35a1139f96bf49f65be192345f49e3
tree3c9dc46fb5b5531a797720c8db21e5338645b564
parentea9c9a8a034ce21b182498758c2552c10a4929e4
kernel - fix statistics counters for if_bridge.

* Count input statistics in bridge_input() instead of bridge_forward()

* Add output statistics in bridge_forward().  That is, the bridge should
  in abstract look like a piece of hardware from a statistics standpoint,
  so when a packet is forwarded through a bridge interface it needs to
  show up as both an input packet and an output packet.

* Fixes statistics reporting for e.g. 'netstat -in 1'.
sys/net/bridge/if_bridge.c