From patchwork Mon Sep 30 09:49:37 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= X-Patchwork-Id: 278999 Return-Path: X-Original-To: incoming-imx@patchwork.ozlabs.org Delivered-To: patchwork-incoming-imx@bilbo.ozlabs.org Received: from casper.infradead.org (unknown [IPv6:2001:770:15f::2]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 261922C007C for ; Mon, 30 Sep 2013 19:52:12 +1000 (EST) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1VQa85-0005xB-E0; Mon, 30 Sep 2013 09:51:01 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1VQa7k-0006Nq-Ni; Mon, 30 Sep 2013 09:50:40 +0000 Received: from metis.ext.pengutronix.de ([2001:6f8:1178:4:290:27ff:fe1d:cc33]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1VQa7E-0006J8-Vy for linux-arm-kernel@lists.infradead.org; Mon, 30 Sep 2013 09:50:10 +0000 Received: from ukl by metis.ext.pengutronix.de with local (Exim 4.72) (envelope-from ) id 1VQa6s-0000qw-FA; Mon, 30 Sep 2013 11:49:47 +0200 From: =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= To: linux-arm-kernel@lists.infradead.org Date: Mon, 30 Sep 2013 11:49:37 +0200 Message-Id: <1380534577-15076-4-git-send-email-u.kleine-koenig@pengutronix.de> X-Mailer: git-send-email 1.8.4.rc3 In-Reply-To: <1380534577-15076-1-git-send-email-u.kleine-koenig@pengutronix.de> References: <1380534577-15076-1-git-send-email-u.kleine-koenig@pengutronix.de> MIME-Version: 1.0 X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: ukl@pengutronix.de X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on metis.extern.pengutronix.de X-Spam-Level: X-Spam-Status: No, score=-1.9 required=4.0 tests=BAYES_00,NO_RELAYS shortcircuit=no autolearn=ham version=3.3.2 Subject: [PATCH 3/3] [RFC] ARM: prepare ARMv7-M for MULTIPLATFORM use X-SA-Exim-Version: 4.2.1 (built Mon, 22 Mar 2010 06:51:10 +0000) X-SA-Exim-Scanned: Yes (on metis.ext.pengutronix.de) X-PTX-Original-Recipient: linux-arm-kernel@lists.infradead.org X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130930_055009_406008_D5A41460 X-CRM114-Status: GOOD ( 14.27 ) X-Spam-Score: -2.6 (--) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-2.6 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RP_MATCHES_RCVD Envelope sender domain matches handover relay domain -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: Olof Johansson , kernel@pengutronix.de, Arnd Bergmann X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+incoming-imx=patchwork.ozlabs.org@lists.infradead.org List-Id: linux-imx-kernel.lists.patchwork.ozlabs.org v7-M is a third group that is incompatible with both v4/v5 and v6/v7. Signed-off-by: Uwe Kleine-König Acked-by: Arnd Bergmann --- This behaves strange but I think is robust not to allow broken configs: When v4/v5 is selected, v6/v7 and v7m are available for enabling, too. When v6/v7 is selected the other choices are disabled When v7m is selected only v6/v7 are available for enabling. --- arch/arm/Kconfig | 11 ++++++++--- arch/arm/kernel/entry-v7m.S | 6 ++++-- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index d873a34..4d749fa 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -881,7 +881,7 @@ comment "CPU Core family selection" config ARCH_MULTI_V4T bool "ARMv4T based platforms (ARM720T, ARM920T, ...)" - depends on !ARCH_MULTI_V6_V7 + depends on !ARCH_MULTI_V6_V7 && !ARCH_MULTI_V7M select ARCH_MULTI_V4_V5 select CPU_ARM920T if !(CPU_ARM7TDMI || CPU_ARM720T || \ CPU_ARM740T || CPU_ARM9TDMI || CPU_ARM922T || \ @@ -889,7 +889,7 @@ config ARCH_MULTI_V4T config ARCH_MULTI_V5 bool "ARMv5 based platforms (ARM926T, XSCALE, PJ1, ...)" - depends on !ARCH_MULTI_V6_V7 + depends on !ARCH_MULTI_V6_V7 && !ARCH_MULTI_V7M select ARCH_MULTI_V4_V5 select CPU_ARM926T if (!CPU_ARM946E || CPU_ARM1020 || \ CPU_ARM1020E || CPU_ARM1022 || CPU_ARM1026 || \ @@ -912,8 +912,13 @@ config ARCH_MULTI_V7 config ARCH_MULTI_V6_V7 bool +config ARCH_MULTI_V7M + bool "ARMv7-M based platforms (Cortex-M)" + depends on !ARCH_MULTI_V6_V7 && !MMU + select CPU_V7M + config ARCH_MULTI_CPU_AUTO - def_bool !(ARCH_MULTI_V4 || ARCH_MULTI_V4T || ARCH_MULTI_V6_V7) + def_bool !(ARCH_MULTI_V4 || ARCH_MULTI_V4T || ARCH_MULTI_V6_V7 || ARCH_MULTI_V7M) select ARCH_MULTI_V5 endmenu diff --git a/arch/arm/kernel/entry-v7m.S b/arch/arm/kernel/entry-v7m.S index 52b2643..f72ced6 100644 --- a/arch/arm/kernel/entry-v7m.S +++ b/arch/arm/kernel/entry-v7m.S @@ -14,8 +14,6 @@ #include #include -#include - #include "entry-header.S" #ifdef CONFIG_TRACE_IRQFLAGS @@ -141,3 +139,7 @@ ENTRY(vector_table) .rept 64 - 16 .long __irq_entry @ 16..64 - External Interrupts .endr + + .globl handle_arch_irq +handle_arch_irq: + .long 0