Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751938AbbKBXbN (ORCPT ); Mon, 2 Nov 2015 18:31:13 -0500 Received: from mail-by2on0090.outbound.protection.outlook.com ([207.46.100.90]:49992 "EHLO na01-by2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751478AbbKBXbH (ORCPT ); Mon, 2 Nov 2015 18:31:07 -0500 Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Yuri.Norov@caviumnetworks.com; From: Yury Norov To: , , , CC: , , , , , , , , , , , , Yury Norov Subject: [RFC PATCH v6 00/17] ILP32 for ARM64 Date: Tue, 3 Nov 2015 02:30:29 +0300 Message-ID: <1446507046-24604-1-git-send-email-ynorov@caviumnetworks.com> X-Mailer: git-send-email 2.1.4 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [109.252.143.100] X-ClientProxiedBy: HE1PR03CA0002.eurprd03.prod.outlook.com (25.163.170.140) To CO2PR07MB617.namprd07.prod.outlook.com (10.141.228.143) X-Microsoft-Exchange-Diagnostics: 1;CO2PR07MB617;2:gIrttNMDXHzcnHwfBhmk5lFnrawqHsiTi9xiP/lAisXr8IJFMtC0D3uDyE/SKp5GG4kEFhzd2Ahm9F6Qjk1fM40s9pkVQ7ciwhxEkL3BUBmvDOHqSurhpEfsR84/sCdKJ7dm4qpsge8FTwYpJViqwibEhuInhuAjVAC8nWx6/8M=;3:/fpEppnq/0NShUJgtI21rPpGurckgD18SZ28bwlxlxn9ewJgSsylR/AdH/tTr96cTwl5tEow6w9uWf9zFIfBywO/dqMGZLHF//6WiiR+F4VlWMDc9vKbp3+rx/sDHFLyvVzh/lEBq5IClaNgXP865A==;25:9t330gh2fhcaGYbahF6GhiS7Kk9ynq+dMciGGzvAJvRzHlXhG1D/B0nGXcJBz2C2QGns0UdwofHV44HjQPHRqWRFNIyS3pzL+MJCvNRODHBipG0avNO5P92p1nl6wLPBKxzEIpWIRbWygALOZM+4pbnlMJVSimN+ZDUgQ8qGg8Zj2iDn5h4wPAqnl0nBmUTR5cL7gIBh9k2F24XjUMJnVIAWjvaO7TB0FRmU1jsEB4RyGl/lwv2MhpE00YD753FO/sSwvfI/7Qwp2jhFU0zBGg== X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:CO2PR07MB617; X-Microsoft-Exchange-Diagnostics: 1;CO2PR07MB617;20:UJs/MVnfW0joYLr1vTx7sBVqWmdRIxv9KINweEmLIqCXz4TtbwzYKu67e9rnGxMLJEcyMcN4yfXk5Owyxc9Rka7X5fSiGM6gHKob+SgOP8ESVJnBHrRG7cRIkq4iZ+rVf8tC0eQgkQx7ISaQjNyUweev7CyytmCPznxuhPr0lNjdc+kvst1Dc4QuooUorb5Vc18V8NF9UrxCurgTmNZVNZlZz+CAXdodRojXMxJtSJRQKG3OXG2v2ppM+MQo2+lWH/pL3kQuQ0+hksszPeusErmdxly+am0LG2PfmsPrSXXYIUjViq6qK24jc+1aT8pa7K3rRZ5w6ndPjG6BT3GwPgcIgzi8NTt+iqWXThUtEa89nG8aQNCrSCtL1wzTlmgYcNvPHa4HvOy4zrNw4pZXaTHjy3XtNMAzKC22/MpxPhOeG4e4k3ACrQwXSX0czH4y1/Cg/QiwzqrDGiIj7F/uIYVKF7a8aoWYI55IWawXryqsAEBkR3PiYj3MlOgWD3xl3egTLSKKOfGZJiJeMgNVMhZ2gJVUNQYlMd6rq4plGySC3gag499PZKBUc9d5CalgtJ4hcCLZgkT49QkUaRZyGVR3BrAw8mIp3ldRGFWB3Yg= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(601004)(2401047)(8121501046)(520078)(5005006)(3002001)(10201501046);SRVR:CO2PR07MB617;BCL:0;PCL:0;RULEID:;SRVR:CO2PR07MB617; X-Microsoft-Exchange-Diagnostics: 1;CO2PR07MB617;4:ogKFVj4UJQ7aq/6JvxntgJP7NCxQ9MrlKgwj5kTvjoJbvX+shVGCioNXitULgxJ5KJQXU2/zOrIG8qJuCaOmb50fImoA/p2/NBHYCbOiOUxhQ67dgAr6cBlMSRP6HQg4AS1XEg5Y4yX2zlvQFQLsABt/zjzfGV9e/nTm5KQvMufdbRRr0ZrIgrC2hvtCpZj/dXOpRhbhRU1guC/GRQtAi5tHDIU6BmO/60v2rUi9yzN4BMK4UavmolHjnSN/7myExCNt2rMcWc51aJIlqy4/zg6HhgYRLjUqeUrUF8OWVcHHQkMAYNRwBa67dDIftbCibqUs+7ezG70xZoogiztCDIJbA4Wtz9FaweoaoSyYuoxmlTeBnamqZFmL0Z1l3paB X-Forefront-PRVS: 0748FF9A04 X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10009020)(6069001)(6009001)(199003)(189002)(76506005)(15975445007)(105586002)(5007970100001)(33646002)(87976001)(50466002)(2201001)(5008740100001)(50226001)(48376002)(36756003)(106356001)(229853001)(122386002)(92566002)(5001960100002)(189998001)(40100003)(77096005)(47776003)(97736004)(107886002)(50986999)(5001770100001)(66066001)(42186005)(5003940100001)(5004730100002)(101416001)(4001430100002)(19580395003)(81156007)(217873001)(2101003);DIR:OUT;SFP:1101;SCL:1;SRVR:CO2PR07MB617;H:localhost;FPR:;SPF:None;PTR:InfoNoRecords;A:1;MX:1;LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1;CO2PR07MB617;23:dhHsPCq6WFxgqusEJAbQ7IxIMvd5nN4CAki+MIIPwB?= =?us-ascii?Q?MmuUrhX+nBjohwBODQ3BfyZGJJLcV4LmU2WSkxfxn2jd9sR+fPlGuS7DvxDw?= =?us-ascii?Q?jtTE0432E1JpskZXKU3jLHFk18Q754fs5kSqXtRzQbUZMBtRpucmyChYcmeE?= =?us-ascii?Q?QE6DndopsDaLAXM/naizCwLuK0RDzSQhShfwTCJrKPcS/CA7mNzqqYlQLsb5?= =?us-ascii?Q?eTAO1nwERo0yLzsXT68D0duFUASlXocNN/xr44icOqDdpq/sl603IJ7LTeOX?= =?us-ascii?Q?+dZJyZzq78DeKnNp+opYwbVYqDXuCNspwgkL2RpYF/LEnfUgZor2uaJ1A5XZ?= =?us-ascii?Q?i1JMxty/6H8f4N0+pf/G/mIQBrL3fIXh8eFw7P0IveXIvs8TfnBI8+p32EvO?= =?us-ascii?Q?Fu5gq0yyyIUCw6TATnnbp5CcQn5zQ+tVQrsm1LscdoDTV/9dHGCdDpII/uj/?= =?us-ascii?Q?3wAZ1P/oJbGt72sxLCU7y7OrqQnLsqevnkqtxpaG/tP0WyJD7/zIDnDFvIna?= =?us-ascii?Q?z3BgNV3epiVIWpv9HX8KgcSf+pW0VSHOdxOYYyL6xZRpmtjU/lSzrUSUvAnl?= =?us-ascii?Q?t4+0TuOCD43npzGe3V7CloyXRx22A0l6S7AEBQnSCd88ntautGtcV0Kr7S/D?= =?us-ascii?Q?c/XtbBDcooUpjg06AhAyQBZ5A+HDBFn2XNgivMDSy1Ej+ChPWGILCm0a7Sue?= =?us-ascii?Q?QasM33eGYwTH11OTDPlf16SuzRFYfL3IR+WremSGvpQq3gpNilP7bvtdaRnN?= =?us-ascii?Q?ow406Dlg6G4GHh5YJgZfXYmEXzTiLdxYqjlL4reNjJCPHHZlcErTo3lLPAqQ?= =?us-ascii?Q?g01vDS6TxzC2HI8w1BMlWygm91RgUNhvr6tncKusDva3Hpu6L4Rvki6dq8qM?= =?us-ascii?Q?61KNOOGwK0IzuHH8PId7Oec3kLsyLtcExqjTRNZPSlXJh35cXFZEXkFzCt+m?= =?us-ascii?Q?w3UOvFAdLdYZipCYbHRDwSEUwZkS+IaSVlNDvwrhcc3b6dql6ewehWwS8Ba5?= =?us-ascii?Q?lHSZmYG/UEk4VBhnAqPFX3meu+2qmf6w7tVZCFsVNey7a4HhNuWJSxzH44jb?= =?us-ascii?Q?ZqD2R3jbTquKeILIqI4JRVgPnF?= X-Microsoft-Exchange-Diagnostics: 1;CO2PR07MB617;5:jIq+grIuvSQUDTVZEcUTQ8LuDnBWq/fTXjoxVypI4ZDYNR9iu0cdRRfZEYCRse6k1WmKrnBLuotVWb5RxJu816Kl4eYWW4yoap3hKOq2LNezmVskIsiSkJ5c+BA5y0HRl/Eu9iqfZp8FyT7lTeOAUw==;24:yFzAiRvHr/3chVt9afBxvD7og6iukRxY2QiZV/BCOSvA32w7TRon9f1Ivw50hyxkOm2sIC7Ee4Yow3B/FAUSSLUeCTmNr9oHs+WZNlFj038=;20:m34+HwW43JvL0VVBONCUdGiYJ2+p4AoekluPefzMCvTTID2fFzn/nS85J3+HaP+INZdRtpIcvzBpg+7O3AxK0Q== SpamDiagnosticOutput: 1:23 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Nov 2015 23:31:04.7290 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: CO2PR07MB617 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 4310 Lines: 101 V6 addresses comments collected for v5 series. This is RFC because LTP tests fail (63 of 779). But I don't expect that major changes are required to fix regressions. v3: https://lkml.org/lkml/2014/9/3/704 v4: https://lkml.org/lkml/2015/4/13/691 v5: https://lkml.org/lkml/2015/9/29/911 v6: - time_t, __kenel_off_t and other types turned to be 32-bit for compatibility reasons (after v5 discussion); - related changes applied to ILP32 syscall table and handlers; - ILP32 VDSO code excluded. It's not mandatory, and caused questions during review process. We definitely make sure we will follow up with a VDSO later on because it is needed for performance reasons; - fixed build issues with different combinations of AARCH32 / ILP32 enabling in config; - ILP32 TLS bug fixed; - entry32-common.S introduced to hold wrappers needed for both ILP32 and AARCH32_EL0; - documentation updated according to latest changes; - rebased to the current head; - coding style re-checked. Andrew Pinski (13): arm64: ensure the kernel is compiled for LP64 arm64: rename COMPAT to AARCH32_EL0 in Kconfig arm64: change some CONFIG_COMPAT over to use CONFIG_AARCH32_EL0 instead arm64:ilp32: share signal structures between ILP32 and LP64 ABIs arm64: introduce is_a32_task and is_a32_thread (for AArch32 compat) arm64:ilp32: add is_ilp32_compat_{task,thread} and TIF_32BIT_AARCH64 arm64:ilp32: share HWCAP between LP64 and ILP32 arm64:ilp32 use the native LP64 'start_thread' for ILP32 threads arm64:ilp32: support core dump generation for ILP32 ptrace: Allow compat to use the native siginfo arm64:ilp32: add sys_ilp32.c and a separate table (in entry.S) to use it arm64:ilp32: use the native siginfo instead of the compat siginfo arm64:ilp32: add ARM64_ILP32 to Kconfig Jan Dakinevich (1): ilp32: common 32-bit wrappers Philipp Tomsich (2): arm64:ilp32: add documentation on the ILP32 ABI for ARM64 arm64:ilp32: change COMPAT_ELF_PLATFORM to report a a subplatform for ILP32 Yury Norov (1): aarch64: ilp32: use generic stat64 structure Documentation/arm64/ilp32.txt | 55 +++++++ arch/arm64/Kconfig | 14 +- arch/arm64/Makefile | 5 + arch/arm64/include/asm/compat.h | 70 ++++++++- arch/arm64/include/asm/elf.h | 105 +++++++++++-- arch/arm64/include/asm/fpsimd.h | 2 +- arch/arm64/include/asm/hwcap.h | 12 +- arch/arm64/include/asm/memory.h | 2 +- arch/arm64/include/asm/processor.h | 18 ++- arch/arm64/include/asm/ptrace.h | 2 +- arch/arm64/include/asm/signal32.h | 19 +++ arch/arm64/include/asm/stat.h | 2 + arch/arm64/include/asm/thread_info.h | 3 +- arch/arm64/include/asm/unistd.h | 11 +- arch/arm64/include/uapi/asm/siginfo.h | 21 +++ arch/arm64/include/uapi/asm/signal.h | 31 ++++ arch/arm64/kernel/Makefile | 4 +- arch/arm64/kernel/asm-offsets.c | 2 +- arch/arm64/kernel/entry.S | 18 ++- arch/arm64/kernel/entry32-common.S | 37 +++++ arch/arm64/kernel/entry32.S | 29 ---- arch/arm64/kernel/head.S | 2 +- arch/arm64/kernel/hw_breakpoint.c | 7 +- arch/arm64/kernel/perf_regs.c | 2 +- arch/arm64/kernel/process.c | 4 +- arch/arm64/kernel/ptrace.c | 47 +++--- arch/arm64/kernel/signal.c | 21 ++- arch/arm64/kernel/sys_ilp32.c | 278 ++++++++++++++++++++++++++++++++++ arch/arm64/kernel/traps.c | 4 +- arch/arm64/kernel/vdso.c | 12 +- include/linux/compat.h | 4 + include/uapi/asm-generic/siginfo.h | 17 ++- include/uapi/asm-generic/signal.h | 27 +++- include/uapi/asm-generic/stat.h | 8 +- kernel/ptrace.c | 24 ++- 35 files changed, 806 insertions(+), 113 deletions(-) create mode 100644 Documentation/arm64/ilp32.txt create mode 100644 arch/arm64/kernel/entry32-common.S create mode 100644 arch/arm64/kernel/sys_ilp32.c -- 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/