Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754601Ab3IYQSf (ORCPT ); Wed, 25 Sep 2013 12:18:35 -0400 Received: from mail-wg0-f51.google.com ([74.125.82.51]:50165 "EHLO mail-wg0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754431Ab3IYQSc (ORCPT ); Wed, 25 Sep 2013 12:18:32 -0400 From: Frederic Weisbecker To: LKML Cc: Frederic Weisbecker , Benjamin Herrenschmidt , Paul Mackerras , Ingo Molnar , Thomas Gleixner , Peter Zijlstra , "H. Peter Anvin" , Linus Torvalds , James Hogan , "James E.J. Bottomley" , Helge Deller , Martin Schwidefsky , Heiko Carstens , "David S. Miller" , Andrew Morton Subject: [PATCH 7/7] x86: Tell about irq stack coverage Date: Wed, 25 Sep 2013 18:18:06 +0200 Message-Id: <1380125886-10341-8-git-send-email-fweisbec@gmail.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1380125886-10341-1-git-send-email-fweisbec@gmail.com> References: <1380125886-10341-1-git-send-email-fweisbec@gmail.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1831 Lines: 53 x86-64 runs irq_exit() under the irq stack. So it can afford to run softirqs in hardirq exit without the need to switch the stacks. The hardirq stack is good enough for that. Now x86-64 runs softirqs in the hardirq stack anyway, so what we mostly skip is some needless per cpu refcounting updates there. x86-32 is not concerned because it only runs the irq handler on the irq stack. Signed-off-by: Frederic Weisbecker Cc: Benjamin Herrenschmidt Cc: Paul Mackerras Cc: Ingo Molnar Cc: Thomas Gleixner Cc: Peter Zijlstra Cc: H. Peter Anvin Cc: Linus Torvalds Cc: Paul Mackerras Cc: James Hogan Cc: James E.J. Bottomley Cc: Helge Deller Cc: Martin Schwidefsky Cc: Heiko Carstens Cc: David S. Miller Cc: Andrew Morton --- arch/x86/include/asm/irq.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/arch/x86/include/asm/irq.h b/arch/x86/include/asm/irq.h index 0ea10f27..879bece 100644 --- a/arch/x86/include/asm/irq.h +++ b/arch/x86/include/asm/irq.h @@ -23,6 +23,10 @@ extern void irq_ctx_init(int cpu); #define __ARCH_HAS_DO_SOFTIRQ +#ifdef CONFIG_X86_64 +# define __ARCH_IRQ_EXIT_ON_IRQ_STACK +#endif + #ifdef CONFIG_HOTPLUG_CPU #include extern void fixup_irqs(void); -- 1.8.3.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/