All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jesus Sanchez-Palencia <jesus.sanchez-palencia@intel.com>
To: Jamal Hadi Salim <jhs@mojatatu.com>, netdev@vger.kernel.org
Cc: xiyou.wangcong@gmail.com, jiri@resnulli.us,
	vinicius.gomes@intel.com, richardcochran@gmail.com,
	intel-wired-lan@lists.osuosl.org, anna-maria@linutronix.de,
	henrik@austad.us, tglx@linutronix.de, john.stultz@linaro.org,
	andre.guedes@intel.com, ivan.briano@intel.com,
	levi.pearson@harman.com
Subject: Re: [RFC v2 net-next 06/10] net/sched: Introduce the TBS Qdisc
Date: Tue, 23 Jan 2018 13:45:16 -0800	[thread overview]
Message-ID: <dd0c274a-2a78-8e84-bfb6-d669b26fa5ba@intel.com> (raw)
In-Reply-To: <8ca1bbaa-80fb-ef09-649d-0c143a48d9dc@mojatatu.com>

Hi,


On 01/18/2018 05:44 AM, Jamal Hadi Salim wrote:
> One more comment:
> Probably try to run a test with a very small delta with
> no offload (probably using something like prio as the root qdisc)
> and dump the stats.
> My gut feeling is your accounting of the backlog in particular is off.


You were right, thanks. It'll be fixed on our next version.

Regards,
Jesus


> 
> cheers,
> jamal
> 
> On 18-01-18 08:35 AM, Jamal Hadi Salim wrote:
>> On 18-01-17 06:06 PM, Jesus Sanchez-Palencia wrote:
>>> From: Vinicius Costa Gomes <vinicius.gomes@intel.com>
>>>
>>> TBS (Time Based Scheduler) uses the information added earlier in this
>>> series (the socket option SO_TXTIME and the new role of
>>> sk_buff->tstamp) to schedule traffic transmission based on absolute
>>> time.
>>>
>>> For some workloads, just bandwidth enforcement is not enough, and
>>> precise control of the transmission of packets is necessary.
>>>
>>> Example:
>>>
>>> $ tc qdisc replace dev enp2s0 parent root handle 100 mqprio num_tc 3 \
>>
>> handle 100:0 ?
>>
>>>             map 2 2 1 0 2 2 2 2 2 2 2 2 2 2 2 2 queues 1@0 1@1 2@2 hw 0
>>>
>>> $ tc qdisc add dev enp2s0 parent 100:1 tbs delta 60000 clockid 11 offload 1
>>>
>>>
>>> In this example, the Qdisc will try to enable offloading (offload 1)
>>> the control of the transmission time to the network adapter, the
>>> time stamp in socket are in reference to the clockid '11' (CLOCK_TAI)
>>> and packets leave the Qdisc "delta" (60000) nanoseconds before its
>>> transmission time.
>>>
>>
>>
>>> When offloading is disabled, the network adapter will ignore the
>>> sk_buff time stamp, and so, the transmission time will be only "best
>>> effort" from the Qdisc.
>>>
>>
>> General comments:
>> 1) iproute2: Avoid magic numbers like 1 or 11 please; "offload"
>> (without 1) and "TAI" will be more human friendly.
>>
>> 2) Experience shows that adding padding fields in the control structs
>> implies they will _never ever_ be used. That was not design intent
>> for netlink but over years shit like that has happened.
>> Maybe look at using a 32 bitmap? It is more "future proof".
>> You seem to only have 2-3 flags but it gives you opportunity
>> to add more changes later. If you are 100% sure youll never need
>> it - then maybe just move the tc_tbs_qopt::offload to the end of
>> of the struct.
>>
>> 3)It would be helpful for debugging to increment some stats other
>> than drop counters on enqueu/dequeue obsolete packet drop. Maybe use
>> overlimits for the dequeu drops (in addition)?
>>
>> 4) I may be misreading things - but did you need to reset the
>> watchdog on dequeue? It is already being kicked for every incoming packet.
>>
>> cheers,
>> jamal
> 

WARNING: multiple messages have this Message-ID (diff)
From: Jesus Sanchez-Palencia <jesus.sanchez-palencia@intel.com>
To: intel-wired-lan@osuosl.org
Subject: [Intel-wired-lan] [RFC v2 net-next 06/10] net/sched: Introduce the TBS Qdisc
Date: Tue, 23 Jan 2018 13:45:16 -0800	[thread overview]
Message-ID: <dd0c274a-2a78-8e84-bfb6-d669b26fa5ba@intel.com> (raw)
In-Reply-To: <8ca1bbaa-80fb-ef09-649d-0c143a48d9dc@mojatatu.com>

Hi,


On 01/18/2018 05:44 AM, Jamal Hadi Salim wrote:
> One more comment:
> Probably try to run a test with a very small delta with
> no offload (probably using something like prio as the root qdisc)
> and dump the stats.
> My gut feeling is your accounting of the backlog in particular is off.


You were right, thanks. It'll be fixed on our next version.

Regards,
Jesus


> 
> cheers,
> jamal
> 
> On 18-01-18 08:35 AM, Jamal Hadi Salim wrote:
>> On 18-01-17 06:06 PM, Jesus Sanchez-Palencia wrote:
>>> From: Vinicius Costa Gomes <vinicius.gomes@intel.com>
>>>
>>> TBS (Time Based Scheduler) uses the information added earlier in this
>>> series (the socket option SO_TXTIME and the new role of
>>> sk_buff->tstamp) to schedule traffic transmission based on absolute
>>> time.
>>>
>>> For some workloads, just bandwidth enforcement is not enough, and
>>> precise control of the transmission of packets is necessary.
>>>
>>> Example:
>>>
>>> $ tc qdisc replace dev enp2s0 parent root handle 100 mqprio num_tc 3 \
>>
>> handle 100:0 ?
>>
>>> ??????????? map 2 2 1 0 2 2 2 2 2 2 2 2 2 2 2 2 queues 1 at 0 1 at 1 2 at 2 hw 0
>>>
>>> $ tc qdisc add dev enp2s0 parent 100:1 tbs delta 60000 clockid 11 offload 1
>>>
>>>
>>> In this example, the Qdisc will try to enable offloading (offload 1)
>>> the control of the transmission time to the network adapter, the
>>> time stamp in socket are in reference to the clockid '11' (CLOCK_TAI)
>>> and packets leave the Qdisc "delta" (60000) nanoseconds before its
>>> transmission time.
>>>
>>
>>
>>> When offloading is disabled, the network adapter will ignore the
>>> sk_buff time stamp, and so, the transmission time will be only "best
>>> effort" from the Qdisc.
>>>
>>
>> General comments:
>> 1) iproute2: Avoid magic numbers like 1 or 11 please; "offload"
>> (without 1) and "TAI" will be more human friendly.
>>
>> 2) Experience shows that adding padding fields in the control structs
>> implies they will _never ever_ be used. That was not design intent
>> for netlink but over years shit like that has happened.
>> Maybe look at using a 32 bitmap? It is more "future proof".
>> You seem to only have 2-3 flags but it gives you opportunity
>> to add more changes later. If you are 100% sure youll never need
>> it - then maybe just move the tc_tbs_qopt::offload to the end of
>> of the struct.
>>
>> 3)It would be helpful for debugging to increment some stats other
>> than drop counters on enqueu/dequeue obsolete packet drop. Maybe use
>> overlimits for the dequeu drops (in addition)?
>>
>> 4) I may be misreading things - but did you need to reset the
>> watchdog on dequeue? It is already being kicked for every incoming packet.
>>
>> cheers,
>> jamal
> 

  reply	other threads:[~2018-01-23 21:46 UTC|newest]

Thread overview: 86+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-17 23:06 [RFC v2 net-next 00/10] Time based packet transmission Jesus Sanchez-Palencia
2018-01-17 23:06 ` [Intel-wired-lan] " Jesus Sanchez-Palencia
2018-01-17 23:06 ` [RFC v2 net-next 01/10] net: Add a new socket option for a future transmit time Jesus Sanchez-Palencia
2018-01-17 23:06   ` [Intel-wired-lan] " Jesus Sanchez-Palencia
2018-01-18  8:42   ` Miroslav Lichvar
2018-01-18  8:42     ` Miroslav Lichvar
2018-01-18 17:13     ` Richard Cochran
2018-01-18 17:13       ` Richard Cochran
2018-02-01  0:49       ` Jesus Sanchez-Palencia
2018-02-01  0:49         ` Jesus Sanchez-Palencia
2018-02-01  4:16         ` Richard Cochran
2018-02-01  4:16           ` Richard Cochran
2018-02-01  9:27         ` Miroslav Lichvar
2018-02-01  9:27           ` Miroslav Lichvar
2018-02-01 20:55           ` Jesus Sanchez-Palencia
2018-02-01 20:55             ` Jesus Sanchez-Palencia
2018-01-23 21:22     ` Vinicius Costa Gomes
2018-01-23 21:22       ` Vinicius Costa Gomes
2018-01-24  3:04       ` Richard Cochran
2018-01-24  3:04         ` Richard Cochran
2018-01-24 22:46         ` Vinicius Costa Gomes
2018-01-24 22:46           ` Vinicius Costa Gomes
2018-01-26  2:12           ` Richard Cochran
2018-01-26  2:12             ` Richard Cochran
2018-02-12 22:39     ` Jesus Sanchez-Palencia
2018-02-12 22:39       ` Jesus Sanchez-Palencia
2018-02-13  9:56       ` Miroslav Lichvar
2018-02-13  9:56         ` Miroslav Lichvar
2018-01-18 17:11   ` Richard Cochran
2018-01-18 17:11     ` [Intel-wired-lan] " Richard Cochran
2018-01-23 18:12     ` Jesus Sanchez-Palencia
2018-01-23 18:12       ` [Intel-wired-lan] " Jesus Sanchez-Palencia
2018-01-19 21:15   ` Willem de Bruijn
2018-01-19 21:15     ` [Intel-wired-lan] " Willem de Bruijn
2018-01-20  2:09     ` Richard Cochran
2018-01-20  2:09       ` [Intel-wired-lan] " Richard Cochran
2018-01-25  9:12       ` Miroslav Lichvar
2018-01-25  9:12         ` Miroslav Lichvar
2018-01-25 16:52         ` Richard Cochran
2018-01-25 16:52           ` Richard Cochran
2018-01-23 18:24     ` Jesus Sanchez-Palencia
2018-01-23 18:24       ` [Intel-wired-lan] " Jesus Sanchez-Palencia
2018-01-23 20:02       ` Willem de Bruijn
2018-01-23 20:02         ` [Intel-wired-lan] " Willem de Bruijn
2018-01-17 23:06 ` [RFC v2 net-next 02/10] net: ipv4: raw: Hook into time based transmission Jesus Sanchez-Palencia
2018-01-17 23:06   ` [Intel-wired-lan] " Jesus Sanchez-Palencia
2018-01-18  0:28   ` Eric Dumazet
2018-01-18  0:28     ` [Intel-wired-lan] " Eric Dumazet
2018-01-17 23:06 ` [RFC v2 net-next 03/10] net: ipv4: udp: " Jesus Sanchez-Palencia
2018-01-17 23:06   ` [Intel-wired-lan] " Jesus Sanchez-Palencia
2018-01-17 23:06 ` [RFC v2 net-next 04/10] net: packet: " Jesus Sanchez-Palencia
2018-01-17 23:06   ` [Intel-wired-lan] " Jesus Sanchez-Palencia
2018-01-17 23:06 ` [RFC v2 net-next 05/10] net/sched: Allow creating a Qdisc watchdog with other clocks Jesus Sanchez-Palencia
2018-01-17 23:06   ` [Intel-wired-lan] " Jesus Sanchez-Palencia
2018-01-17 23:06 ` [RFC v2 net-next 06/10] net/sched: Introduce the TBS Qdisc Jesus Sanchez-Palencia
2018-01-17 23:06   ` [Intel-wired-lan] " Jesus Sanchez-Palencia
2018-01-18 13:35   ` Jamal Hadi Salim
2018-01-18 13:35     ` [Intel-wired-lan] " Jamal Hadi Salim
2018-01-18 13:44     ` Jamal Hadi Salim
2018-01-18 13:44       ` [Intel-wired-lan] " Jamal Hadi Salim
2018-01-23 21:45       ` Jesus Sanchez-Palencia [this message]
2018-01-23 21:45         ` Jesus Sanchez-Palencia
2018-01-18 17:18     ` Richard Cochran
2018-01-18 17:18       ` [Intel-wired-lan] " Richard Cochran
2018-01-23 22:01     ` Jesus Sanchez-Palencia
2018-01-23 22:01       ` [Intel-wired-lan] " Jesus Sanchez-Palencia
2018-01-19 21:18   ` Willem de Bruijn
2018-01-19 21:18     ` [Intel-wired-lan] " Willem de Bruijn
2018-01-17 23:06 ` [RFC v2 net-next 07/10] igb: Refactor igb_configure_cbs() Jesus Sanchez-Palencia
2018-01-17 23:06   ` [Intel-wired-lan] " Jesus Sanchez-Palencia
2018-01-17 23:06 ` [RFC v2 net-next 08/10] igb: Only change Tx arbitration when CBS is on Jesus Sanchez-Palencia
2018-01-17 23:06   ` [Intel-wired-lan] " Jesus Sanchez-Palencia
2018-01-17 23:06 ` [RFC v2 net-next 09/10] igb: Refactor igb_offload_cbs() Jesus Sanchez-Palencia
2018-01-17 23:06   ` [Intel-wired-lan] " Jesus Sanchez-Palencia
2018-01-17 23:06 ` [RFC v2 net-next 10/10] igb: Add support for TBS offload Jesus Sanchez-Palencia
2018-01-17 23:06   ` [Intel-wired-lan] " Jesus Sanchez-Palencia
2018-01-23  5:23 ` [RFC v2 net-next 00/10] Time based packet transmission Richard Cochran
2018-01-23  5:23   ` [Intel-wired-lan] " Richard Cochran
2018-01-23  5:26   ` Richard Cochran
2018-01-23  5:26     ` [Intel-wired-lan] " Richard Cochran
2018-01-23 18:07     ` Jesus Sanchez-Palencia
2018-01-23 18:07       ` [Intel-wired-lan] " Jesus Sanchez-Palencia
2018-01-24  1:43 ` Levi Pearson
2018-01-24  1:43   ` [Intel-wired-lan] " Levi Pearson
2018-01-27  0:04   ` Jesus Sanchez-Palencia
2018-01-27  0:04     ` [Intel-wired-lan] " Jesus Sanchez-Palencia

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=dd0c274a-2a78-8e84-bfb6-d669b26fa5ba@intel.com \
    --to=jesus.sanchez-palencia@intel.com \
    --cc=andre.guedes@intel.com \
    --cc=anna-maria@linutronix.de \
    --cc=henrik@austad.us \
    --cc=intel-wired-lan@lists.osuosl.org \
    --cc=ivan.briano@intel.com \
    --cc=jhs@mojatatu.com \
    --cc=jiri@resnulli.us \
    --cc=john.stultz@linaro.org \
    --cc=levi.pearson@harman.com \
    --cc=netdev@vger.kernel.org \
    --cc=richardcochran@gmail.com \
    --cc=tglx@linutronix.de \
    --cc=vinicius.gomes@intel.com \
    --cc=xiyou.wangcong@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.