OSDN Git Service

igc: Add support for ETF offloading
authorVinicius Costa Gomes <vinicius.gomes@intel.com>
Fri, 14 Feb 2020 23:52:03 +0000 (15:52 -0800)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Fri, 17 Apr 2020 17:19:24 +0000 (10:19 -0700)
commit82faa9b799500f9e002067c6d8cb027ab12acca4
treec6fdeb045cf254e3345abcc85375ea27261c063b
parentec50a9d437f05dd76444a65fdd3cfbfad90ee9d6
igc: Add support for ETF offloading

This adds support for ETF offloading for the i225 controller.

For i225, the LaunchTime feature is almost a subset of the Qbv
feature. The main change from the i210 is that the launchtime of each
packet is specified as an offset applied to the BASET register. BASET
is automatically incremented each cycle.

For i225, the approach chosen is to re-use most of the setup used for
taprio offloading. With a few changes:

 - The more or less obvious one is that when ETF is enabled, we should
 set add the expected launchtime to the (advanced) transmit
 descriptor;

 - The less obvious, is that when taprio offloading is not enabled, we
 add a dummy schedule (all queues are open all the time, with a cycle
 time of 1 second).

Signed-off-by: Vinicius Costa Gomes <vinicius.gomes@intel.com>
Reviewed-by: Andre Guedes <andre.guedes@intel.com>
Tested-by: Aaron Brown <aaron.f.brown@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/igc/igc_defines.h
drivers/net/ethernet/intel/igc/igc_main.c
drivers/net/ethernet/intel/igc/igc_tsn.c