freebsd-dev/sys/ofed/drivers/net/mlx4
Gleb Smirnoff 063efed28c The drbr(9) API appeared to be so unclear, that most drivers in
tree used it incorrectly, which lead to inaccurate overrated
if_obytes accounting. The drbr(9) used to update ifnet stats on
drbr_enqueue(), which is not accurate since enqueuing doesn't
imply successful processing by driver. Dequeuing neither mean
that. Most drivers also called drbr_stats_update() which did
accounting again, leading to doubled if_obytes statistics. And
in case of severe transmitting, when a packet could be several
times enqueued and dequeued it could have been accounted several
times.

o Thus, make drbr(9) API thinner. Now drbr(9) merely chooses between
  ALTQ queueing or buf_ring(9) queueing.
  - It doesn't touch the buf_ring stats any more.
  - It doesn't touch ifnet stats anymore.
  - drbr_stats_update() no longer exists.

o buf_ring(9) handles its stats itself:
  - It handles br_drops itself.
  - br_prod_bytes stats are dropped. Rationale: no one ever
    reads them but update of a common counter on every packet
    negatively affects performance due to excessive cache
    invalidation.
  - buf_ring_enqueue_bytes() reduced to buf_ring_enqueue(), since
    we no longer account bytes.

o Drivers handle their stats theirselves: if_obytes, if_omcasts.

o mlx4(4), igb(4), em(4), vxge(4), oce(4) and  ixv(4) no longer
  use drbr_stats_update(), and update ifnet stats theirselves.

o bxe(4) was the most correct driver, it didn't call
  drbr_stats_update(), thus it was the only driver accurate under
  moderate load. Now it also maintains stats itself.

o ixgbe(4) had already taken stats from hardware, so just
  - drop software stats updating.
  - take multicast packet count from hardware as well.

o mxge(4) just no longer needs NO_SLOW_STATS define.

o cxgb(4), cxgbe(4) need no change, since they obtain stats
  from hardware.

Reviewed by:	jfv, gnn
2012-09-28 18:28:27 +00:00
..
alloc.c
catas.c
cmd.c
cq.c
en_cq.c - Correct the vlan filter programming. The device filter is built in 2011-03-23 02:47:04 +00:00
en_ethtool.c - Implement wake-on-lan support in mlxen. 2011-03-26 00:54:01 +00:00
en_frag.c Add OFED and the associated options and drivers to x86 LINT builds: 2012-04-12 14:01:06 +00:00
en_main.c
en_netdev.c Do not announce IPv6 TSO support yet. The driver seems to make assumptions 2012-04-23 21:50:10 +00:00
en_params.c
en_port.c Properly parse 40G media types from newer Mellanox adapters that are 2012-04-10 14:01:09 +00:00
en_port.h Properly parse 40G media types from newer Mellanox adapters that are 2012-04-10 14:01:09 +00:00
en_resources.c
en_rx.c Add OFED and the associated options and drivers to x86 LINT builds: 2012-04-12 14:01:06 +00:00
en_selftest.c
en_tx.c The drbr(9) API appeared to be so unclear, that most drivers in 2012-09-28 18:28:27 +00:00
eq.c
fw.c - Implement wake-on-lan support in mlxen. 2011-03-26 00:54:01 +00:00
fw.h - Implement wake-on-lan support in mlxen. 2011-03-26 00:54:01 +00:00
icm.c
icm.h
intf.c
main.c - Implement wake-on-lan support in mlxen. 2011-03-26 00:54:01 +00:00
Makefile
mcg.c
mlx4_en.h - Implement wake-on-lan support in mlxen. 2011-03-26 00:54:01 +00:00
mlx4.h
mr.c
pd.c
port.c
profile.c
qp.c
reset.c
sense.c
srq.c
xrcd.c