[v1] net/ice: fix wrong FDIR flow type for IPv4 fragment

Message ID 20210602082104.33681-1-ting.xu@intel.com (mailing list archive)
State Accepted, archived
Delegated to: Qi Zhang
Headers
Series [v1] net/ice: fix wrong FDIR flow type for IPv4 fragment |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation success Compilation OK
ci/intel-Testing success Testing PASS
ci/iol-intel-Functional success Functional Testing PASS
ci/iol-intel-Performance success Performance Testing PASS
ci/iol-abi-testing success Testing PASS
ci/iol-testing success Testing PASS

Commit Message

Xu, Ting June 2, 2021, 8:21 a.m. UTC
  When creating FDIR rule and parsing the pattern, if IPv4 fragment type is
detected, the flow type is not changed to ICE_FLTR_PTYPE_FRAG_IPV4 from
ICE_FLTR_PTYPE_NONF_IPV4_OTHER. It will cause profile confilict with
other FDIR rules for IPv4 other type.

Fixes: b7e8781de768 ("net/ice: support flow director for IP fragment packet")
Cc: stable@dpdk.org

Signed-off-by: Ting Xu <ting.xu@intel.com>
---
 drivers/net/ice/ice_fdir_filter.c | 1 +
 1 file changed, 1 insertion(+)
  

Comments

Qi Zhang June 7, 2021, 12:42 a.m. UTC | #1
> -----Original Message-----
> From: Xu, Ting <ting.xu@intel.com>
> Sent: Wednesday, June 2, 2021 4:21 PM
> To: dev@dpdk.org
> Cc: Zhang, Qi Z <qi.z.zhang@intel.com>; Yang, Qiming
> <qiming.yang@intel.com>; Xu, Ting <ting.xu@intel.com>; stable@dpdk.org
> Subject: [PATCH v1] net/ice: fix wrong FDIR flow type for IPv4 fragment
> 
> When creating FDIR rule and parsing the pattern, if IPv4 fragment type is
> detected, the flow type is not changed to ICE_FLTR_PTYPE_FRAG_IPV4 from
> ICE_FLTR_PTYPE_NONF_IPV4_OTHER. It will cause profile confilict with other
> FDIR rules for IPv4 other type.
> 
> Fixes: b7e8781de768 ("net/ice: support flow director for IP fragment packet")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Ting Xu <ting.xu@intel.com>

Acked-by: Qi Zhang <qi.z.zhang@intel.com>

Applied to dpdk-next-net-intel.

Thanks
Qi
  

Patch

diff --git a/drivers/net/ice/ice_fdir_filter.c b/drivers/net/ice/ice_fdir_filter.c
index 092c704503..5cba56918a 100644
--- a/drivers/net/ice/ice_fdir_filter.c
+++ b/drivers/net/ice/ice_fdir_filter.c
@@ -1780,6 +1780,7 @@  ice_fdir_parse_pattern(__rte_unused struct ice_adapter *ad,
 				 * ethertype, if the spec is for all valid
 				 * packet id, set ethertype into input set.
 				 */
+				flow_type = ICE_FLTR_PTYPE_FRAG_IPV4;
 				*input_set |= ICE_INSET_ETHERTYPE;
 				input_set_o |= ICE_INSET_ETHERTYPE;
 			} else if (ipv4_mask->hdr.packet_id == UINT16_MAX) {