aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/intel/ice/ice_ethtool.c
diff options
context:
space:
mode:
authorJacob Keller <jacob.e.keller@intel.com>2022-07-27 16:15:58 -0700
committerTony Nguyen <anthony.l.nguyen@intel.com>2022-08-16 09:04:37 -0700
commitcf6b82fd3fbc8f747333ef5005798a90b5345bd4 (patch)
tree320b9e46fd851ea5e8fe6d5f4e4a6277cd314884 /drivers/net/ethernet/intel/ice/ice_ethtool.c
parentice: set tx_tstamps when creating new Tx rings via ethtool (diff)
downloadlinux-dev-cf6b82fd3fbc8f747333ef5005798a90b5345bd4.tar.xz
linux-dev-cf6b82fd3fbc8f747333ef5005798a90b5345bd4.zip
ice: initialize cached_phctime when creating Rx rings
When we create new Rx rings, the cached_phctime field is zero initialized. This could result in incorrect timestamp reporting due to the cached value not yet being updated. Although a background task will periodically update the cached value, ensure it matches the existing cached value in the PF structure at ring initialization. Signed-off-by: Jacob Keller <jacob.e.keller@intel.com> Tested-by: Gurucharan <gurucharanx.g@intel.com> (A Contingent worker at Intel) Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
Diffstat (limited to 'drivers/net/ethernet/intel/ice/ice_ethtool.c')
-rw-r--r--drivers/net/ethernet/intel/ice/ice_ethtool.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/intel/ice/ice_ethtool.c b/drivers/net/ethernet/intel/ice/ice_ethtool.c
index bbf6a300078e..3a18762cc38f 100644
--- a/drivers/net/ethernet/intel/ice/ice_ethtool.c
+++ b/drivers/net/ethernet/intel/ice/ice_ethtool.c
@@ -2885,6 +2885,7 @@ process_rx:
/* clone ring and setup updated count */
rx_rings[i] = *vsi->rx_rings[i];
rx_rings[i].count = new_rx_cnt;
+ rx_rings[i].cached_phctime = pf->ptp.cached_phc_time;
rx_rings[i].desc = NULL;
rx_rings[i].rx_buf = NULL;
/* this is to allow wr32 to have something to write to