ix: Implement MSI-X support and enable multiple TX rings
authorSepherosa Ziehau <sephe@dragonflybsd.org>
Wed, 19 Feb 2014 12:01:35 +0000 (20:01 +0800)
committerSepherosa Ziehau <sephe@dragonflybsd.org>
Fri, 28 Feb 2014 11:37:15 +0000 (19:37 +0800)
commit189a0ff3761b47cd5d8fa4e38e0c61209c3a91ac
tree88d75b69fe86c086d46ddb21cdb6621d1a57b343
parent0612e99a9b0f809b4fba82962748b4783901bc31
ix: Implement MSI-X support and enable multiple TX rings

Two modes are supported, if there are enough MSI-X vector:
- TX ring and RX ring processing uses independent MSI-X vector.  It
  could be useful for some most TX applocation.  It could be enabled
  by setting hw.ix.msix.agg_rxtx or hw.ixY.msix.agg_rxtx to 0.
- TX ring and RX ring processing uses same MSI-X vector.  This is the
  default.  TX ring is processed when the header write back pointer
  is moved; this avoids unecessary TX ring serialization if there is
  no TX descriptor to recollect at all.

For 82598, MSI-X is not enabled by default, due to hardware errata.  It
could be enabled by setting per-device tunable hw.ixY.msix.enable.

Multiple TX rings are enable as of this commit.  Under MSI-X mode, 32 TX
rings could be used for 82599 and X540; 16 TX rings could be used for
82598.  Once polling(4) is implemented, more TX rings could be used.

Multiple RX rings have already been enabled, however, under MSI-X mode,
16 RX rings could be used for all devices supported by this driver.

Unlike the original Intel's ixgbe, number of RX rings and number of TX
rings could be configured independently.

Remove the original Intel's ixgbe MSI-X related code, which is not used
at all.
sys/dev/netif/ix/if_ix.c
sys/dev/netif/ix/if_ix.h