DPDK-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Bruce Richardson <bruce.richardson@intel.com>
To: Anatoly Burakov <anatoly.burakov@intel.com>
Cc: <dev@dpdk.org>, Vladimir Medvedkin <vladimir.medvedkin@intel.com>
Subject: Re: [PATCH v1 1/1] net/iavf: remove RAW flow item support from fsub
Date: Wed, 6 May 2026 16:10:55 +0100	[thread overview]
Message-ID: <aftZ_4yoZWjimNia@bricha3-mobl1.ger.corp.intel.com> (raw)
In-Reply-To: <34827309e49eaba498cfe41500ee8de1fd3a2bb5.1777542270.git.anatoly.burakov@intel.com>

On Thu, Apr 30, 2026 at 10:44:38AM +0100, Anatoly Burakov wrote:
> Currently, no kernel driver implements support for RAW items, so having
> this support in our parser is extra work for no value. Remove the support
> for RAW flow items until such time as there is kernel driver support.
> 
> Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
> ---
>  drivers/net/intel/iavf/iavf_fsub.c | 75 ------------------------------
>  1 file changed, 75 deletions(-)
> 

Acked-by: Bruce Richardson <bruce.richardson@intel.com>

Just to clarify, this is removing raw item support from the flow
subscription part of the driver. Raw flow support remains elsewhere.

With patch description reworded to clarify this,
applied to dpdk-next-net-intel.

Thanks,
/Bruce

> diff --git a/drivers/net/intel/iavf/iavf_fsub.c b/drivers/net/intel/iavf/iavf_fsub.c
> index bfb34695de..a00d02ded5 100644
> --- a/drivers/net/intel/iavf/iavf_fsub.c
> +++ b/drivers/net/intel/iavf/iavf_fsub.c
> @@ -57,7 +57,6 @@ static struct iavf_flow_parser iavf_fsub_parser;
>  
>  static struct
>  iavf_pattern_match_item iavf_fsub_pattern_list[] = {
> -	{iavf_pattern_raw,				IAVF_INSET_NONE,			IAVF_INSET_NONE},
>  	{iavf_pattern_ethertype,			IAVF_SW_INSET_ETHER,			IAVF_INSET_NONE},
>  	{iavf_pattern_eth_ipv4,				IAVF_SW_INSET_MAC_IPV4,			IAVF_INSET_NONE},
>  	{iavf_pattern_eth_vlan_ipv4,			IAVF_SW_INSET_MAC_VLAN_IPV4,		IAVF_INSET_NONE},
> @@ -154,7 +153,6 @@ iavf_fsub_parse_pattern(const struct rte_flow_item pattern[],
>  {
>  	struct virtchnl_proto_hdrs *hdrs = &filter->sub_fltr.proto_hdrs;
>  	enum rte_flow_item_type item_type;
> -	const struct rte_flow_item_raw *raw_spec, *raw_mask;
>  	const struct rte_flow_item_eth *eth_spec, *eth_mask;
>  	const struct rte_flow_item_ipv4 *ipv4_spec, *ipv4_mask;
>  	const struct rte_flow_item_ipv6 *ipv6_spec, *ipv6_mask;
> @@ -166,7 +164,6 @@ iavf_fsub_parse_pattern(const struct rte_flow_item pattern[],
>  	uint64_t outer_input_set = IAVF_INSET_NONE;
>  	uint64_t *input = NULL;
>  	uint16_t input_set_byte = 0;
> -	uint8_t item_num = 0;
>  	uint32_t layer = 0;
>  
>  	for (item = pattern; item->type != RTE_FLOW_ITEM_TYPE_END; item++) {
> @@ -178,79 +175,7 @@ iavf_fsub_parse_pattern(const struct rte_flow_item pattern[],
>  		}
>  
>  		item_type = item->type;
> -		item_num++;
> -
>  		switch (item_type) {
> -		case RTE_FLOW_ITEM_TYPE_RAW: {
> -			raw_spec = item->spec;
> -			raw_mask = item->mask;
> -
> -			if (!raw_spec || !raw_mask) {
> -				PMD_DRV_LOG(ERR, "NULL RAW spec/mask");
> -				rte_flow_error_set(error, EINVAL,
> -						RTE_FLOW_ERROR_TYPE_ITEM,
> -						item, "NULL RAW spec/mask");
> -				return -rte_errno;
> -			}
> -
> -			if (item_num != 1)
> -				return -rte_errno;
> -
> -			if (raw_spec->length != raw_mask->length)
> -				return -rte_errno;
> -
> -			uint16_t pkt_len = 0;
> -			uint16_t tmp_val = 0;
> -			uint8_t tmp = 0;
> -			int i, j;
> -
> -			pkt_len = raw_spec->length;
> -
> -			for (i = 0, j = 0; i < pkt_len; i += 2, j++) {
> -				tmp = raw_spec->pattern[i];
> -				if (tmp >= 'a' && tmp <= 'f')
> -					tmp_val = tmp - 'a' + 10;
> -				if (tmp >= 'A' && tmp <= 'F')
> -					tmp_val = tmp - 'A' + 10;
> -				if (tmp >= '0' && tmp <= '9')
> -					tmp_val = tmp - '0';
> -
> -				tmp_val *= 16;
> -				tmp = raw_spec->pattern[i + 1];
> -				if (tmp >= 'a' && tmp <= 'f')
> -					tmp_val += (tmp - 'a' + 10);
> -				if (tmp >= 'A' && tmp <= 'F')
> -					tmp_val += (tmp - 'A' + 10);
> -				if (tmp >= '0' && tmp <= '9')
> -					tmp_val += (tmp - '0');
> -
> -				hdrs->raw.spec[j] = tmp_val;
> -
> -				tmp = raw_mask->pattern[i];
> -				if (tmp >= 'a' && tmp <= 'f')
> -					tmp_val = tmp - 'a' + 10;
> -				if (tmp >= 'A' && tmp <= 'F')
> -					tmp_val = tmp - 'A' + 10;
> -				if (tmp >= '0' && tmp <= '9')
> -					tmp_val = tmp - '0';
> -
> -				tmp_val *= 16;
> -				tmp = raw_mask->pattern[i + 1];
> -				if (tmp >= 'a' && tmp <= 'f')
> -					tmp_val += (tmp - 'a' + 10);
> -				if (tmp >= 'A' && tmp <= 'F')
> -					tmp_val += (tmp - 'A' + 10);
> -				if (tmp >= '0' && tmp <= '9')
> -					tmp_val += (tmp - '0');
> -
> -				hdrs->raw.mask[j] = tmp_val;
> -			}
> -
> -			hdrs->raw.pkt_len = pkt_len / 2;
> -			hdrs->tunnel_level = 0;
> -			hdrs->count = 0;
> -			return 0;
> -		}
>  		case RTE_FLOW_ITEM_TYPE_ETH:
>  			eth_spec = item->spec;
>  			eth_mask = item->mask;
> -- 
> 2.47.3
> 

      reply	other threads:[~2026-05-06 15:11 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-30  9:44 [PATCH v1 1/1] net/iavf: remove RAW flow item support from fsub Anatoly Burakov
2026-05-06 15:10 ` Bruce Richardson [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=aftZ_4yoZWjimNia@bricha3-mobl1.ger.corp.intel.com \
    --to=bruce.richardson@intel.com \
    --cc=anatoly.burakov@intel.com \
    --cc=dev@dpdk.org \
    --cc=vladimir.medvedkin@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox