Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp2246728pxb; Sun, 17 Apr 2022 15:45:00 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwWDFlQ52K0BDYJPl+1Ay3cms01tHrj8zfJcxurNxgciqc8Pmq/i3fRMSUQ2B07xJ4h0tLF X-Received: by 2002:a05:6402:1941:b0:413:2b5f:9074 with SMTP id f1-20020a056402194100b004132b5f9074mr9391531edz.414.1650235500083; Sun, 17 Apr 2022 15:45:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650235500; cv=none; d=google.com; s=arc-20160816; b=SssxLSiJOOPWnMqYFPpjPQHY8DpW4rfGYHzPC2+hDifHviiav9GAUAtwL7qO/gzO4i 0NYMdYsjnRUG5Rw7IYVFSgPVoG72FawqLlt1W0ZpajQQk5iLDA3BdBgcck8nK3vCCH0L m4KQ/HkO0YvhwuEhPK03lYMBSoMto+FtWmIA6t9NcepVDvIwhQMgrMrdunbFwzFOikE9 GyLgJXoNeZRUT8Hw1PpIRXop0kzvpvtr7Y8J8jrvb7yik2UXi4GzxUvUjKJfJmvHCclH vRq+96qsfnESWecs227Av+zNIJsvDUdPhHt5Z8u/ZiZIU41lo2hARRtnssmjTmUdwx43 3AoQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:date:mime-version:content-transfer-encoding :message-id:references:subject:cc:to:dkim-signature:dkim-signature :from; bh=W1m8VLfjzQK90MyhsuL33nF8VtSdralMAdK05ScJcC0=; b=MPOLDUhsnHAqxb/X78g5LyaJO2G4sHC+46V4ghr8Ut31w86oPvzxZ0zOG+0IyFEzSY WHOkC/Jb7AeHD+M8j8AlurVoN6yCZu7E3Vc2g3nffpJuta9fq2l8dTWTJMYMWMfBKnx3 4fVCGXXJNldgbeUt1siP5kGfSi6Z20X4YI8Ig3vCelQmfj6iE08+NsK5pAE8r+7MDEdg 3fshnRFKpioSG0yD8aMWQ6y+O6sh2CUicCKg+pGi+T8CkqDPZndf8XHivc5EMZM0ELz/ OZ9IiXb9ChytBrA6aQCVVpHJxcTUsepu0XLpPwxUxZbBbv+bkSgmxp6I7kembGdruRxb hlcQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=PDFlTQfM; dkim=neutral (no key) header.i=@linutronix.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id m8-20020a17090679c800b006df76385eeesi5076284ejo.910.2022.04.17.15.44.35; Sun, 17 Apr 2022 15:45:00 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=PDFlTQfM; dkim=neutral (no key) header.i=@linutronix.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233862AbiDQKB4 (ORCPT + 99 others); Sun, 17 Apr 2022 06:01:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35014 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233854AbiDQKBv (ORCPT ); Sun, 17 Apr 2022 06:01:51 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [IPv6:2a0a:51c0:0:12e:550::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 28F35C03 for ; Sun, 17 Apr 2022 02:59:17 -0700 (PDT) From: Thomas Gleixner DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1650189555; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: references:references; bh=W1m8VLfjzQK90MyhsuL33nF8VtSdralMAdK05ScJcC0=; b=PDFlTQfM2fsq9CVTz11u7J9taJm3QKMeEc3VchYJ9gfJ/iRpQ3OpDgqZNqoCby7BCW1gp4 oUDqpBqN3S9/52Fmanx2doouaS6I/Mkgjowy/xEYCMuBl6fXZkA5zlZryp196J+a7L1SDH yPBnVNvPGcvTHI37tpUrlsZpIUw+FAp9VnbXAOwb/9D300n2taIPVy0qMLOAyrBXFxrPit YWzyv3rxdh9NBpAjMgLpTMpdOf8H0g34eW+vz7xFWoGNun3H04gJ+fXyzYrR+hHnuzIyf4 EiP0CiydqhQAYflccl6glsl3OVc63Ay7IJpKNKTIllgyMcZ3JGKM9fxMthpNWw== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1650189555; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: references:references; bh=W1m8VLfjzQK90MyhsuL33nF8VtSdralMAdK05ScJcC0=; b=aYJwx9qgEpYZMR3OI0VJMjkuqpbgaddmMc0Wf43yxfT7ktqke4EF8pXHuL6Is0yu9nrx35 Ca28yBkg0xuJ/SCA== To: Linus Torvalds Cc: linux-kernel@vger.kernel.org, x86@kernel.org Subject: [GIT pull] timers/urgent for v5.18-rc3 References: <165018953450.44773.6382828227632028472.tglx@xen13> Message-ID: <165018953738.44773.8160831624072143061.tglx@xen13> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Date: Sun, 17 Apr 2022 11:59:14 +0200 (CEST) X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Linus, please pull the latest timers/urgent branch from: git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git timers-urgent-20= 22-04-17 up to: 9c95bc25ad3b: tick/sched: Fix non-kernel-doc comment A small set of fixes for the timers core: - Fix the warning condition in __run_timers() which does not take into account, that a CPU base (especially the deferrable base) has never a timer armed on it and therefore the next_expiry value can become stale. - Replace a WARN_ON() in the NOHZ code with a WARN_ON_ONCE() to prevent endless spam in dmesg. - Remove the double star from a comment which is not meant to be in kernel-doc format. Thanks, tglx ------------------> Anna-Maria Behnsen (1): timers: Fix warning condition in __run_timers() Jiapeng Chong (1): tick/sched: Fix non-kernel-doc comment Paul Gortmaker (1): tick/nohz: Use WARN_ON_ONCE() to prevent console saturation kernel/time/tick-sched.c | 6 +++--- kernel/time/timer.c | 11 +++++++---- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/kernel/time/tick-sched.c b/kernel/time/tick-sched.c index 2d76c91b85de..d257721c68b8 100644 --- a/kernel/time/tick-sched.c +++ b/kernel/time/tick-sched.c @@ -188,7 +188,7 @@ static void tick_sched_do_timer(struct tick_sched *ts, kt= ime_t now) */ if (unlikely(tick_do_timer_cpu =3D=3D TICK_DO_TIMER_NONE)) { #ifdef CONFIG_NO_HZ_FULL - WARN_ON(tick_nohz_full_running); + WARN_ON_ONCE(tick_nohz_full_running); #endif tick_do_timer_cpu =3D cpu; } @@ -1538,7 +1538,7 @@ void tick_cancel_sched_timer(int cpu) } #endif =20 -/** +/* * Async notification about clocksource changes */ void tick_clock_notify(void) @@ -1559,7 +1559,7 @@ void tick_oneshot_notify(void) set_bit(0, &ts->check_clocks); } =20 -/** +/* * Check, if a change happened, which makes oneshot possible. * * Called cyclic from the hrtimer softirq (driven by the timer diff --git a/kernel/time/timer.c b/kernel/time/timer.c index 85f1021ad459..9dd2a39cb3b0 100644 --- a/kernel/time/timer.c +++ b/kernel/time/timer.c @@ -1722,11 +1722,14 @@ static inline void __run_timers(struct timer_base *ba= se) time_after_eq(jiffies, base->next_expiry)) { levels =3D collect_expired_timers(base, heads); /* - * The only possible reason for not finding any expired - * timer at this clk is that all matching timers have been - * dequeued. + * The two possible reasons for not finding any expired + * timer at this clk are that all matching timers have been + * dequeued or no timer has been queued since + * base::next_expiry was set to base::clk + + * NEXT_TIMER_MAX_DELTA. */ - WARN_ON_ONCE(!levels && !base->next_expiry_recalc); + WARN_ON_ONCE(!levels && !base->next_expiry_recalc + && base->timers_pending); base->clk++; base->next_expiry =3D __next_timer_interrupt(base); =20