From patchwork Fri Jun 17 23:54:13 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yury Norov X-Patchwork-Id: 9185197 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 4449A601C0 for ; Fri, 17 Jun 2016 23:57:06 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2DA8C208C2 for ; Fri, 17 Jun 2016 23:57:06 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 09F23280B0; Fri, 17 Jun 2016 23:57:06 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.1 required=2.0 tests=BAD_ENC_HEADER,BAYES_00, DKIM_SIGNED, RCVD_IN_DNSWL_MED, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 803A8208C2 for ; Fri, 17 Jun 2016 23:57:05 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1bE3c5-0001ss-F1; Fri, 17 Jun 2016 23:55:49 +0000 Received: from mail-by2on0054.outbound.protection.outlook.com ([207.46.100.54] helo=na01-by2-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1bE3bY-0000Hv-30 for linux-arm-kernel@lists.infradead.org; Fri, 17 Jun 2016 23:55:17 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-caviumnetworks-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=DkGwTzpzFgzdDpa8bLXuohhsgByiDDoDMgxHKTG5GRc=; b=wGH/Lt/kpxxIpk/kQSON8E28LcFSBBrY8gQM0y/KwTtIAjzQxwd1d0OcF6xZeDdr7UI7rFLcqwGYNEbGPg5A5od75jg1xPERX0WtWGA/a/fdtO6WC+JmSj7KjgF/9i718Qxk+zmvOPs6xrLuPF8RpY1YocWVGhyiDLFUK5I8H7E= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Yuri.Norov@caviumnetworks.com; Received: from localhost (50.233.148.158) by BN4PR07MB2242.namprd07.prod.outlook.com (10.164.63.148) with Microsoft SMTP Server (TLS) id 15.1.523.12; Fri, 17 Jun 2016 23:54:53 +0000 From: Yury Norov To: , , , , , , Subject: [PATCH 04/19] arm64: ensure the kernel is compiled for LP64 Date: Sat, 18 Jun 2016 02:54:13 +0300 Message-ID: <1466207668-10549-5-git-send-email-ynorov@caviumnetworks.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1466207668-10549-1-git-send-email-ynorov@caviumnetworks.com> References: <1466207668-10549-1-git-send-email-ynorov@caviumnetworks.com> MIME-Version: 1.0 X-Originating-IP: [50.233.148.158] X-ClientProxiedBy: BLUPR18CA0036.namprd18.prod.outlook.com (10.162.230.46) To BN4PR07MB2242.namprd07.prod.outlook.com (10.164.63.148) X-MS-Office365-Filtering-Correlation-Id: d384d343-0c98-47e4-24a0-08d3970ac732 X-Microsoft-Exchange-Diagnostics: 1; BN4PR07MB2242; 2:AJCI8l/gm7FMCP8eTN8cbu1vfH0tRkKdPDsCeaaBcdjWUwXQr5Ym2j6sORfsYyS70WP8woBytMrIFNmC6B2OwfvBFtz6SeKE0tz1hxxx0GIRAfiTcEi/082lxgQaCOhJINCagkKfZcW0hBNwxX0XxIr9aYtb8IQrnhD4Lg3kwopBLlMu/J7P4eHD20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+92Pvtx1XlepiZDHQBUR4N2FQtVQcVx/ppPG5+Td9veVT/ZZo4i52SKheb3aI+K0+OSDu6Gpdd1VMy26WGLYVGfj/xwV64csukHT9n1MFJ28fTne80a0usoXDx7fmzDibzZhhEAZ3NTGCprF3DKimMZvfVqqg90iAhi90DkFntP9basddBTKqRvFMtrxHDAc8K9lve74= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(601004)(2401047)(5005006)(8121501046)(10201501046)(3002001); SRVR:BN4PR07MB2242; BCL:0; PCL:0; RULEID:; SRVR:BN4PR07MB2242; X-Microsoft-Exchange-Diagnostics: 1; BN4PR07MB2242; 4:PNw5UKqNms7e1Wh2AFTHi1056sfPZKcCbC00Swx5JSA322z7ZsKZkv+g8cjlpRvPBT3+l1op2RDMEpwRMaBIRmSqTY7O2qPGp3DXtZk2Fro8hAA3/0Uir4iASoijGgLd4i6BD/oYVWa3ozjGSgyiRUlVDXc8FbpmQeO5rrhg+mP+2Jquc7ZWzcJ0feXPm5I8oxBXBRf8DYh7II8CPUwzdcdRfTEVmVarE1c5OjFj51GZP9Tv8g6faA0uFFMPZOSLRvqQGLUE5pLKZI8DlsLwSIbwXYkJkUQIqHG+9gI/mkv+EVeeXPocn0T4qBKE9rfoIcuJ0x3r5IxTe5RC8jIxzHh+P3Hmt3n55nIiqzeN4KjlnQotENsUQq+n3+qM2pO3 X-Forefront-PRVS: 09760A0505 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(6009001)(6069001)(7916002)(199003)(189002)(50466002)(105586002)(76176999)(50986999)(92566002)(8676002)(2950100001)(2906002)(36756003)(97736004)(5001770100001)(189998001)(68736007)(7846002)(81166006)(101416001)(81156014)(106356001)(66066001)(48376002)(4326007)(107886002)(33646002)(50226002)(47776003)(76506005)(229853001)(19580395003)(42186005)(19580405001)(6116002)(3846002)(586003)(4001430100002)(5004730100002)(5003940100001)(77096005)(2201001)(2101003); DIR:OUT; SFP:1101; SCL:1; SRVR:BN4PR07MB2242; H:localhost; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en; Received-SPF: None (protection.outlook.com: caviumnetworks.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; BN4PR07MB2242; 23:nyMFZm4ioy9nnZ5fU79voMDazX1owAX7Wwdp0gZJy?= =?us-ascii?Q?8acnWwfRON8cFDvsV/QS71xtE6L/SMLiKd8YwdcNEh5JNSWci5Z7lGnD+DY/?= =?us-ascii?Q?XNfGOG+rrz28CjPYEpKWg4QjEwzShegRiVVLDgaP8DS3ntPQ1qEODSyybg4f?= =?us-ascii?Q?CONJiCBTPI7Vn0TorvbOxUHjufJfB0LrBwJ4suEFisgE3QXsGq+0YH3JbaQr?= =?us-ascii?Q?/hz2WnnXUW9oPCAStlYV3DP/pMkSjRD/kDEClpNgjsmAXBCeWd1PAIkd89YQ?= =?us-ascii?Q?4FunqEZ85Jplv+IR0ljEou+Sk4E9pZL7pCIAwYx6DSWXfmLh1MVLdMtuGtPa?= =?us-ascii?Q?k3pZtdLidvQQhlMtDznYbIz5O85JYy7jQfB45HPkBb3JEeMfCc2FBM/r1Yjo?= =?us-ascii?Q?D2ffWaG9+/35lzdVlQ/3yCzxDzdc5RdIi9OTo+Fl0FabUCSqCXJy4UA4V0ts?= =?us-ascii?Q?3Y8AxLgaK8An72sXdgtrNsY343bUIs5b+WXy3+pTlBRO9Gk+ol+9od96DNhV?= =?us-ascii?Q?wa0EnfAtip3grSw0sdYeV9+zikH39qKIvjquNsFO6knaKi/DpXF7UQZ0FMtk?= =?us-ascii?Q?v0Px7+66CeYxDEZKSSeMbEQb1AqoogfrRsufqcHnCFRZEbXFUUUJzysc/0Az?= =?us-ascii?Q?HNfdgEpb4rN/wAi33Xd++ED1trw1ieIWfyaHqmzbdoKVuZ8ALWdfCkF3tzhb?= =?us-ascii?Q?glRvxHVDDLd+Jm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pyiQ7fmpSVYKjt4Hjhcniq2m1ZdedoZKsYm4WC/YEyzdSPGoMYRCBKX4CMzjYtje/MLzh02MbCsl5N6o349dP9FsrrfXHEWGiR4=; 7:/5QSGQvpVRd/+BuW8AhAsKVzLFMeUsc3FBW8PL2CVb+OKYvcwAqsA0vrhcyDEqjAYSVrQtlHavuzAvIm24AOZsAadxxHNNI61Dkx640qGhxqdOHEFFVcdSwLqdMSUKGIDUH2mb/tUd1UDTcsiOVqtn4Q8ygYimcUvdKOfRctPzOrch5o+GJIJbo7DCrnj/JHMx0BxT/0wgEbjc0+vmHldrnj9jfWENiw4T1LhGz/MLy99EcY4LQYY1EcvNAspFwj SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 17 Jun 2016 23:54:53.3368 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN4PR07MB2242 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20160617_165516_290911_A3C7BB74 X-CRM114-Status: UNSURE ( 5.66 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: szabolcs.nagy@arm.com, heiko.carstens@de.ibm.com, ynorov@caviumnetworks.com, philipp.tomsich@theobroma-systems.com, joseph@codesourcery.com, Prasun.Kapoor@caviumnetworks.com, agraf@suse.de, Andrew Pinski , geert@linux-m68k.org, kilobyte@angband.pl, manuel.montezelo@gmail.com, pinskia@gmail.com, linyongting@huawei.com, klimov.linux@gmail.com, broonie@kernel.org, bamvor.zhangjian@huawei.com, maxim.kuvyrkov@linaro.org, Nathan_Lynch@mentor.com, Andrew Pinski , schwidefsky@de.ibm.com, davem@davemloft.net, christoph.muellner@theobroma-systems.com Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP From: Andrew Pinski The kernel needs to be compiled as a LP64 binary for ARM64, even when using a compiler that defaults to code-generation for the ILP32 ABI. Consequently, we need to explicitly pass '-mabi=lp64' (supported on gcc-4.9 and newer). Signed-off-by: Andrew Pinski Signed-off-by: Philipp Tomsich Signed-off-by: Christoph Muellner Signed-off-by: Yury Norov Reviewed-by: David Daney --- arch/arm64/Makefile | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/arch/arm64/Makefile b/arch/arm64/Makefile index 7085e32..51c5293 100644 --- a/arch/arm64/Makefile +++ b/arch/arm64/Makefile @@ -35,14 +35,19 @@ KBUILD_CFLAGS += -fno-asynchronous-unwind-tables KBUILD_CFLAGS += $(call cc-option, -mpc-relative-literal-loads) KBUILD_AFLAGS += $(lseinstr) +KBUILD_CFLAGS += $(call cc-option,-mabi=lp64) +KBUILD_AFLAGS += $(call cc-option,-mabi=lp64) + ifeq ($(CONFIG_CPU_BIG_ENDIAN), y) KBUILD_CPPFLAGS += -mbig-endian AS += -EB LD += -EB +LDFLAGS += -maarch64linuxb else KBUILD_CPPFLAGS += -mlittle-endian AS += -EL LD += -EL +LDFLAGS += -maarch64linux endif CHECKFLAGS += -D__aarch64__