linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andre Guedes <andre.guedes@linux.intel.com>
To: Ivan Khoronzhuk <ivan.khoronzhuk@linaro.org>,
	Murali Karicheri <m-karicheri2@ti.com>,
	Vinicius Costa Gomes <vinicius.gomes@intel.com>
Cc: Po Liu <po.liu@nxp.com>,
	"alexandru.ardelean@analog.com" <alexandru.ardelean@analog.com>,
	"allison@lohutok.net" <allison@lohutok.net>,
	"andrew@lunn.ch" <andrew@lunn.ch>,
	"ayal@mellanox.com" <ayal@mellanox.com>,
	"davem@davemloft.net" <davem@davemloft.net>,
	"f.fainelli@gmail.com" <f.fainelli@gmail.com>,
	"gregkh@linuxfoundation.org" <gregkh@linuxfoundation.org>,
	"hauke.mehrtens@intel.com" <hauke.mehrtens@intel.com>,
	"hkallweit1@gmail.com" <hkallweit1@gmail.com>,
	"jiri@mellanox.com" <jiri@mellanox.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"pablo@netfilter.org" <pablo@netfilter.org>,
	"saeedm@mellanox.com" <saeedm@mellanox.com>,
	"tglx@linutronix.de" <tglx@linutronix.de>,
	Vladimir Oltean <vladimir.oltean@nxp.com>,
	"simon.horman@netronome.com" <simon.horman@netronome.com>,
	Claudiu Manoil <claudiu.manoil@nxp.com>,
	Alexandru Marginean <alexandru.marginean@nxp.com>,
	Xiaoliang Yang <xiaoliang.yang_1@nxp.com>,
	Roy Zang <roy.zang@nxp.com>, Mingkai Hu <mingkai.hu@nxp.com>,
	Jerry Huang <jerry.huang@nxp.com>, Leo Li <leoyang.li@nxp.com>
Subject: Re: [EXT] Re: [v1,net-next, 1/2] ethtool: add setting frame preemption of traffic classes
Date: Wed, 08 Jan 2020 17:07:37 -0800	[thread overview]
Message-ID: <157853205713.36295.17877768211004089754@aguedesl-mac01.jf.intel.com> (raw)
In-Reply-To: <b7e1cb8b-b6b1-c0fa-3864-4036750f3164@ti.com>

Hi,

> >>> 1. add support in taprio to be configured without any schedule in the
> >>> "full offload" mode. In practice, allowing taprio to work somewhat
> >>> similar to (mqprio + frame-preemption), changes in the code should de
> >>> fairly small;
> >>
> >> +
> >>
> >> And if follow mqprio settings logic then preemption also can be enabled
> >> immediately while configuring taprio first time, and similarly new ADMIN
> >> can't change it and can be set w/o preemption option afterwards.
> >>
> >> So that following is correct:
> >>
> >> OPER
> >> $ tc qdisc add dev IFACE parent root handle 100 taprio \
> >>        base-time 10000000 \
> >>        num_tc 3 \
> >>        map 2 2 1 0 2 2 2 2 2 2 2 2 2 2 2 2 \
> >>        queues 1@0 1@1 2@2 \
> >>        preemption 0 1 1 1
> >>        flags 1
> >>
> >> then
> >> ADMIN
> >> $ tc qdisc add dev IFACE parent root handle 100 taprio \
> >>        base-time 12000000 \
> >>        num_tc 3 \
> >>        map 2 2 1 0 2 2 2 2 2 2 2 2 2 2 2 2 \
> >>        queues 1@0 1@1 2@2 \
> >>        preemption 0 1 1 1
> >>        sched-entry S 01 300000 \
> >>        sched-entry S 02 300000 \
> >>        flags 1
> >>
> >> then
> >> ADMIN
> >> $ tc qdisc add dev IFACE parent root handle 100 taprio \
> >>        base-time 13000000 \
> >>        sched-entry S 01 300000 \
> >>        sched-entry S 02 300000 \
> >>        flags 1
> >>
> >> BUT:
> >>
> >> 1) The question is only should it be in this way? I mean preemption to be
> >> enabled immediately? Also should include other parameters like
> >> fragment size.
> > 
> > We can decide what things are allowed/useful here. For example, it might
> > make sense to allow "preemption" to be changed. We can extend taprio to
> > support changing the fragment size, if that makes sense.
> > 
> >>
> >> 2) What if I want to use frame preemption with another "transmission selection
> >> algorithm"? Say another one "time sensitive" - CBS? How is it going to be
> >> stacked?
> > 
> > I am not seeing any (conceptual*) problems when plugging a cbs (for
> > example) qdisc into one of taprio children. Or, are you talking about a
> > more general problem?
> > 
> > * here I am considering that support for taprio without an schedule is
> >   added.
> > 
> >>
> >> In this case ethtool looks better, allowing this "MAC level" feature, to be
> >> configured separately.
> > 
> > My only issue with using ethtool is that then we would have two
> > different interfaces for "complementary" features. And it would make
> > things even harder to configure and debug. The fact that one talks about
> > traffic classes and the other transmission queues doesn't make me more
> > comfortable as well.
> > 
> > On the other hand, as there isn't a way to implement frame preemption in
> > software, I agree that it makes it kind of awkward to have it in the tc
> > subsystem.
> Absolutely. I think frame pre-emption feature flag, per queue express/
> pre-empt state, frag size, timers (hold/release) to be configured
> independently (perhaps through ethtool) and then taprio should check
> this with the lower device and then allow supporting additional Gate
> operations such as Hold/release if supported by underlying device.
> 
> What do you think? Why to abuse tc for this?
> 

After reading all this great discussion and revisiting the 802.1Q and 802.3br
specs, I'm now leaning towards to not coupling Frame Preemption support under
taprio qdisc. Besides what have been discussed, Annex S.2 from 802.1Q-2018
foresees FP without EST so it makes me feel like we should keep them separate.

Regarding the FP configuration knobs, the following seems reasonable to me:
    * Enable/disable FP feature
    * Preemptable queue mapping
    * Fragment size multiplier

I'm not sure about the knob 'timers (hold/release)' described in the quotes
above. I couldn't find a match in the specs. If it refers to 'holdAdvance' and
'releaseAdvance' parameters described in 802.1Q-2018, I believe they are not
configurable. Do we know any hardware where they are configurable?

Regards,

Andre

  reply	other threads:[~2020-01-09  1:07 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-27  9:59 [v1,net-next, 1/2] ethtool: add setting frame preemption of traffic classes Po Liu
2019-11-27  9:59 ` [v1,net-next, 2/2] enetc: implement the enetc 802.1Qbu hardware function Po Liu
2019-11-27 11:00   ` Vladimir Oltean
2019-12-04  1:35   ` Ivan Khoronzhuk
2019-11-27 18:57 ` [v1,net-next, 1/2] ethtool: add setting frame preemption of traffic classes David Miller
2019-12-03 15:11 ` Ivan Khoronzhuk
2019-12-11  2:52 ` Andre Guedes
2019-12-16  7:43   ` [EXT] " Po Liu
2019-12-16 21:44     ` Vinicius Costa Gomes
2019-12-19  0:43       ` Ivan Khoronzhuk
2019-12-19  1:54         ` Vinicius Costa Gomes
2019-12-30 16:56           ` Murali Karicheri
2020-01-17 23:47             ` Vinicius Costa Gomes
2019-12-30 17:03           ` Murali Karicheri
2020-01-09  1:07             ` Andre Guedes [this message]
2020-01-09  8:59               ` Jose Abreu
2020-01-09 18:04                 ` Andre Guedes
2020-01-10 14:35                   ` Jose Abreu
2020-01-10 16:02               ` Vladimir Oltean
2020-01-10 20:59                 ` Andre Guedes
2020-01-09  0:56       ` Andre Guedes
2020-01-18  0:03 ` Vinicius Costa Gomes
2020-01-22 18:10   ` Murali Karicheri
2020-01-23 13:30     ` Vladimir Oltean
2020-01-23 17:50       ` Vinicius Costa Gomes
2020-02-10 20:30         ` Murali Karicheri
2020-02-11 19:22           ` Vinicius Costa Gomes
2020-02-25 17:55             ` Murali Karicheri
2020-02-10 20:17       ` Murali Karicheri
2020-02-21 21:43 ` Vinicius Costa Gomes
2020-02-22  3:26   ` [EXT] " Po Liu
2020-02-25 17:59     ` Murali Karicheri
2020-02-25 17:59       ` Murali Karicheri
2020-02-26  2:01       ` Po Liu
2020-03-12 23:34     ` Vinicius Costa Gomes
2020-03-13  6:00       ` Po Liu
2020-03-18 14:07       ` Murali Karicheri
2020-05-13 14:55         ` Murali Karicheri
2020-05-13 17:21           ` Vinicius Costa Gomes

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=157853205713.36295.17877768211004089754@aguedesl-mac01.jf.intel.com \
    --to=andre.guedes@linux.intel.com \
    --cc=alexandru.ardelean@analog.com \
    --cc=alexandru.marginean@nxp.com \
    --cc=allison@lohutok.net \
    --cc=andrew@lunn.ch \
    --cc=ayal@mellanox.com \
    --cc=claudiu.manoil@nxp.com \
    --cc=davem@davemloft.net \
    --cc=f.fainelli@gmail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=hauke.mehrtens@intel.com \
    --cc=hkallweit1@gmail.com \
    --cc=ivan.khoronzhuk@linaro.org \
    --cc=jerry.huang@nxp.com \
    --cc=jiri@mellanox.com \
    --cc=leoyang.li@nxp.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=m-karicheri2@ti.com \
    --cc=mingkai.hu@nxp.com \
    --cc=netdev@vger.kernel.org \
    --cc=pablo@netfilter.org \
    --cc=po.liu@nxp.com \
    --cc=roy.zang@nxp.com \
    --cc=saeedm@mellanox.com \
    --cc=simon.horman@netronome.com \
    --cc=tglx@linutronix.de \
    --cc=vinicius.gomes@intel.com \
    --cc=vladimir.oltean@nxp.com \
    --cc=xiaoliang.yang_1@nxp.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;
as well as URLs for NNTP newsgroup(s).