From patchwork Wed Aug 17 11:46:28 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yury Norov X-Patchwork-Id: 9285677 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 3611F60459 for ; Wed, 17 Aug 2016 11:50:56 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2B21827FB7 for ; Wed, 17 Aug 2016 11:50:56 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1F36F29072; Wed, 17 Aug 2016 11:50:56 +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 88A3427FB7 for ; Wed, 17 Aug 2016 11:50:55 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.85_2 #1 (Red Hat Linux)) id 1bZzKY-0000ap-SF; Wed, 17 Aug 2016 11:48:22 +0000 Received: from mail-dm3nam03on0071.outbound.protection.outlook.com ([104.47.41.71] helo=NAM03-DM3-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.85_2 #1 (Red Hat Linux)) id 1bZzJy-0000Jm-Vy for linux-arm-kernel@lists.infradead.org; Wed, 17 Aug 2016 11:47:48 +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=/7LnIOMenk96fyJo1w0nJQI5pRx5YMAdiAXj3Qm1VxQ=; b=xgXXIalegmo0D0tsyYm/I2574dGeJJ0a16XJN4OAecdpjTjjkkPBiz06wlyThnSz9DUnHoVyUuyWl0iGa4clZ/UC9c4h+29vwhLrEQvPcD6QX8wj9G8iK/NuaLWPF9AZy46i0Uxko72Uf3wlIiydRzc1/jGAManI3BDHclinagw= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Yuri.Norov@caviumnetworks.com; Received: from localhost (95.143.213.121) by DM3PR07MB2249.namprd07.prod.outlook.com (10.164.33.147) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA_P384) id 15.1.557.21; Wed, 17 Aug 2016 11:47:23 +0000 From: Yury Norov To: , , , , , , Subject: [PATCH 03/18] arm64: ensure the kernel is compiled for LP64 Date: Wed, 17 Aug 2016 14:46:28 +0300 Message-ID: <1471434403-25291-4-git-send-email-ynorov@caviumnetworks.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1471434403-25291-1-git-send-email-ynorov@caviumnetworks.com> References: <1471434403-25291-1-git-send-email-ynorov@caviumnetworks.com> MIME-Version: 1.0 X-Originating-IP: [95.143.213.121] X-ClientProxiedBy: AM4PR02CA0041.eurprd02.prod.outlook.com (10.165.239.179) To DM3PR07MB2249.namprd07.prod.outlook.com (10.164.33.147) X-MS-Office365-Filtering-Correlation-Id: 1a885cf9-56dc-402b-7194-08d3c694412c X-Microsoft-Exchange-Diagnostics: 1; DM3PR07MB2249; 2:0TOlJBQOpbE7TIGaVo4WGiSb/MkGHnO0bMKmNsEVc4nQJ8I8PHUhfFJWqPhXHFxmWL7QRboOlWwaMUTNw8kHKze7DIr3vHdqkuEUjJF2q9+4wiyYPFJE2Bn4QEeWDW5vNUhCxh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s2uFI2kNBqigBRPCk9mpL2hoC80IQgDWX3pXMzmco4L6dJ75J9/sQvt9vxDTni32WtRYu+peYPqBxgFm0CRcSMirsZ2rTLh+llteAte2NyLjKcynMYfbHLlP84sHJPYgnRlyTwQL+nAT9uPY9dpfLzW/I+qUCh2KoclJ++DV2b7ZufaWmmAiC/6Kr1NsSfYXmuqo8dZW16i6TiCpMkxESXzjYURX0RDGpw1xrMMB8qaVnSdMPl3sNnxnkreFakfGPcY4VuQPE6TOGCY5+DDsmHIkVCHnnM0MIpA+NoV7cAFGvQJjFSk8wm6zP1BlfN73czQMKB6Lt5ti9GEqdCIbjyFHmj/t96frYCDEKCsuSaGTOXSv26P1osRS8a7npNrONa8GU0feMuhKiDSC7gsenrRZ5Dot5lHqkPheMmAGKAUD9GsVfrnA+5PbTQToAdgAvuzyawGrg4i+L8FrnkO1QxYzKlsGA7PRGC/0iMDm+uxrdwt/iBMQi0EkWs= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040176)(601004)(2401047)(8121501046)(5005006)(3002001)(10201501046); SRVR:DM3PR07MB2249; BCL:0; PCL:0; RULEID:; SRVR:DM3PR07MB2249; X-Microsoft-Exchange-Diagnostics: 1; DM3PR07MB2249; 4:Pm/3owzafl7nV5zoo/bWyS7cJ2LCCRME7gBFrmfW+Hjm0nDhpXCvdSJNHqQkXOiGbwcWFP0+gz6oXbp0pOn+BlnxPkhAczEAmE5UcGsL0gUJQ5tNbQ7LEk1y72znCGZumyVcWcaQ5ZzaeVK6kBQy+L7XRVbm9WeJydihtT4YES/5XtvGf9CEW0fAGCMZJGlhclzatV8Q/g3RiOYctYRwhoi2Iq11F+c5/w0qEfSJGuNOMR6EVEsaPDxSln0GL0gGXSbae3Npuh+ZlHUdRYag/s7ctagGT6MrDejfG2ABEfiYCqt/3E4SYwNFdtQbUKBSbbicF6/bVRaKpMYv8iXJA6kNbIEXWyH/G6mVtwEE6/gYjedKAHrdjsJJWD3iduVSxvl8QTJ+oPRxASJ1nj6MAg== X-Forefront-PRVS: 0037FD6480 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(6069001)(6009001)(7916002)(199003)(189002)(77096005)(50986999)(36756003)(105586002)(19580405001)(19580395003)(7846002)(7736002)(5003940100001)(4001430100002)(586003)(229853001)(2201001)(106356001)(97736004)(76176999)(3846002)(6116002)(101416001)(42186005)(33646002)(76506005)(5001770100001)(2950100001)(48376002)(189998001)(107886002)(50226002)(66066001)(81166006)(47776003)(8676002)(4326007)(2906002)(81156014)(7416002)(92566002)(305945005)(50466002)(68736007)(2101003); DIR:OUT; SFP:1101; SCL:1; SRVR:DM3PR07MB2249; 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; DM3PR07MB2249; 23:avpqbl5iRC//aFJJraxggqUMKyCs2AB319CPjrAeZ?= =?us-ascii?Q?Y0akEvSkWqQ8dFesjKoK9wHgCuCtDr004S2SPGmEL8qN2gkfFSlRb4R087sp?= =?us-ascii?Q?XAflbp/iqAUlp6B23zu5ItmIPLHydQo93ixH3kq4DCujgJARpDy6x2C4Jopl?= =?us-ascii?Q?B/waThUSj0tD0uRZHTLcNZqZgUldp8OcvfbBwSyWT3t+J1OMoMYCsG/moU2O?= =?us-ascii?Q?LHRGp/zgDSz9KoG7gVHxaCLqqGdS3EiT2EGIOgB8R5un+hnaZLW/D1+Q39E9?= =?us-ascii?Q?wG8yz02ta15++7nU8bWp7hE80i5VbXw0gGc9z8qhlGWoge7icOF0O1FJ0I07?= =?us-ascii?Q?8KgSBJBr1HPkOi4IEFXocIRqBswaM6K2bgK+QHxe5g2kV1kq7HnkKHKZaNlS?= =?us-ascii?Q?D7BTjTSuvpoZJorMq2N6qbUix0MBzRy8Tp/EVXJWZ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263dLxy48wdEIWOlqIB5AhScMqgE6zKgcL8GQYZMZfele15qiWOpk3aTUcnJodFW907t2N5xOC+uFogXA+jrRXKgUGeRQ6kmdeOYYRLSlbxRR7JVrFLvxxmcpb1/ffpA3SwjCG0IwHXLRjKZpsxqL2MbkTfPUvGa5BAPeFA5YU5h73dN0fqdfVrRfAnVKlrUKWh0DhHrRsOiDZvDZAhiIphE=; 5:l9lDPBZpMSMD3/+5dNDl3KW8C9CDPRUfW2Vn6DWQuM6zeUjTzvZqaLBYn5tonhX2evsL5Ewj6NYiSZ4Or/qeBgE7SfNGaiDepnhcW5Mf+1hLNw5U+zantDa6xMlRi/hR1QVcZ2WfCflKLoXkpA7Z7Q==; 24:OKsRj408QxCxA1vzrfO5sAbAy8WmEujEvvqKfgg73XjIzyleHRcNd7kb47Of8x8Bc7IF5KWV2lncSnnlMrzjGFPx5BmBD4QyBHgvHlzaF0M=; 7:qcJ+TDez3keipOEo+JnxwLd9GBFaYeZXSuPpYy4NyFG0kuTX1TRDbspYxs5q9U6PWBg64hqz5LhfEksidPEbcZU3zzY69+gE8qy6Jhzo930XjpaBg1bo4RqDlWd1uRhf4J1UiX3efBeXIgYiirsypBajGIBMXLCJPyJUfUiMt/afC6J5HGGejnZjbLnrFCAHrLJIWFpIKy4xgvduYa2MydX1nZ9K1Bwv5RIjCz94VgJG7hJiC3l8yxloZ/t23XFG SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 17 Aug 2016 11:47:23.6620 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM3PR07MB2249 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20160817_044747_250275_4BA6C880 X-CRM114-Status: UNSURE ( 5.59 ) 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, cmetcalf@ezchip.com, ynorov@caviumnetworks.com, philipp.tomsich@theobroma-systems.com, joseph@codesourcery.com, zhouchengming1@huawei.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 5b54f8c..4800227 100644 --- a/arch/arm64/Makefile +++ b/arch/arm64/Makefile @@ -34,14 +34,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__