From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 1A126CCF9F8 for ; Wed, 12 Nov 2025 14:21:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: Content-Type:MIME-Version:References:In-Reply-To:Subject:Cc:To:From: Message-ID:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=sdW3OlTExVNBHFnWUo8/ACBmb4Vov6jHiAMtYyCLPPY=; b=aEhivqZjdtzNZbwTZCcCz6KDWZ VAjIJ/86GFIYU/qYLEJy2VURnyNF+UQ0/9EeHylyi0YZOm/1uuSSHccKpsasLdsLQe4UCEe0F+Vg5 KVkqJuAEJ1Scsz4jpJ0b4Q8yb2NydUhjcBRSvMoMXX4gk8lJ6FqQAN9H0/wnTPPC0RJS3XHJ2tgif ne7R449VsFtDyf8FWFu2cuC5jVRKu0T/QyXW8GSERacW8HcREJdzV6VAQlZ+pK4MBozcSoy6Ze664 qboKn2gUct0oVqNaJ0eYfMb5UZ9LS/svKtZhV4lVqngWr2o85YC9PbsnfuKcKM8xvk4pHR9a3n3sA 9POZb37Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98.2 #2 (Red Hat Linux)) id 1vJBiy-00000008v81-14Bk; Wed, 12 Nov 2025 14:21:28 +0000 Received: from tor.source.kernel.org ([2600:3c04:e001:324:0:1991:8:25]) by bombadil.infradead.org with esmtps (Exim 4.98.2 #2 (Red Hat Linux)) id 1vJBiw-00000008v7n-0q4R for linux-arm-kernel@lists.infradead.org; Wed, 12 Nov 2025 14:21:26 +0000 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by tor.source.kernel.org (Postfix) with ESMTP id 3D96B6021C; Wed, 12 Nov 2025 14:21:25 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id DC674C4CEF1; Wed, 12 Nov 2025 14:21:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1762957284; bh=/hOxQ9C2lk+N1NIFVh7E5xgqEFJaMmpx3AHeuX5+Zpg=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=S9WMmZ/QWOtdikDnydmU61FjwbB33dU661tQCn0LGXCwTDjFjNyMN4nAabSqTbQQX zMofYdpo2BcBxGlJnV5HMtLCFuXnDYQNDvTu+q3mpqyZAvbo+Sa9LV87XW1KeufzDi WwEA2yI09w1qqI0sjrv3ScXYLoi3mo3DpmHIgUyAZaDc1bQUTeDMYjOvsm+QV582zX 9ZzC1xGvrofsGKVNhyKWh0TKCfnARAMQfOOjSTtQcx68Gb7/Y0Edk7Funj/6mhQmCo 1BzEGBIcLqj6xDaoz8Jjj4bQrLf4sIX8SvgxygQ5cNrDZFl4MMH1XVGaY84pKOr6tF 6dYb9u2R7cGrQ== Received: from sofa.misterjones.org ([185.219.108.64] helo=goblin-girl.misterjones.org) by disco-boy.misterjones.org with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.2) (envelope-from ) id 1vJBis-00000004Z5y-2Y9g; Wed, 12 Nov 2025 14:21:22 +0000 Date: Wed, 12 Nov 2025 14:21:22 +0000 Message-ID: <86v7jftjq5.wl-maz@kernel.org> From: Marc Zyngier To: Breno Leitao Cc: catalin.marinas@arm.com, will@kernel.org, mark.rutland@arm.com, paulmck@kernel.org, mhiramat@kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, kernel-team@meta.com Subject: Re: arm64: pseudo NMI bootconfig question In-Reply-To: References: User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM-LB/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL-LB/10.8 EasyPG/1.0.0 Emacs/30.1 (aarch64-unknown-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-SA-Exim-Connect-IP: 185.219.108.64 X-SA-Exim-Rcpt-To: leitao@debian.org, catalin.marinas@arm.com, will@kernel.org, mark.rutland@arm.com, paulmck@kernel.org, mhiramat@kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, kernel-team@meta.com X-SA-Exim-Mail-From: maz@kernel.org X-SA-Exim-Scanned: No (on disco-boy.misterjones.org); SAEximRunCond expanded to false X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Wed, 12 Nov 2025 14:05:43 +0000, Breno Leitao wrote: >=20 > Hello, >=20 > In most major Linux distributions, it=E2=80=99s common to have a separate= debug kernel > build. This variant is compiled with additional debug configuration optio= ns to > provide deeper observability and easier debugging, typically at the expen= se of > some performance. >=20 > This approach is also used in several companies, including mine. The debug > flavor is usually a drop-in replacement deployed when investigating > issues, allowing quicker identification before more detailed manual > debugging. >=20 > I=E2=80=99m currently debugging some hung tasks using the debug kernel fl= avor and > noticed that backtraces weren=E2=80=99t printed correctly because PSEUDO = NMI isn=E2=80=99t > enabled. >=20 > AFAIK, to enable PSEUDO NMI on ARM, the following are required: >=20 > cmdline: irqchip.gicv3_pseudo_nmi=3D1 > config: CONFIG_ARM64_PSEUDO_NMI=3Dy >=20 > I wanted to have pseudo NMI enabled by default in the debug kernel > (without relying on kernel command-line parameters), but this isn=E2=80= =99t > possible today. The reason is that `irqchip.gicv3_pseudo_nmi` is an early > parameter, which can=E2=80=99t be set through bootconfig, so, independent= of my > .config, I need to hack cmdline arguments to have the debuggability > I need. >=20 > Question: >=20 > Would it make sense to provide an option to enable pseudo NMI in certain > kernel configuration without requiring an extra command-line parameter? [I wasn't asked, but I'll give my answer anyway] The short answer is no. The long answer is that there is so much broken HW out there that dies a painful death when enabling pseudo-NMI that is isn't practical to do so. It also brings a measurable overhead to some of the most frequent operations (interrupt masking). Until someone weeds out the broken machines (in some cases, by prying them from my cold dead hands), the requirement for the option is likely to stick. Thanks, M. --=20 Without deviation from the norm, progress is not possible.