dev.dpdk.org archive mirror
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
To: "Chen, Jing D" <jing.d.chen-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
Cc: dev-VfR2kkLFssw@public.gmane.org
Subject: Re: [PATCH 1/6] ether: enhancement for VMDQ support
Date: Wed, 15 Oct 2014 11:59:54 +0200	[thread overview]
Message-ID: <2528969.6AYAK7jRAV@xps13> (raw)
In-Reply-To: <4341B239C0EFF9468EE453F9E9F4604D015F36E1-E2R4CRU6q/6iAffOGbnezLfspsVTdybXVpNB7YpNyf8@public.gmane.org>

2014-10-15 09:47, Chen, Jing D:
> From: Thomas Monjalon [mailto:thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org]
> > 2014-10-15 06:59, Chen, Jing D:
> > > From: Thomas Monjalon [mailto:thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org]
> > > > >  enum rte_eth_rx_mq_mode {
> > > > > -	ETH_MQ_RX_NONE = 0,  /**< None of DCB,RSS or VMDQ mode */
> > > > > -
> > > > > -	ETH_MQ_RX_RSS,       /**< For RX side, only RSS is on */
> > > > > -	ETH_MQ_RX_DCB,       /**< For RX side,only DCB is on. */
> > > > > -	ETH_MQ_RX_DCB_RSS,   /**< Both DCB and RSS enable */
> > > > > -
> > > > > -	ETH_MQ_RX_VMDQ_ONLY, /**< Only VMDQ, no RSS nor DCB */
> > > > > -	ETH_MQ_RX_VMDQ_RSS,  /**< RSS mode with VMDQ */
> > > > > -	ETH_MQ_RX_VMDQ_DCB,  /**< Use VMDQ+DCB to route traffic to queues */
> > > > > -	ETH_MQ_RX_VMDQ_DCB_RSS, /**< Enable both VMDQ and DCB in VMDq */
> > > > > +	/**< None of DCB,RSS or VMDQ mode */
> > > > > +	ETH_MQ_RX_NONE = 0,
> > > > > +
> > > > > +	/**< For RX side, only RSS is on */
> > > > > +	ETH_MQ_RX_RSS = ETH_MQ_RX_RSS_FLAG,
> > > > > +	/**< For RX side,only DCB is on. */
> > > > > +	ETH_MQ_RX_DCB = ETH_MQ_RX_DCB_FLAG,
> > > > > +	/**< Both DCB and RSS enable */
> > > > > +	ETH_MQ_RX_DCB_RSS = ETH_MQ_RX_RSS_FLAG | ETH_MQ_RX_DCB_FLAG,
> > > > > +
> > > > > +	/**< Only VMDQ, no RSS nor DCB */
> > > > > +	ETH_MQ_RX_VMDQ_ONLY = ETH_MQ_RX_VMDQ_FLAG,
> > > > > +	/**< RSS mode with VMDQ */
> > > > > +	ETH_MQ_RX_VMDQ_RSS = ETH_MQ_RX_RSS_FLAG | ETH_MQ_RX_VMDQ_FLAG,
> > > > > +	/**< Use VMDQ+DCB to route traffic to queues */
> > > > > +	ETH_MQ_RX_VMDQ_DCB = ETH_MQ_RX_VMDQ_FLAG | ETH_MQ_RX_DCB_FLAG,
> > > > > +	/**< Enable both VMDQ and DCB in VMDq */
> > > > > +	ETH_MQ_RX_VMDQ_DCB_RSS = ETH_MQ_RX_RSS_FLAG | ETH_MQ_RX_DCB_FLAG |
> > > > > +				 ETH_MQ_RX_VMDQ_FLAG,
> > > > >  };
> > > >
> > > > Why not simply remove all these combinations and keep only flags?
> > > > Please keep it simple.
> > >
> > > One reason is back-compatibility.
> > 
> > I understand but I think we should prefer cleanup.
> > As there is no way to advertise deprecation of flags, it should be
> > simply removed.
> > 
> > > Another reason is not all NIC driver support all the combined modes, only
> > > limited sets
> > > driver supported. Under this condition, it's better to use the combination
> > > definition
> > > (VMDQ_DCB, DCB_RSS, etc) to let driver check whether it supports.
> > 
> > Driver can do the same checks with simple flags and it's probably simpler
> > (e.g. a driver which doesn't support VMDQ had no need to check all VMDQ
> > combinations).
[...]
> case ETH_MQ_RX_VMDQ_FLAG |  ETH_MQ_RX_DCB_FLAG:
[...] 
> Won't it look weird for reading? In fact, it's more complex in
> rte_eth_dev_check_mq_mode(),
> With the change, the code will look weird.

I think that defining all combinations of flags is more weird.

> In fact, I don't see benefit with the change to old code. New PMD driver
> can use simple flag while old driver (IXGBE/IGB) can use original definition.

If nobody else agree with my point of view, I'll accept yours.

-- 
Thomas

  parent reply	other threads:[~2014-10-15  9:59 UTC|newest]

Thread overview: 45+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-23 13:14 [PATCH 0/6] i40e VMDQ support Chen Jing D(Mark)
     [not found] ` <1411478047-1251-1-git-send-email-jing.d.chen-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-09-23 13:14   ` [PATCH 1/6] ether: enhancement for " Chen Jing D(Mark)
     [not found]     ` <1411478047-1251-2-git-send-email-jing.d.chen-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-10-14 14:09       ` Thomas Monjalon
2014-10-15  6:59         ` Chen, Jing D
     [not found]           ` <4341B239C0EFF9468EE453F9E9F4604D015F35FE-E2R4CRU6q/6iAffOGbnezLfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2014-10-15  8:10             ` Thomas Monjalon
2014-10-15  9:47               ` Chen, Jing D
     [not found]                 ` <4341B239C0EFF9468EE453F9E9F4604D015F36E1-E2R4CRU6q/6iAffOGbnezLfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2014-10-15  9:59                   ` Thomas Monjalon [this message]
2014-10-16 10:07       ` [PATCH v2 0/6] i40e " Chen Jing D(Mark)
     [not found]         ` <1413454046-13407-1-git-send-email-jing.d.chen-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-10-16 10:07           ` [PATCH v2 1/6] ether: enhancement for " Chen Jing D(Mark)
     [not found]             ` <1413454046-13407-2-git-send-email-jing.d.chen-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-11-03 22:17               ` Thomas Monjalon
2014-11-04  5:50                 ` Chen, Jing D
     [not found]                   ` <4341B239C0EFF9468EE453F9E9F4604D016061A7-E2R4CRU6q/6iAffOGbnezLfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2014-11-04  8:53                     ` Thomas Monjalon
2014-11-04  8:59                       ` Chen, Jing D
2014-10-16 10:07           ` [PATCH v2 2/6] igb: change for VMDQ arguments expansion Chen Jing D(Mark)
     [not found]             ` <1413454046-13407-3-git-send-email-jing.d.chen-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-11-03 18:37               ` Thomas Monjalon
2014-11-04  5:26                 ` Chen, Jing D
2014-10-16 10:07           ` [PATCH v2 3/6] ixgbe: " Chen Jing D(Mark)
2014-10-16 10:07           ` [PATCH v2 4/6] i40e: add VMDQ support Chen Jing D(Mark)
     [not found]             ` <1413454046-13407-5-git-send-email-jing.d.chen-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-11-03 18:33               ` Thomas Monjalon
2014-11-04  5:22                 ` Chen, Jing D
2014-10-16 10:07           ` [PATCH v2 5/6] i40e: macaddr add/del enhancement Chen Jing D(Mark)
2014-10-16 10:07           ` [PATCH v2 6/6] i40e: Add full VMDQ pools support Chen Jing D(Mark)
2014-10-21  3:30           ` [PATCH v2 0/6] i40e VMDQ support Cao, Min
2014-11-03  7:54           ` Chen, Jing D
2014-11-04 10:01       ` [PATCH v3 " Chen Jing D(Mark)
     [not found]         ` <1415095289-28961-1-git-send-email-jing.d.chen-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-11-04 10:01           ` [PATCH v3 1/6] ether: enhancement for " Chen Jing D(Mark)
2014-11-04 10:01           ` [PATCH v3 2/6] igb: change for VMDQ arguments expansion Chen Jing D(Mark)
2014-11-04 10:01           ` [PATCH v3 3/6] ixgbe: " Chen Jing D(Mark)
2014-11-04 10:01           ` [PATCH v3 4/6] i40e: add VMDQ support Chen Jing D(Mark)
2014-11-04 10:01           ` [PATCH v3 5/6] i40e: macaddr add/del enhancement Chen Jing D(Mark)
2014-11-04 10:01           ` [PATCH v3 6/6] i40e: Add full VMDQ pools support Chen Jing D(Mark)
2014-11-04 11:19           ` [PATCH v3 0/6] i40e VMDQ support Ananyev, Konstantin
     [not found]             ` <2601191342CEEE43887BDE71AB977258213A249C-kPTMFJFq+rEu0RiL9chJVbfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2014-11-04 23:17               ` Thomas Monjalon
2014-12-11  6:09           ` Cao, Min
2014-09-23 13:14   ` [PATCH 2/6] igb: change for VMDQ arguments expansion Chen Jing D(Mark)
2014-09-23 13:14   ` [PATCH 3/6] ixgbe: " Chen Jing D(Mark)
2014-09-23 13:14   ` [PATCH 4/6] i40e: add VMDQ support Chen Jing D(Mark)
     [not found]     ` <1411478047-1251-5-git-send-email-jing.d.chen-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-10-13 16:14       ` De Lara Guarch, Pablo
2014-09-23 13:14   ` [PATCH 5/6] i40e: macaddr add/del enhancement Chen Jing D(Mark)
     [not found]     ` <1411478047-1251-6-git-send-email-jing.d.chen-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-10-14 14:25       ` Thomas Monjalon
2014-10-15  7:01         ` Chen, Jing D
2014-09-23 13:14   ` [PATCH 6/6] i40e: Add full VMDQ pools support Chen Jing D(Mark)
2014-10-10 10:45   ` [PATCH 0/6] i40e VMDQ support Ananyev, Konstantin
2014-10-14  8:27   ` Chen, Jing D
2014-10-21  3:30   ` Cao, Min

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=2528969.6AYAK7jRAV@xps13 \
    --to=thomas.monjalon-pdr9zngts4eavxtiumwx3w@public.gmane.org \
    --cc=dev-VfR2kkLFssw@public.gmane.org \
    --cc=jing.d.chen-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org \
    /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;
as well as URLs for NNTP newsgroup(s).