From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from r3-22.sinamail.sina.com.cn (r3-22.sinamail.sina.com.cn [202.108.3.22]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2DFDB1F4634 for ; Mon, 17 Aug 2026 00:35:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=202.108.3.22 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786926937; cv=none; b=DPvIZ8oa5Q6PIBsXxcpcyEABgK/A56GokYRUn66l9t4wv79HjoaD0mdfiw61efkQUmjmpfh6R17xFzPw60o/b8nwVRgwRumHwjQpT09zSM27+msRZeVBC3hU+34XoRokvcdAkjDR3ybWAGCNAUHZMScedtxaCVIMLUEzYFOkZs0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786926937; c=relaxed/simple; bh=1f1Z4MBW/XoJe2K9oEW57m5NLO5VbDoaOLqmmuNtlg0=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=Ye73qheKiNT83BQsiuadz0p71Gri0Isqmc4mOvRF7WdFrjIsxrIOzUZ8k96NuD4OyzpuFQXurTMw2ZfMNITLvpF0+MppBFpuuCk0aUN10OwEePWm3dwIMzM04tAf8FXjMj3z49isSUJBc09jb6Dd1wuif+0U2TlRE4LZrK8WqpM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=sina.com; spf=pass smtp.mailfrom=sina.com; dkim=pass (1024-bit key) header.d=sina.com header.i=@sina.com header.b=g8sKVWJd; arc=none smtp.client-ip=202.108.3.22 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=sina.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=sina.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=sina.com header.i=@sina.com header.b="g8sKVWJd" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sina.com; s=201208; t=1786926933; bh=6+xXhRkohpflekplecwqyMdPW0YNzOLFlu7gBLbhZP4=; h=From:Subject:Date:Message-ID; b=g8sKVWJdIw6vTdGhE5Lp9vjF9DZ85NB6z2r550bNPNHn93SL4uEtfyu/QIsh0ck+p zVgHRl+DGckVwallj/hbx4CfjkpQnWoktoz/9H586KxupJwRDJiSjauskjhNBuBM7n //di8IfBzXiFjwY1QaxsU3TR90wPwTKfE9MdjSCc= X-SMAIL-HELO: localhost.localdomain Received: from unknown (HELO localhost.localdomain)([221.216.154.155]) by sina.com (10.54.253.33) with ESMTP id 6A82574800002A32; Mon, 17 Aug 2026 08:35:23 +0800 (CST) X-Sender: hdanton@sina.com X-Auth-ID: hdanton@sina.com Authentication-Results: sina.com; spf=none smtp.mailfrom=hdanton@sina.com; dkim=none header.i=none; dmarc=none action=none header.from=hdanton@sina.com X-SMAIL-MID: 3469806685492 X-SMAIL-UIID: C6ACEC40819142E59DADD02F0ACED4A6-20260817-083523-1 From: Hillf Danton To: Junjie Cao Cc: Uladzislau Zhauniarovich , Vinicius Costa Gomes , Eric Dumazet , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, syzbot+19d01f6082ec61dd45b2@syzkaller.appspotmail.com Subject: Re: [PATCH] net/sched: taprio: enforce minimum software scheduling interval Date: Mon, 17 Aug 2026 08:35:13 +0800 Message-ID: <20260817003514.1241-1-hdanton@sina.com> In-Reply-To: <20260816142847.227167-1-junjie.cao@intel.com> References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit On Sun, 16 Aug 2026 22:28:47 +0800 Junjie Cao wrote: > On Fri, 14 Aug 2026, Hillf Danton wrote: > > Better if you specify why interval like 2us is ruled out. > > The yardstick is the service cost of one expiry. On a release build I > see ~5.1M local timer interrupts in 5s on the owning CPU for a 700ns > single-entry schedule on veth, so the whole per-expiry service path is > around a microsecond; Uladzislau estimated ~10us per invocation on the > syzbot debug config earlier in the moderation thread. A 2us interval > still livelocks a debug build, and on a release build it pins a > permanent ~500k irqs/s on one CPU. 100us keeps margin above the > debug-config cost. > The 2us interval survived the syzbot test [10]. [10] Subject: Re: [syzbot] [mm?] INFO: rcu detected stall in exit_to_user_mode_loop https://lore.kernel.org/lkml/68885247.a00a0220.b12ec.00c8.GAE@google.com/ > One more thing that came out of testing this: the floor only covers > half of the problem. A valid schedule that falls behind replays its > whole backlog one hrtimer expiry at a time. With a 4x200us schedule > and CLOCK_TAI stepped forward 72h (think ptp4l's first big step, or a > VM pause) I get an RCU stall with the owning CPU stuck in hrtimer > expiry processing, and no admission check can catch that; syzbot's > reports show the same stall with advance_sched() on the stack. A > bounded catch-up in advance_sched() fixes it. Conversely, catch-up > alone doesn't help the storm case: the 700ns schedule is still > admitted and sustains ~1M irqs/s. > > I have both halves ready as a series - a bounded catch-up in > advance_sched() plus this patch with the exemption folded in - tested > by syzbot against both reproducer buckets on net.git dd057113ac7b, > with a tc-testing case. I plan to post it in a day, keeping your > Signed-off-by on this one, unless you'd prefer to respin it yourself. > The guys on the cc list know I hate SOB because cc is enough.