* [PATCH iwl-next v1] ice: Add a new counter for Rx EIPE errors
@ 2024-01-03 14:11 Jan Sokolowski
2024-01-04 20:35 ` Simon Horman
2024-01-08 4:40 ` [Intel-wired-lan] " Pucha, HimasekharX Reddy
0 siblings, 2 replies; 3+ messages in thread
From: Jan Sokolowski @ 2024-01-03 14:11 UTC (permalink / raw)
To: intel-wired-lan
Cc: netdev, Aniruddha Paul, Przemek Kitszel, Jan Glaza,
Jan Sokolowski
From: Aniruddha Paul <aniruddha.paul@intel.com>
HW incorrectly reports EIPE errors on encapsulated packets
with L2 padding inside inner packet. HW shows outer UDP/IPV4
packet checksum errors as part of the EIPE flags of the
Rx descriptor. These are reported only if checksum offload
is enabled and L3/L4 parsed flag is valid in Rx descriptor.
When that error is reported by HW, we don't act on it
instead of incrementing main Rx errors statistic as it
would normally happen.
Add a new statistic to count these errors since we still want
to print them.
Signed-off-by: Aniruddha Paul <aniruddha.paul@intel.com>
Reviewed-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
Reviewed-by: Jan Glaza <jan.glaza@intel.com>
Signed-off-by: Jan Sokolowski <jan.sokolowski@intel.com>
---
drivers/net/ethernet/intel/ice/ice.h | 1 +
drivers/net/ethernet/intel/ice/ice_ethtool.c | 1 +
drivers/net/ethernet/intel/ice/ice_txrx_lib.c | 8 ++++++--
3 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/drivers/net/ethernet/intel/ice/ice.h b/drivers/net/ethernet/intel/ice/ice.h
index 367b613d92c0..e841f6c4f1c4 100644
--- a/drivers/net/ethernet/intel/ice/ice.h
+++ b/drivers/net/ethernet/intel/ice/ice.h
@@ -606,6 +606,7 @@ struct ice_pf {
wait_queue_head_t reset_wait_queue;
u32 hw_csum_rx_error;
+ u32 hw_rx_eipe_error;
u32 oicr_err_reg;
struct msi_map oicr_irq; /* Other interrupt cause MSIX vector */
struct msi_map ll_ts_irq; /* LL_TS interrupt MSIX vector */
diff --git a/drivers/net/ethernet/intel/ice/ice_ethtool.c b/drivers/net/ethernet/intel/ice/ice_ethtool.c
index a19b06f18e40..f25e43881df2 100644
--- a/drivers/net/ethernet/intel/ice/ice_ethtool.c
+++ b/drivers/net/ethernet/intel/ice/ice_ethtool.c
@@ -129,6 +129,7 @@ static const struct ice_stats ice_gstrings_pf_stats[] = {
ICE_PF_STAT("rx_oversize.nic", stats.rx_oversize),
ICE_PF_STAT("rx_jabber.nic", stats.rx_jabber),
ICE_PF_STAT("rx_csum_bad.nic", hw_csum_rx_error),
+ ICE_PF_STAT("rx_eipe_error.nic", hw_rx_eipe_error),
ICE_PF_STAT("rx_dropped.nic", stats.eth.rx_discards),
ICE_PF_STAT("rx_crc_errors.nic", stats.crc_errors),
ICE_PF_STAT("illegal_bytes.nic", stats.illegal_bytes),
diff --git a/drivers/net/ethernet/intel/ice/ice_txrx_lib.c b/drivers/net/ethernet/intel/ice/ice_txrx_lib.c
index 839e5da24ad5..f8f1d2bdc1be 100644
--- a/drivers/net/ethernet/intel/ice/ice_txrx_lib.c
+++ b/drivers/net/ethernet/intel/ice/ice_txrx_lib.c
@@ -143,8 +143,12 @@ ice_rx_csum(struct ice_rx_ring *ring, struct sk_buff *skb,
ipv6 = (decoded.outer_ip == ICE_RX_PTYPE_OUTER_IP) &&
(decoded.outer_ip_ver == ICE_RX_PTYPE_OUTER_IPV6);
- if (ipv4 && (rx_status0 & (BIT(ICE_RX_FLEX_DESC_STATUS0_XSUM_IPE_S) |
- BIT(ICE_RX_FLEX_DESC_STATUS0_XSUM_EIPE_S))))
+ if (ipv4 && (rx_status0 & (BIT(ICE_RX_FLEX_DESC_STATUS0_XSUM_EIPE_S)))) {
+ ring->vsi->back->hw_rx_eipe_error++;
+ return;
+ }
+
+ if (ipv4 && (rx_status0 & (BIT(ICE_RX_FLEX_DESC_STATUS0_XSUM_IPE_S))))
goto checksum_fail;
if (ipv6 && (rx_status0 & (BIT(ICE_RX_FLEX_DESC_STATUS0_IPV6EXADD_S))))
--
2.31.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH iwl-next v1] ice: Add a new counter for Rx EIPE errors
2024-01-03 14:11 [PATCH iwl-next v1] ice: Add a new counter for Rx EIPE errors Jan Sokolowski
@ 2024-01-04 20:35 ` Simon Horman
2024-01-08 4:40 ` [Intel-wired-lan] " Pucha, HimasekharX Reddy
1 sibling, 0 replies; 3+ messages in thread
From: Simon Horman @ 2024-01-04 20:35 UTC (permalink / raw)
To: Jan Sokolowski
Cc: intel-wired-lan, netdev, Aniruddha Paul, Przemek Kitszel,
Jan Glaza
On Wed, Jan 03, 2024 at 03:11:15PM +0100, Jan Sokolowski wrote:
> From: Aniruddha Paul <aniruddha.paul@intel.com>
>
> HW incorrectly reports EIPE errors on encapsulated packets
> with L2 padding inside inner packet. HW shows outer UDP/IPV4
> packet checksum errors as part of the EIPE flags of the
> Rx descriptor. These are reported only if checksum offload
> is enabled and L3/L4 parsed flag is valid in Rx descriptor.
>
> When that error is reported by HW, we don't act on it
> instead of incrementing main Rx errors statistic as it
> would normally happen.
>
> Add a new statistic to count these errors since we still want
> to print them.
>
> Signed-off-by: Aniruddha Paul <aniruddha.paul@intel.com>
> Reviewed-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
> Reviewed-by: Jan Glaza <jan.glaza@intel.com>
> Signed-off-by: Jan Sokolowski <jan.sokolowski@intel.com>
Reviewed-by: Simon Horman <horms@kernel.org>
^ permalink raw reply [flat|nested] 3+ messages in thread
* RE: [Intel-wired-lan] [PATCH iwl-next v1] ice: Add a new counter for Rx EIPE errors
2024-01-03 14:11 [PATCH iwl-next v1] ice: Add a new counter for Rx EIPE errors Jan Sokolowski
2024-01-04 20:35 ` Simon Horman
@ 2024-01-08 4:40 ` Pucha, HimasekharX Reddy
1 sibling, 0 replies; 3+ messages in thread
From: Pucha, HimasekharX Reddy @ 2024-01-08 4:40 UTC (permalink / raw)
To: Sokolowski, Jan, intel-wired-lan@lists.osuosl.org
Cc: netdev@vger.kernel.org, Sokolowski, Jan, Kitszel, Przemyslaw,
Glaza, Jan, Aniruddha Paul
> -----Original Message-----
> From: Intel-wired-lan <intel-wired-lan-bounces@osuosl.org> On Behalf Of Jan Sokolowski
> Sent: Wednesday, January 3, 2024 7:41 PM
> To: intel-wired-lan@lists.osuosl.org
> Cc: netdev@vger.kernel.org; Sokolowski, Jan <jan.sokolowski@intel.com>; Kitszel, Przemyslaw <przemyslaw.kitszel@intel.com>; Glaza, Jan <jan.glaza@intel.com>; Aniruddha Paul <aniruddha.paul@intel.com>
> Subject: [Intel-wired-lan] [PATCH iwl-next v1] ice: Add a new counter for Rx EIPE errors
>
> From: Aniruddha Paul <aniruddha.paul@intel.com>
>
> HW incorrectly reports EIPE errors on encapsulated packets
> with L2 padding inside inner packet. HW shows outer UDP/IPV4
> packet checksum errors as part of the EIPE flags of the
> Rx descriptor. These are reported only if checksum offload
> is enabled and L3/L4 parsed flag is valid in Rx descriptor.
>
> When that error is reported by HW, we don't act on it
> instead of incrementing main Rx errors statistic as it
> would normally happen.
>
> Add a new statistic to count these errors since we still want
> to print them.
>
> Signed-off-by: Aniruddha Paul <aniruddha.paul@intel.com>
> Reviewed-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
> Reviewed-by: Jan Glaza <jan.glaza@intel.com>
> Signed-off-by: Jan Sokolowski <jan.sokolowski@intel.com>
> ---
> drivers/net/ethernet/intel/ice/ice.h | 1 +
> drivers/net/ethernet/intel/ice/ice_ethtool.c | 1 +
> drivers/net/ethernet/intel/ice/ice_txrx_lib.c | 8 ++++++--
> 3 files changed, 8 insertions(+), 2 deletions(-)
>
Tested-by: Pucha Himasekhar Reddy <himasekharx.reddy.pucha@intel.com> (A Contingent worker at Intel)
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-01-08 4:40 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-01-03 14:11 [PATCH iwl-next v1] ice: Add a new counter for Rx EIPE errors Jan Sokolowski
2024-01-04 20:35 ` Simon Horman
2024-01-08 4:40 ` [Intel-wired-lan] " Pucha, HimasekharX Reddy
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).