Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752997AbbKBXbo (ORCPT ); Mon, 2 Nov 2015 18:31:44 -0500 Received: from mail-by2on0093.outbound.protection.outlook.com ([207.46.100.93]:14144 "EHLO na01-by2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752216AbbKBXbh (ORCPT ); Mon, 2 Nov 2015 18:31:37 -0500 Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Yuri.Norov@caviumnetworks.com; From: Yury Norov To: , , , CC: , , , , , , , , , , , , Andrew Pinski , Yury Norov , Andrew Pinski Subject: [PATCH v6 02/17] arm64: ensure the kernel is compiled for LP64 Date: Tue, 3 Nov 2015 02:30:31 +0300 Message-ID: <1446507046-24604-3-git-send-email-ynorov@caviumnetworks.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1446507046-24604-1-git-send-email-ynorov@caviumnetworks.com> References: <1446507046-24604-1-git-send-email-ynorov@caviumnetworks.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [109.252.143.100] X-ClientProxiedBy: VI1PR06CA0004.eurprd06.prod.outlook.com (25.162.116.142) To DM2PR07MB621.namprd07.prod.outlook.com (10.141.177.140) X-Microsoft-Exchange-Diagnostics: 1;DM2PR07MB621;2:JDkm7QEtI2znoVLpQS50o0shrAeK4VHHCYE32FAjGrp2O2hq15wILayhMJwT4Mz+oyThB+YukCoh9fPkF/Mx3u9L6fS2VHmUqaFeisF3mgTkiug0i4oY1wutWwOczlq/XEKDR2LC2WWsfv9kuEADC2CsYk7tASiL74y+BANt49Q=;3:jNEKNJlAc8vnyx/hpKIB44TMuJDFjNh68juDNehaeA6hM0v83QgZ+pBw4iBBPSd2nNrT6oStTG9MqN2v8vZ7/vgxomZA0m7IuCYJEAECETk0r0N+zZ9OhySLcRMRAgCVgSxmZVVjXI/IQfygcHvHbw==;25:wKEvWVq2JBJTLwZcJAyg+Im6yDmsr99LtEzKk3rtSRxLJVHeIbSS/32tNfLat8UuTd+GaB9Hq7+eClPalhEfTZVXXIzkQD+UqKzjHzYLl6D0wUK3KPHaM2j9YjCrgWVOvPbkvTG4Rpu1ZudDbZEsgMvK4KsOe1jFT9CX6Sl+v644L5tjbqZGSqGloGFneMVxttp+OhyNMYF8+T7zaY8V1crUkAEskVTQ01s4cKPzazBP2vdp0sUuSlvoVT03y/7gZ4raqpbOxPXBfiNgt0NZjQ== X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:DM2PR07MB621; X-Microsoft-Exchange-Diagnostics: 1;DM2PR07MB621;20:d7KbbXe6ZXcoDqrv5Fbem4SbAU4NMJ3qjHkJmkPD5hB/0xghe+LJoLsYf/e8JxR27+gVAIohDNDPvmdxEeOo1sQyFatFacpgdoA7Pa1S79bkw+srtAGsBSUiZWLNXSDQQ9Jbfk/J8+gWPaVbS8uiwuIHtrIg9fWxRruRvdWK6eY5cd52Ov1KX9j/lKL+GXWL2fHYW9+YD3xOyAJPoFT6PasGrld04NevjZUYN7EK9Jy3tKcPJg7ZKsQvoFx5yjE5cMvtbAuKDrb3OtktC1kmdlZ3Iuzgph304+icOMRyk2dNlEsR/FE1OCKUWG8j7yng80h+wEyPZUBeJYKQ+KsRdIgGdYCdz5f92daJeqpvczMGfBu9kMi4yXy69MPTbKChx7z0qFFKl5lGgAh18+dKecHs2wE34vfLauut4K6Zenk02N1ESDcUOLJHAMMJfxVl9gtOwWAdQneL+gOvks+nqDPUerT+bfWjMyZKpFPA99OzhNSCh/1oQeQhN/Oqu7u/5q04FRbW5tSAjLLgr+TEK4g/LDFyIYyby+7+IgeQBj7O1D83MjGe3Y3XyRQUZza5ONY5jjZNalFP1J2nJGBaVtCdXSSNe131S0T3AX4tqoA= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(236414709691187); X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(601004)(2401047)(8121501046)(520078)(5005006)(3002001)(10201501046);SRVR:DM2PR07MB621;BCL:0;PCL:0;RULEID:;SRVR:DM2PR07MB621; X-Microsoft-Exchange-Diagnostics: 1;DM2PR07MB621;4:Db3aDAfsdCfbvnZNIJMEw/a+B0b/uo7nH0tsnv9CQoHoQTtH5MK5qnJz5qHHOtJdosP2S0sN59EexzWCmika8xoUozacip4laHbaQ8yH8Z9AgeMjZiEK0jIQzMHDq8SNwtzsKtShP4BtDEUDpUoQqXa68cAw2u/dU5pw3a5hRR+lhHjtNnd01IkuOrnVIPJKSjv/ULFKngSG2n7ohF4f5lbnVxHlxG6ASE1WNT8tyHUCsd5zXa2tmZwclciw6eGRNI/ykSWKPCQtC5J59i9e6qlXMPMKuO24uYRMNPmCxCLDcBDESvpP2AWfuvVdF/SMoOYQ/OeT3fx41jtoWqQNn06z2AnuEdhCGYTDrZ8wU1dFOZMgwXUTpoN5l09z8MhL X-Forefront-PRVS: 0748FF9A04 X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10009020)(979002)(6009001)(6069001)(189002)(199003)(50986999)(97736004)(5004730100002)(33646002)(19580395003)(81156007)(5007970100001)(2201001)(5001770100001)(19580405001)(47776003)(229853001)(40100003)(105586002)(106356001)(122386002)(66066001)(50226001)(87976001)(5003940100001)(2950100001)(36756003)(77096005)(50466002)(4001430100002)(5001960100002)(189998001)(48376002)(101416001)(76176999)(42186005)(107886002)(5008740100001)(76506005)(92566002)(2101003)(969003)(989001)(999001)(1009001)(1019001);DIR:OUT;SFP:1101;SCL:1;SRVR:DM2PR07MB621;H:localhost;FPR:;SPF:None;PTR:InfoNoRecords;MX:1;A:1;LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1;DM2PR07MB621;23:d51OA/cAwfhZiLs4CrbQjxCD4yRByJbntARiRmlnem?= =?us-ascii?Q?xH2WGQCmFhy/oK5ZRoK+LL2gaUy+ImBI9N62RpVI802KO81fx91RHl0OcOu1?= =?us-ascii?Q?TYCELcLUpyG+lXYzGmEjYpdO3dRLB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?Q?meXXZOW402n/apBDBZvSnkhRhV3CYH0E6mAUsfmG/ZQd4U2yVjSJUptjGo/q?= =?us-ascii?Q?wtMFfY9HbdHra7s1OHUGw7eTQwS1qSl3MiIJW4HBRRbveWJ5BIgZ+CKCiwsp?= =?us-ascii?Q?DDzWpobnKiiBcAznZtRmEwiRE9EvndiS0YZHsCrMxWVFKoiE7OUJwOoIiisv?= =?us-ascii?Q?lK0RlnYawiyxx7ziMAzMu4JPzeMIUaNhDj?= X-Microsoft-Exchange-Diagnostics: 1;DM2PR07MB621;5:/TqOQAyULPIfkMP3+M2XX1C5lj8a0myTp3fm4Xa+wkr8uOO0VpRTTwO7AvYzkvZAmMHTIPX4oJCR6q9KLPtNAhL/WLa7ptGtoeb+g5JoYRsUTbBu7B3efIgLjsfN+x6UmtlnS39jVzm7CZ9K/I72Pw==;24:9hKAR7LU76ZzpYhSdPsnXSk7EfFuNz8b7lmQHYqWhHycvcL4ROJE34ICiopSfXV/KUuYV2jvzPsMyhj/oQ950MVHoBxQLiHsRjTMGnBAh5I=;20:/Tu6tgPDs2yZSf4h8+U603W89cwbYaw8/OvsYR5HmSZB2NMJEqUTjpo8i4eTDjH3KeXtu6gC0FhxEVD3+HhkeA== SpamDiagnosticOutput: 1:23 SpamDiagnosticMetadata: NSPM X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Nov 2015 23:31:34.1391 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM2PR07MB621 X-Microsoft-Exchange-Diagnostics: 1;DM2PR07MB447;2:jxU2hCtt687OZc9MeVZeGTAPnqAbmHSHZ4et/EZ0Zf73JhDgzs0qz32xXxnpCmHPHaQvnN/qW+fe1+TuAPHaAGlIveC39eSSSGcEiYURv7MzqE2oysI1LTAIxosBx5r8W3bFhvD4yu7MBsXE3vhjtpj4XmCZfqmKHBillcQ7ZDw=;23:2xqYMKQvU7Zl0qs99rfrgL76xlHzLmgFiLfDN+z56VvpR1yUosOGAwvcPLshJdxQiYC+bNRApbI6zTU/6zYrXcXMkZeVFWRWZ2xUR3Wuu9ayhwTTGd6LJrCdQEBk2xGoRSNSeVWYKNVeDmOF74cZ4URjEljTgJvnFjuUm69etcWdyXhWHtTeuYlKRQ0KFr0V X-OriginatorOrg: caviumnetworks.com Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1506 Lines: 48 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: Philipp Tomsich Signed-off-by: Christoph Muellner Signed-off-by: Yury Norov Signed-off-by: Andrew Pinski Reviewed-by: David Daney --- arch/arm64/Makefile | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/arch/arm64/Makefile b/arch/arm64/Makefile index d10b5d4..432b69a 100644 --- a/arch/arm64/Makefile +++ b/arch/arm64/Makefile @@ -29,14 +29,19 @@ endif KBUILD_CFLAGS += -mgeneral-regs-only $(lseinstr) 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__ -- 2.1.4 -- 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/