Received: by 2002:a05:7412:31a9:b0:e2:908c:2ebd with SMTP id et41csp4634757rdb; Fri, 15 Sep 2023 08:01:36 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEA488CIh2Nib+6VwosvZeZsUpYNoTcNoq4eCN7I3uBvo9aJmbUmXj5MU59DdxjolupPGVw X-Received: by 2002:a17:90a:4dc7:b0:274:6440:ad9a with SMTP id r7-20020a17090a4dc700b002746440ad9amr1770977pjl.31.1694790096229; Fri, 15 Sep 2023 08:01:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1694790096; cv=none; d=google.com; s=arc-20160816; b=Vm+sCcbK+sjACPb7HcoFgi/bpAHulyLYF2w/ML4U6ItHatm0y3MABRdTh37TtWzFcB 8cpqCZRxKPR46appWbJO5tit34p+b+mkHATNuaaDBTXIdTWxSkfLNxge457PQ+Z+clSr x6p+8Kf9utJH2uO2lHBfHQArJA0B7X0Co+9dfbN3TLmL+Bn0NZ7vye3cVJL6ouRdkkLZ 0dMc7j4IDi6vGyKx9OioFbC9w85tkfdlAKmPIho+U7UPNn35QyGeU/9draWwKoENJiK+ 4ogMZYtbx44VXzg4fr4w48H5G09JPCtwb8vXjmLCkxVz00zdDjxxebjUFg+Mx4wTZzW3 OzDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:robot-unsubscribe :robot-id:message-id:mime-version:references:in-reply-to:cc:subject :to:reply-to:sender:from:dkim-signature:dkim-signature:date; bh=UFxc2R4QX3SL6qKcyTQop/43MwcshPy66p2kRtRIxKc=; fh=4vfBNVFiAwP0DemeTjMQt5Mu5RUi1hzhGD2L0jN8ZMk=; b=xJEU3Wy9AqANhMXCL6vgbGZNOLyArGqXudMJvi0cSM0s18NgAAiLqRCNVQX/EbNhVk yNm6lVVW6zuvruF+Cn+6yw2VWiXJmIY+jWTu32HkLLYOMEaCoodHyViBHSLP5hl657b3 ewfVDzG/ZqzL50UHuVVqJgIBNy8kLscHGcgEygubDphKYWo1pJjnsDJAltQTb6ENS+dm L4w1x07FliT8fmAWc2U1Gwi/4C6n47f+IXy9WdK8URgZimilTvTsjuHM0rKY2WKvipxC I51youEgV0CedbgyWwum2HLfVH3j8rIzGQ6meqzK0aPrFdAzqVBKBk8Na6reGIs21+jX TjJg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=p0EiLuh6; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 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 lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id p1-20020a17090a868100b0026b54eb88d4si5700003pjn.126.2023.09.15.08.01.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Sep 2023 08:01:36 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=p0EiLuh6; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 0FB4C806E3E2; Fri, 15 Sep 2023 02:36:40 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233675AbjIOJge (ORCPT + 99 others); Fri, 15 Sep 2023 05:36:34 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35558 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233117AbjIOJgd (ORCPT ); Fri, 15 Sep 2023 05:36:33 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [IPv6:2a0a:51c0:0:12e:550::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D4744171C; Fri, 15 Sep 2023 02:36:26 -0700 (PDT) Date: Fri, 15 Sep 2023 09:36:23 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1694770584; h=from:from:sender:sender:reply-to: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: in-reply-to:in-reply-to:references:references; bh=UFxc2R4QX3SL6qKcyTQop/43MwcshPy66p2kRtRIxKc=; b=p0EiLuh6t09J8EmNaD7SQJRVmcG+YZ6GUWswNIUMiipyySKFp1AoW1BfnDWUfIiltKeZBd d6n4JNYVZN2CcozrXuLA0NW5qS85ctrVU51NBdeacmBrB6XkBa6DbuTuN6ccXaIEJ6Vr3i HICxcO5hujpPwzgl1S4ni6YbGVvWUrQY5lH21ZslTcoai9Piyd0ktaNl509MCCi22Iz91v US1df2IVcec9CSRX3Jl8Hk/XW9DLdXHn8JbHb09KY+ytjC6+N/knHctk4ud9UK32ZLq8DF p6TMHmK/Fy8Geq7SSuULIsaHhnMY9ba4h/K5WslkxfJC5aXL+uGNrZh0kd3x1Q== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1694770584; h=from:from:sender:sender:reply-to: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: in-reply-to:in-reply-to:references:references; bh=UFxc2R4QX3SL6qKcyTQop/43MwcshPy66p2kRtRIxKc=; b=iOyHCMeM7XpKke5X81o3PnfrvhS+RPJmhECKpWGDY2PDvCI1RSM3grSFtiliiNp36AoSFz 6N2y7wWt1uhjaaBw== From: "tip-bot2 for Lukas Wunner" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: core/urgent] panic: Reenable preemption in WARN slowpath Cc: Lukas Wunner , Ingo Molnar , Linus Torvalds , Thomas Gleixner , "Paul E. McKenney" , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <3ec48fde01e4ee6505f77908ba351bad200ae3d1.1694763684.git.lukas@wunner.de> References: <3ec48fde01e4ee6505f77908ba351bad200ae3d1.1694763684.git.lukas@wunner.de> MIME-Version: 1.0 Message-ID: <169477058360.27769.17772363826818333894.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Fri, 15 Sep 2023 02:36:40 -0700 (PDT) The following commit has been merged into the core/urgent branch of tip: Commit-ID: cccd32816506cbac3a4c65d9dff51b3125ef1a03 Gitweb: https://git.kernel.org/tip/cccd32816506cbac3a4c65d9dff51b3125ef1a03 Author: Lukas Wunner AuthorDate: Fri, 15 Sep 2023 09:55:39 +02:00 Committer: Ingo Molnar CommitterDate: Fri, 15 Sep 2023 11:28:08 +02:00 panic: Reenable preemption in WARN slowpath Commit: 5a5d7e9badd2 ("cpuidle: lib/bug: Disable rcu_is_watching() during WARN/BUG") amended warn_slowpath_fmt() to disable preemption until the WARN splat has been emitted. However the commit neglected to reenable preemption in the !fmt codepath, i.e. when a WARN splat is emitted without additional format string. One consequence is that users may see more splats than intended. E.g. a WARN splat emitted in a work item results in at least two extra splats: BUG: workqueue leaked lock or atomic (emitted by process_one_work()) BUG: scheduling while atomic (emitted by worker_thread() -> schedule()) Ironically the point of the commit was to *avoid* extra splats. ;) Fix it. Fixes: 5a5d7e9badd2 ("cpuidle: lib/bug: Disable rcu_is_watching() during WARN/BUG") Signed-off-by: Lukas Wunner Signed-off-by: Ingo Molnar Cc: Linus Torvalds Cc: Thomas Gleixner Cc: Paul E. McKenney Link: https://lore.kernel.org/r/3ec48fde01e4ee6505f77908ba351bad200ae3d1.1694763684.git.lukas@wunner.de --- kernel/panic.c | 1 + 1 file changed, 1 insertion(+) diff --git a/kernel/panic.c b/kernel/panic.c index 07239d4..ffa037f 100644 --- a/kernel/panic.c +++ b/kernel/panic.c @@ -697,6 +697,7 @@ void warn_slowpath_fmt(const char *file, int line, unsigned taint, if (!fmt) { __warn(file, line, __builtin_return_address(0), taint, NULL, NULL); + warn_rcu_exit(rcu); return; }