Skip to contentSkip to conversation

fm10k: report the receive timestamp in FM10K_CB(skb)->tstamp

PATCH New Jacob Keller 2 participants 4 messages Nov 18, 2016 – Dec 12, 2016

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/2 fm10k: report the receive timestamp in FM10K_CB(skb)->tstamp

This was accidentally removed when we defeatured the full 1588 Clock support. We need to report the Rx descriptor timestamp value so that applications built on top of the IES API can function properly.

Additionally, remove the FM10K_FLAG_RX_TS_ENABLED, as it is not used now that 1588 functionality has been removed.

---
 drivers/net/ethernet/intel/fm10k/fm10k.h      | 5 ++---
 drivers/net/ethernet/intel/fm10k/fm10k_main.c | 2 ++
 2 files changed, 4 insertions(+), 3 deletions(-)
drivers/net/ethernet/intel/fm10k/fm10k.h +2 -3
index 4d19e46f7c55..75d2c8018815 100644
@@ -260,9 +260,8 @@ struct fm10k_intfc {
 #define FM10K_FLAG_RESET_REQUESTED		(u32)(BIT(0))
 #define FM10K_FLAG_RSS_FIELD_IPV4_UDP		(u32)(BIT(1))
 #define FM10K_FLAG_RSS_FIELD_IPV6_UDP		(u32)(BIT(2))
-#define FM10K_FLAG_RX_TS_ENABLED		(u32)(BIT(3))
-#define FM10K_FLAG_SWPRI_CONFIG			(u32)(BIT(4))
-#define FM10K_FLAG_DEBUG_STATS			(u32)(BIT(5))
+#define FM10K_FLAG_SWPRI_CONFIG			(u32)(BIT(3))
+#define FM10K_FLAG_DEBUG_STATS			(u32)(BIT(4))
 	int xcast_mode;
 
 	/* Tx fast path data */
drivers/net/ethernet/intel/fm10k/fm10k_main.c +2 -0
index 8f90c6db53ff..5bb233a9614c 100644
@@ -475,6 +475,8 @@ static unsigned int fm10k_process_skb_fields(struct fm10k_ring *rx_ring,
 
 	fm10k_rx_checksum(rx_ring, rx_desc, skb);
 
+	FM10K_CB(skb)->tstamp = rx_desc->q.timestamp;
+
 	FM10K_CB(skb)->fi.w.vlan = rx_desc->w.vlan;
 
 	skb_record_rx_queue(skb, rx_ring->queue_index);
Signature · 1 line
2.11.0.rc2.152.g4d04e67
#1 lore raw

PATCH 2/2 fm10k: remove FM10K_FLAG_DEBUG_STATS

The debug statistics were removed due to complications with the ethtool statistics API which are not possible to resolve without a new statistics interface. The flag was left behind, but we no longer need it.

---
 drivers/net/ethernet/intel/fm10k/fm10k.h | 1 -
 1 file changed, 1 deletion(-)
drivers/net/ethernet/intel/fm10k/fm10k.h +0 -1
index 75d2c8018815..52b979443cde 100644
@@ -261,7 +261,6 @@ struct fm10k_intfc {
 #define FM10K_FLAG_RSS_FIELD_IPV4_UDP		(u32)(BIT(1))
 #define FM10K_FLAG_RSS_FIELD_IPV6_UDP		(u32)(BIT(2))
 #define FM10K_FLAG_SWPRI_CONFIG			(u32)(BIT(3))
-#define FM10K_FLAG_DEBUG_STATS			(u32)(BIT(4))
 	int xcast_mode;
 
 	/* Tx fast path data */
Signature · 1 line
2.11.0.rc2.152.g4d04e67
#2 lore raw

PATCH 2/2 fm10k: remove FM10K_FLAG_DEBUG_STATS

-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Jacob Keller
Sent: Friday, November 18, 2016 9:46 AM
To: Intel Wired LAN <[email protected]>
Subject: [Intel-wired-lan] [PATCH 2/2] fm10k: remove FM10K_FLAG_DEBUG_STATS

The debug statistics were removed due to complications with the ethtool statistics API which are not possible to resolve without a new statistics interface. The flag was left behind, but we no longer need it.

---

#3 lore raw

PATCH 1/2 fm10k: report the receive timestamp in FM10K_CB(skb)->tstamp

In reply to Jacob Keller

-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Jacob Keller
Sent: Friday, November 18, 2016 9:46 AM
To: Intel Wired LAN <[email protected]>
Subject: [Intel-wired-lan] [PATCH 1/2] fm10k: report the receive timestamp in FM10K_CB(skb)->tstamp

This was accidentally removed when we defeatured the full 1588 Clock support. We need to report the Rx descriptor timestamp value so that applications built on top of the IES API can function properly.

Additionally, remove the FM10K_FLAG_RX_TS_ENABLED, as it is not used now that 1588 functionality has been removed.

---