From patchwork Wed Aug 8 21:27:52 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 10606 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id C18DA23E57 for ; Wed, 8 Aug 2012 21:28:22 +0000 (UTC) Received: from mail-yx0-f180.google.com (mail-yx0-f180.google.com [209.85.213.180]) by fiordland.canonical.com (Postfix) with ESMTP id 8E486A184CA for ; Wed, 8 Aug 2012 21:28:22 +0000 (UTC) Received: by mail-yx0-f180.google.com with SMTP id q6so1333068yen.11 for ; Wed, 08 Aug 2012 14:28:22 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf:from:to:cc :subject:date:message-id:x-mailer:in-reply-to:references :x-provags-id:x-gm-message-state; bh=rPOLME16lTvqBHhSr5kqnJSPG0SgEgurdvrD9Mcz4TM=; b=DWsTN/SINJtcCQVZyiZhIsHQgc/aGLvcA8Nj7NhPtOnGAaYw601IS3GUkORNtiL54A eup+Dj5HeXTgVOPl4Yn71PSHAiJxe2fkrXGHROBF7VT2KeWUzhd0Aagd/baM2L0mIVdo IK9RPHASvMtTJ2dfg9YFlq5jFO4e2TC4eoMmMMPxfJZHNrKaVo2tS1TuYAuPptbiM/d3 t8d6Up2r1HxsldCpVX0miEh5pAVTFuojJFhonbhsUjayvOcUsKLFx7Xu4tMWnrVzK3ne TroZMKE0TyXi8W+ZSbH8g23Rqgb3klPYVFEnEop5WdmPw/R1gbItJ+OsbgXsYqds0YqU k1qA== Received: by 10.50.94.133 with SMTP id dc5mr350687igb.16.1344461302035; Wed, 08 Aug 2012 14:28:22 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.50.184.200 with SMTP id ew8csp628851igc; Wed, 8 Aug 2012 14:28:21 -0700 (PDT) Received: by 10.216.101.68 with SMTP id a46mr9577334weg.120.1344461300883; Wed, 08 Aug 2012 14:28:20 -0700 (PDT) Received: from moutng.kundenserver.de (moutng.kundenserver.de. [212.227.126.187]) by mx.google.com with ESMTP id x58si31467154wes.113.2012.08.08.14.28.20; Wed, 08 Aug 2012 14:28:20 -0700 (PDT) Received-SPF: neutral (google.com: 212.227.126.187 is neither permitted nor denied by best guess record for domain of arnd@arndb.de) client-ip=212.227.126.187; Authentication-Results: mx.google.com; spf=neutral (google.com: 212.227.126.187 is neither permitted nor denied by best guess record for domain of arnd@arndb.de) smtp.mail=arnd@arndb.de Received: from localhost.localdomain (HSI-KBW-149-172-5-253.hsi13.kabel-badenwuerttemberg.de [149.172.5.253]) by mrelayeu.kundenserver.de (node=mreu2) with ESMTP (Nemesis) id 0Mh8wH-1TLPLv0WJt-00M5GO; Wed, 08 Aug 2012 23:28:10 +0200 From: Arnd Bergmann To: linux-arm-kernel@lists.infradead.org Cc: arm@kernel.org, linux-kernel@vger.kernel.org, Arnd Bergmann , Russell King , Dave Martin Subject: [PATCH 04/10] ARM: pass -marm to gcc by default Date: Wed, 8 Aug 2012 23:27:52 +0200 Message-Id: <1344461278-28245-5-git-send-email-arnd@arndb.de> X-Mailer: git-send-email 1.7.10 In-Reply-To: <1344461278-28245-1-git-send-email-arnd@arndb.de> References: <1344461278-28245-1-git-send-email-arnd@arndb.de> X-Provags-ID: V02:K0:nd8XuSNg3c4SZ09Jhb7+/zeFJBVPUv9+oP3u/DhLaAF u3bRnZAri28uO5kLBSI3z37nC81oIiGUaedz1bpZjJdEHF2Y8A l3yljfBSO31hI2xPRN/QjsDOE9UiJM2xwiFcYqUAwnL9qQY/XY CWAhrv81bM7+xm854i2gHSI+kZOfKpheDaY14OrBDTYDRMJ6MV 7GKIB/9ZS/KP0wh92SHE0sfsQlI/TKNYmUP92WwG/yjyI5VDKA Vltji8f/AB/lO39ZFzv5xNc07EjmfdBLtrDW4QDA9X7DUCbYk0 ezsuVRK2qyxvBah1TVYXLx20l5PFfXrhsJuLo2ohXDmTfduYlH vC+9Sb1Q/CvHhj68I0VhbJNua9B3CahDFugDOrQL6MdLGRH0em 59wqKKGItwWLA== X-Gm-Message-State: ALoCoQnye4lpc/JLEHJCGHbsmx/X5PAVFRu/mAF116ffBt0t/KJc/T3YVz34/rqGqVScCoPiAbIt The Linaro cross toolchain and probably others nowadays default to building in THUMB2 mode. When building a kernel for a CPU that does not support THUMB2, the compiler complains about incorrect flags. We can work around this by setting -marm for all non-T2 builds. Without this patch, building assabet_defconfig results in: usr/initramfs_data.S:1:0: warning: target CPU does not support THUMB instructions [enabled by default] arch/arm/nwfpe/entry.S:1:0: warning: target CPU does not support THUMB instructions [enabled by default] firmware/cis/PCMLM28.cis.gen.S:1:0: warning: target CPU does not support THUMB instructions [enabled by default] (and many more) Signed-off-by: Arnd Bergmann Cc: Russell King Cc: Dave Martin --- arch/arm/Makefile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm/Makefile b/arch/arm/Makefile index 30eae87..b4c2296 100644 --- a/arch/arm/Makefile +++ b/arch/arm/Makefile @@ -111,6 +111,9 @@ AFLAGS_THUMB2 :=$(CFLAGS_THUMB2) -Wa$(comma)-mthumb ifeq ($(CONFIG_THUMB2_AVOID_R_ARM_THM_JUMP11),y) CFLAGS_MODULE +=-fno-optimize-sibling-calls endif +else +CFLAGS_THUMB2 :=-marm +AFLAGS_THUMB2 :=-marm endif # Need -Uarm for gcc < 3.x