Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752884AbbEDKar (ORCPT ); Mon, 4 May 2015 06:30:47 -0400 Received: from mout.kundenserver.de ([212.227.17.24]:65106 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752080AbbEDKaI (ORCPT ); Mon, 4 May 2015 06:30:08 -0400 From: Arnd Bergmann To: linux-arm-kernel@lists.infradead.org Cc: "Dr. Philipp Tomsich" , Andreas Kraschitzer , "Pinski, Andrew" , Catalin Marinas , "linux-kernel@vger.kernel.org" , "agraf@suse.de" , Andrew Pinski , Andreas Schwab , Kumar Sankaran , Benedikt Huber , Christoph Muellner Subject: Re: [PATCH v4 00/24] ILP32 for ARM64 Date: Mon, 04 May 2015 12:29:52 +0200 Message-ID: <3908616.DHRS6D2Ytk@wuerfel> User-Agent: KMail/4.11.5 (Linux/3.16.0-10-generic; KDE/4.11.5; x86_64; ; ) In-Reply-To: <6299275.Ntfb3Dzi12@wuerfel> References: <025BB233-8D14-457A-B3B2-C6BD6C3B32EF@theobroma-systems.com> <0394DFCE-2D52-4028-A9F5-BE4285AFC5D9@theobroma-systems.com> <6299275.Ntfb3Dzi12@wuerfel> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Provags-ID: V03:K0:MmUc+ImJEAkVlTcVSuFHstOZezeDz87GIzIQvOk6RCEzYrMHdsE v2FpX9L1fc9bZLo1epytCMETnoNC0DegiqbahlZ1esGT73irWf8SqU/MM4zPRxCWxK7aIpj luyl1Bw8iczP5QOHNvEWnhFQVvB5I864kXUuyLJAuqBB2ECI2vmB+zGY5p0UmNkuWFM6GGP FRQtxYyDqEeXRlwp+Ld+w== X-UI-Out-Filterresults: notjunk:1; Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1709 Lines: 33 On Saturday 18 April 2015 21:24:19 Arnd Bergmann wrote: > Given Catalin's comments from yesterday, I think we can just fix the > definitions of 'struct stat64' for asm-generic to make it have the same > layout as the 64-bit version of 'struct stat', and use that for aarch64-ilp32. > > Similarly for the four sysvipc headers, we can have a modified version of > the asm-generic ones in arch/arm64/uapi/asm, which will use the same layout > for ilp32 and lp64 without having to set __kernel_ulong_t to 64-bit. To pick up that earlier thread, I now have a prototype implementation for converting all 32-bit architectures to use 64-bit time_t. For 'struct stat', I ended up introducing a new structure on arm32 that matches the layout of arm64 (and I did the same for all other 32-bit architectures that have a 64-bit counterpart). This means we can share the same system calls between arm64-lp64, arm64-ilp32 and arm32 with 64-bit time_t and arm64-aarch32 emulation for 32-bit time_t, while using the existing compat handling for the original 'struct stat' emulation in both arm32 and arm64-aarch32. However, for ipc, the situation is different: I found a way to use extra padding fields in semid64_ds/shmid64_ds/msqid64_ds, so the ipc system calls will still use normal 32-bit data structures on arm32 and arm64-aarch64, but you cannot use them arm64-ilp32, and will have to #ifdef the three header files there to choose between the two implementations. Arnd -- 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/