net/ixgbevf: add an option pflink_fullchk to get link status quickly
PATCH 1/1 net/ixgbevf: add an option pflink_fullchk to get link status quickly
In some scenario, if the PF's running status is stopped, the VF link status can be detected as down by checking the mailbox status. This fully checking will introduce mailbox interrupt in PF, and it will be bad if many VFs are running and the application is checking the VF's link status quickly (wait_to_complete is 0) and frequently.
Normally, checking the PF's link status is enough, no need to fully check. For different scenarios, add 'pflink_fullchk' option to control whether check the link fully or not.
Fixes 91546fb62e67 ("net/ixgbevf: fix link state")
Signed-off-by Haiyue Wang <[email protected]>
--- doc/guides/nics/ixgbe.rst | 18 ++++++++++++ drivers/net/ixgbe/ixgbe_ethdev.c | 63 ++++++++++++++++++++++++++++++++++++++++ drivers/net/ixgbe/ixgbe_ethdev.h | 5 ++++ 3 files changed, 86 insertions(+)
doc/guides/nics/ixgbe.rst +18 -0
@@ -82,6 +82,24 @@ To guarantee the constraint, capabilities in dev_conf.rxmode.offloads will be ch fdir_conf->mode will also be checked. +VF Runtime Options +^^^^^^^^^^^^^^^^^^ + +The following ``devargs`` options can be enabled at runtime. They must +be passed as part of EAL arguments. For example, + +.. code-block:: console + + testpmd -w af:10.0,pflink_fullchk=1 -- -i + +- ``pflink_fullchk`` (default **0**) + + Toggle behavior to get ixgbevf link status quickly by checking the + mailbox status or not. If set, the VF will check the PF's link status + and the PF's mailbox running status, which will trigger PF's mailbox + interrupt generation. Otherwise, just check PF's link status, then no + mailbox interrupt in PF. + RX Burst Size ^^^^^^^^^^^^^
drivers/net/ixgbe/ixgbe_ethdev.c +63 -0
105 lines not on this page · raw message
drivers/net/ixgbe/ixgbe_ethdev.h +5 -0
@@ -498,6 +498,11 @@ struct ixgbe_adapter {/* For RSS reta table update */ uint8_t rss_reta_updated; + +/* Used for VF link sync with PF's physical and logical (by checking +* mailbox status) link status. +*/ +uint8_t pflink_fullchk; };struct ixgbe_vf_representor {
Signature · 1 line
2.7.4