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 X-Spam-Level: X-Spam-Status: No, score=-9.0 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,MAILING_LIST_MULTI,MENTIONS_GIT_HOSTING,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C59E8C4363A for ; Wed, 21 Oct 2020 10:29:22 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 3D40620795 for ; Wed, 21 Oct 2020 10:29:22 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="DlKf5bnw"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="KLQBz9PH" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 3D40620795 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Type: Content-Transfer-Encoding:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:Message-ID:References:In-Reply-To:Subject:To:From: Date:MIME-Version:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=bBHk+3vgO1jH0FDaB495HQiKDZ2FUTBu8j8rUcNjDWI=; b=DlKf5bnwdip+3OrW5sLwQD/DW toAmMa56Ab26vanC2mPQozy0oPK29qn+IuzWHng1XcX7hBlY3rLVs5Msw7u3nKg9RL571r/C7/fiF DP17ZlIdX8S6L1zgApXTfpScjHMmUM+x3+xJtPWV7Ag0CARtqIG/8Gq37uNABz5cdTUnAXGj5tQMu lAlrACmX/OqPqw0tOqmVEuWz625/Oh/Rlq4SzypLF12FCbQjq9KDFwdoy3YnyRLn1i9xV1rJFJEmh sVjtbPooIqzip3cmLLzUakPks79FcEBFpAt1RA1RRquhZXvA6buQDGMBQWr3xr41PJ0ZSyZonpRl6 oMfjYXbpw==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kVBLd-0005Jg-TZ; Wed, 21 Oct 2020 10:28:01 +0000 Received: from mail.kernel.org ([198.145.29.99]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kVBLb-0005IX-G2 for linux-arm-kernel@lists.infradead.org; Wed, 21 Oct 2020 10:28:00 +0000 Received: from disco-boy.misterjones.org (disco-boy.misterjones.org [51.254.78.96]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 53A9720795; Wed, 21 Oct 2020 10:27:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1603276078; bh=bUkGtFLF6jET5lEcrcQKVZVTxu7HB+oWtwgZEXhk4gk=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=KLQBz9PHgGvLwOxBZ+1qjVheotgicuLH1X2/hAEvcswpbIZugQefA2fSIV5fR2oBS pX2fDynzIC6NC2z5Si9WEvXFw7GS2YzhgHq5mqrEJZWNTfz+f8l59CW641sDY8/7dL lpW6iS3LG0cWXDF0Rb042Exlk/lTdJgMOtBqWOpM= Received: from disco-boy.misterjones.org ([51.254.78.96] helo=www.loen.fr) by disco-boy.misterjones.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1kVBLY-0030gT-B3; Wed, 21 Oct 2020 11:27:56 +0100 MIME-Version: 1.0 Date: Wed, 21 Oct 2020 11:27:56 +0100 From: Marc Zyngier To: Sumit Garg Subject: Re: [PATCH v5 1/5] arm64: Add framework to turn IPI as NMI In-Reply-To: References: <1602673931-28782-1-git-send-email-sumit.garg@linaro.org> <1602673931-28782-2-git-send-email-sumit.garg@linaro.org> User-Agent: Roundcube Webmail/1.4.9 Message-ID: <1d41e0e4e6ee6c794b83d2c75c3748da@kernel.org> X-Sender: maz@kernel.org X-SA-Exim-Connect-IP: 51.254.78.96 X-SA-Exim-Rcpt-To: sumit.garg@linaro.org, catalin.marinas@arm.com, will@kernel.org, linux-arm-kernel@lists.infradead.org, tglx@linutronix.de, jason@lakedaemon.net, mark.rutland@arm.com, julien.thierry.kdev@gmail.com, dianders@chromium.org, daniel.thompson@linaro.org, jason.wessel@windriver.com, msys.mizuma@gmail.com, ito-yuichi@fujitsu.com, kgdb-bugreport@lists.sourceforge.net, linux-kernel@vger.kernel.org X-SA-Exim-Mail-From: maz@kernel.org X-SA-Exim-Scanned: No (on disco-boy.misterjones.org); SAEximRunCond expanded to false X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201021_062759_851629_75E32DFC X-CRM114-Status: GOOD ( 21.78 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Mark Rutland , Daniel Thompson , Jason Cooper , Catalin Marinas , ito-yuichi@fujitsu.com, Douglas Anderson , Linux Kernel Mailing List , julien.thierry.kdev@gmail.com, Jason Wessel , kgdb-bugreport@lists.sourceforge.net, Thomas Gleixner , Masayoshi Mizuma , Will Deacon , linux-arm-kernel Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 2020-10-20 12:22, Sumit Garg wrote: > On Tue, 20 Oct 2020 at 15:38, Marc Zyngier wrote: >> >> On 2020-10-20 07:43, Sumit Garg wrote: >> > On Mon, 19 Oct 2020 at 17:07, Marc Zyngier wrote: >> >> [...] >> >> >> > +{ >> >> > + if (!ipi_desc) >> >> > + return; >> >> > + >> >> > + if (is_nmi) { >> >> > + if (!prepare_percpu_nmi(ipi_id)) >> >> > + enable_percpu_nmi(ipi_id, IRQ_TYPE_NONE); >> >> > + } else { >> >> > + enable_percpu_irq(ipi_id, IRQ_TYPE_NONE); >> >> >> >> I'm not keen on this. Normal IRQs can't reliably work, so why do you >> >> even bother with this? >> > >> > Yeah I agree but we need to support existing functionality for kgdb >> > roundup and sysrq backtrace using normal IRQs as well. >> >> When has this become a requirement? I don't really see the point in >> implementing something that is known not to work. >> > > For kgdb: > > Default implementation [1] uses smp_call_function_single_async() which > in turn will invoke IPI as a normal IRQ to roundup CPUs. > > [1] > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/kernel/debug/debug_core.c#n244 > > For sysrq backtrace: > > Default implementation [2] fallbacks to smp_call_function() (IPI as a > normal IRQ) to print backtrace in case architecture doesn't provide > arch_trigger_cpumask_backtrace() hook. > > [2] > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/tty/sysrq.c#n250 > > So in general, IPI as a normal IRQ is still useful for debugging but > it can't debug a core which is stuck in deadlock with interrupts > disabled. And that's not something we implement today for good reasons: it *cannot* work reliably. What changed that we all of a sudden need it? > And since we choose override default implementations for pseudo NMI > support, we need to be backwards compatible for platforms which don't > possess pseudo NMI support. No. There is nothing to be "backward compatible" with, because - this isn't a userspace visible feature - *it doesn't work* So please drop this non-feature from this series. M. -- Jazz is not dead. It just smells funny... _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel