public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Michal Swiatkowski <michal.swiatkowski@linux.intel.com>
To: Alexander Lobakin <aleksander.lobakin@intel.com>
Cc: intel-wired-lan@lists.osuosl.org, netdev@vger.kernel.org,
	wojciech.drewek@intel.com, piotr.raczynski@intel.com,
	pmenzel@molgen.mpg.de
Subject: Re: [PATCH net-next v3 3/5] ice: allow matching on meta data
Date: Thu, 6 Apr 2023 13:32:04 +0200	[thread overview]
Message-ID: <ZC6ttC+qX/Z0UZb2@localhost.localdomain> (raw)
In-Reply-To: <8559d4df-71a8-8d4f-b2f6-91f69281f2d9@intel.com>

On Wed, Apr 05, 2023 at 03:31:01PM +0200, Alexander Lobakin wrote:
> From: Michal Swiatkowski <michal.swiatkowski@linux.intel.com>
> Date: Wed, 5 Apr 2023 09:51:11 +0200
> 
> > Add meta data matching criteria in the same place as protocol matching
> > criteria. There is no need to add meta data as special words after
> > parsing all lookups. Trade meta data in the same why as other lookups.
> > 
> > The one difference between meta data lookups and protocol lookups is
> > that meta data doesn't impact how the packets looks like. Because of that
> > ignore it when filling testing packet.
> 
> [...]
> 
> > --- a/drivers/net/ethernet/intel/ice/ice_switch.h
> > +++ b/drivers/net/ethernet/intel/ice/ice_switch.h
> > @@ -186,12 +186,14 @@ struct ice_adv_rule_flags_info {
> >  };
> >  
> >  struct ice_adv_rule_info {
> > +	/* Store metadata values in rule info */
> >  	enum ice_sw_tunnel_type tun_type;
> >  	u16 vlan_type;
> >  	u16 fltr_rule_id;
> >  	u32 priority;
> >  	struct ice_sw_act_ctrl sw_act;
> >  	struct ice_adv_rule_flags_info flags_info;
> > +	u16 src_vsi;
> 
> Minor: since these 2 bytes will introduce 2-byte hole or padding either
> way, I think it's okay to put this field somewhere around rule ID or
> priority, i.e. other primitives. So that when someone is adding new
> short field, he'll see there is a hole and use it. u16 after 2 big
> structures looks a bit off to me, sorry for the initial confusion with
> this "please no holes at all!11" -- it's highly desired, but not by
> sacrificing logical grouping :D
> 

Good point, it looks a little strange, I will move it :)

Thanks,
Michal

> >  };
> >  
> >  /* A collection of one or more four word recipe */
> [...]
> 
> Thanks,
> Olek

  reply	other threads:[~2023-04-06 11:33 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-05  7:51 [PATCH net-next v3 0/5] ice: allow matching on meta data Michal Swiatkowski
2023-04-05  7:51 ` [PATCH net-next v3 1/5] ice: define meta data to match in switch Michal Swiatkowski
2023-04-05  7:51 ` [PATCH net-next v3 2/5] ice: remove redundant Rx field from rule info Michal Swiatkowski
2023-04-05  7:51 ` [PATCH net-next v3 3/5] ice: allow matching on meta data Michal Swiatkowski
2023-04-05 13:31   ` Alexander Lobakin
2023-04-06 11:32     ` Michal Swiatkowski [this message]
2023-04-05  7:51 ` [PATCH net-next v3 4/5] ice: specify field names in ice_prot_ext init Michal Swiatkowski
2023-04-05 13:25   ` Alexander Lobakin
2023-04-06 11:34     ` Michal Swiatkowski
2023-04-05  7:51 ` [PATCH net-next v3 5/5] ice: use src VSI instead of src MAC in slow-path Michal Swiatkowski

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=ZC6ttC+qX/Z0UZb2@localhost.localdomain \
    --to=michal.swiatkowski@linux.intel.com \
    --cc=aleksander.lobakin@intel.com \
    --cc=intel-wired-lan@lists.osuosl.org \
    --cc=netdev@vger.kernel.org \
    --cc=piotr.raczynski@intel.com \
    --cc=pmenzel@molgen.mpg.de \
    --cc=wojciech.drewek@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