All of lore.kernel.org
 help / color / mirror / Atom feed
From: Junjie Cao <junjie.cao@intel.com>
To: Jakub Kicinski <kuba@kernel.org>
Cc: netdev@vger.kernel.org, davem@davemloft.net, edumazet@google.com,
	pabeni@redhat.com, horms@kernel.org, jhs@mojatatu.com,
	jiri@resnulli.us, vinicius.gomes@intel.com, shuah@kernel.org,
	bestswngs@gmail.com, uladzislau.zhauniarovich@gmail.com,
	hdanton@sina.com,
	syzbot+19d01f6082ec61dd45b2@syzkaller.appspotmail.com,
	syzbot+8785aaf121cfb2141e0d@syzkaller.appspotmail.com,
	syzbot+2642f347f7309b4880dc@syzkaller.appspotmail.com,
	linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org
Subject: Re: [PATCH net v2 1/3] net/sched: taprio: catch up in bounded time when the schedule falls behind
Date: Mon, 31 Aug 2026 15:30:25 +0800	[thread overview]
Message-ID: <20260831073025.409831-1-junjie.cao@intel.com> (raw)
In-Reply-To: <20260824185335.2703968-1-kuba@kernel.org>

On Mon, 24 Aug 2026 11:53:35 -0700, Jakub Kicinski <kuba@kernel.org> wrote:
> No Link: tags present in the commit header.

v3 will carry the syzbot tags, including a fourth bucket akpm had syzbot
test this patch alone against:
https://lore.kernel.org/all/6a936ec2.4d659fcc.734b4.0032.GAE@google.com/

> has a second exit condition (--budget), so taprio_catch_up() can return
[...]
> jump makes end == now, and the strict ktime_before(end, now) test then skips

Right. v3 treats end == now as behind, in the walk and its caller, and
the comment mentions the cap.

> case, so a large gate control list turns a previously O(1) critical section
> into an O(num_entries) walk over separately allocated entries.

One lap at most per hold now, versus no bound at all before. Leaving it
as is.

> inoperative. Adding N * cycle_time then shifts the timeline by
> (N * cycle_time) modulo the interval sum, and the gate_close_time[] values

Yes. v3 jumps whole laps instead: min(cycle_time, sum of intervals) on
the entry timeline, cycle_time on cycle_end_time, i.e. exactly what N
restarts of the current code do.

> then terminates on budget exhaustion with end < now, and behind stays below
[...]
> changelog describes does not converge at all. Is the intent that this patch
> depends on the minimum interval patch for the bound to hold?

No. With the jump in laps the residual is under one lap, so the walk
finishes within num_entries steps for any schedule. v3 drops 2/3 anyway.

> be observed torn, which is also pre-existing. Is it worth a comment that
> advance_sched() may legitimately update the currently published entry?

Yes, will add.

  reply	other threads:[~2026-08-31  7:30 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-20  6:27 [PATCH net v2 0/3] net/sched: taprio: fix software schedule livelocks Junjie Cao
2026-08-20  6:27 ` [PATCH net v2 1/3] net/sched: taprio: catch up in bounded time when the schedule falls behind Junjie Cao
2026-08-24 18:53   ` Jakub Kicinski
2026-08-31  7:30     ` Junjie Cao [this message]
2026-08-20  6:27 ` [PATCH net v2 2/3] net/sched: taprio: enforce a minimum interval for software schedules Junjie Cao
2026-08-24 18:53   ` Jakub Kicinski
2026-08-31  7:30     ` Junjie Cao
2026-08-20  6:27 ` [PATCH net v2 3/3] selftests/tc-testing: taprio: add case for the software minimum interval Junjie Cao
2026-08-24 18:53   ` Jakub Kicinski
2026-08-31  7:31     ` Junjie Cao

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=20260831073025.409831-1-junjie.cao@intel.com \
    --to=junjie.cao@intel.com \
    --cc=bestswngs@gmail.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=hdanton@sina.com \
    --cc=horms@kernel.org \
    --cc=jhs@mojatatu.com \
    --cc=jiri@resnulli.us \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=shuah@kernel.org \
    --cc=syzbot+19d01f6082ec61dd45b2@syzkaller.appspotmail.com \
    --cc=syzbot+2642f347f7309b4880dc@syzkaller.appspotmail.com \
    --cc=syzbot+8785aaf121cfb2141e0d@syzkaller.appspotmail.com \
    --cc=uladzislau.zhauniarovich@gmail.com \
    --cc=vinicius.gomes@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 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.