aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/intel/igc/igc.h
diff options
context:
space:
mode:
authorVinicius Costa Gomes <vinicius.gomes@intel.com>2020-02-14 15:52:02 -0800
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>2020-04-17 10:19:24 -0700
commitec50a9d437f05dd76444a65fdd3cfbfad90ee9d6 (patch)
tree4962301811790846c2a5c25474837418b87a8a4a /drivers/net/ethernet/intel/igc/igc.h
parent34428dff3679f0c4c9b185ff8eccefd12a7f55f8 (diff)
downloadkernel_replicant_linux-ec50a9d437f05dd76444a65fdd3cfbfad90ee9d6.tar.gz
kernel_replicant_linux-ec50a9d437f05dd76444a65fdd3cfbfad90ee9d6.tar.bz2
kernel_replicant_linux-ec50a9d437f05dd76444a65fdd3cfbfad90ee9d6.zip
igc: Add support for taprio offloading
Adds support for translating taprio schedules into i225 cycles. This will allow schedules to run in the hardware, making the schedules enforcement more precise and saving CPU time. Right now, the only simple schedules are allowed, complex schedules are rejected. "simple" in this context are schedules that each HW queue is opened and closed only once in each cycle. Changing schedules is still not supported as well. 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>
Diffstat (limited to 'drivers/net/ethernet/intel/igc/igc.h')
-rw-r--r--drivers/net/ethernet/intel/igc/igc.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/net/ethernet/intel/igc/igc.h b/drivers/net/ethernet/intel/igc/igc.h
index a1f845a2aa80..5e36822de5ec 100644
--- a/drivers/net/ethernet/intel/igc/igc.h
+++ b/drivers/net/ethernet/intel/igc/igc.h
@@ -70,6 +70,7 @@ extern char igc_driver_version[];
#define IGC_FLAG_HAS_MSIX BIT(13)
#define IGC_FLAG_VLAN_PROMISC BIT(15)
#define IGC_FLAG_RX_LEGACY BIT(16)
+#define IGC_FLAG_TSN_QBV_ENABLED BIT(17)
#define IGC_FLAG_RSS_FIELD_IPV4_UDP BIT(6)
#define IGC_FLAG_RSS_FIELD_IPV6_UDP BIT(7)
@@ -287,6 +288,9 @@ struct igc_ring {
u8 reg_idx; /* physical index of the ring */
bool launchtime_enable; /* true if LaunchTime is enabled */
+ u32 start_time;
+ u32 end_time;
+
/* everything past this point are written often */
u16 next_to_clean;
u16 next_to_use;
@@ -421,6 +425,9 @@ struct igc_adapter {
u32 max_frame_size;
u32 min_frame_size;
+ ktime_t base_time;
+ ktime_t cycle_time;
+
/* OS defined structs */
struct pci_dev *pdev;
/* lock for statistics */