From mboxrd@z Thu Jan 1 00:00:00 1970 From: Florian Weimer Subject: Re: [PATCH v3 0/6] mips: system call table generation support Date: Thu, 06 Dec 2018 19:10:57 +0100 Message-ID: <87mupiikzy.fsf@oldenburg2.str.redhat.com> References: <1543481016-18500-1-git-send-email-firoz.khan@linaro.org> <20181205063436.kzxgnvgexcgq572k@pburton-laptop> Mime-Version: 1.0 Content-Type: text/plain Return-path: In-Reply-To: (Maciej W. Rozycki's message of "Thu, 6 Dec 2018 17:43:27 +0000 (GMT)") Sender: linux-kernel-owner@vger.kernel.org To: "Maciej W. Rozycki" Cc: Joseph Myers , Paul Burton , Firoz Khan , "open list:RALINK MIPS ARCHITECTURE" , Ralf Baechle , James Hogan , Greg Kroah-Hartman , Philippe Ombredanne , Thomas Gleixner , Kate Stewart , y2038 Mailman List , Arnd Bergmann , Linux Kernel Mailing List , Linux-Arch , Deepa Dinamani , Marcin Juszkiewicz , libc-alpha@sourceware.org List-Id: linux-arch.vger.kernel.org * Maciej W. Rozycki: > On Thu, 6 Dec 2018, Joseph Myers wrote: > >> > So how are `SYS_' macros generated that land in ? >> >> By gen-syscall-h.awk, which generates #ifdef conditionals for each >> possible __NR_* name (as listed in syscall-names.list in glibc). > > I seem to remember having to take extra care with how the three MIPS ABIs > wire the syscalls to get it right in glibc, but I take it then this has > been now addressed reliably enough for the glibc not to care how exactly > has been arranged. This is a fairly recent change (commit 2dba5ce7b8115d6a2789bf279892263621088e74, ": Use an arch-independent system call list on Linux", first release with it is glibc 2.27). This patch is quite backportable; we have put it into our 2.17-derived glibc, and the upstream work was originally driven by downstream ordering requirements of kernel header and glibc builds. Glad to see it's useful elsewhere. The test retains the old -based macro extraction for testing purposes, but it needs that only for the actual target architecture and only the *names*, so it's easy to implement. Before that, the generation would have to carefully take into account multiple sub-targets (i386/x86-64/x32 is one of the more complicated scenarios). Presumably, you saw problem with that part. Even if you introduce breakage here, it will only affect older glibc builds. It's not something that application developers would see. Thanks, Florian From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx1.redhat.com ([209.132.183.28]:56488 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725898AbeLFSLF (ORCPT ); Thu, 6 Dec 2018 13:11:05 -0500 From: Florian Weimer Subject: Re: [PATCH v3 0/6] mips: system call table generation support References: <1543481016-18500-1-git-send-email-firoz.khan@linaro.org> <20181205063436.kzxgnvgexcgq572k@pburton-laptop> Date: Thu, 06 Dec 2018 19:10:57 +0100 In-Reply-To: (Maciej W. Rozycki's message of "Thu, 6 Dec 2018 17:43:27 +0000 (GMT)") Message-ID: <87mupiikzy.fsf@oldenburg2.str.redhat.com> MIME-Version: 1.0 Content-Type: text/plain Sender: linux-arch-owner@vger.kernel.org List-ID: To: "Maciej W. Rozycki" Cc: Joseph Myers , Paul Burton , Firoz Khan , "open list:RALINK MIPS ARCHITECTURE" , Ralf Baechle , James Hogan , Greg Kroah-Hartman , Philippe Ombredanne , Thomas Gleixner , Kate Stewart , y2038 Mailman List , Arnd Bergmann , Linux Kernel Mailing List , Linux-Arch , Deepa Dinamani , Marcin Juszkiewicz , libc-alpha@sourceware.org Message-ID: <20181206181057.FA-5jgyAbdM3bYMqXPe_9fbSeYEXdDU4ASd0AGEltqQ@z> * Maciej W. Rozycki: > On Thu, 6 Dec 2018, Joseph Myers wrote: > >> > So how are `SYS_' macros generated that land in ? >> >> By gen-syscall-h.awk, which generates #ifdef conditionals for each >> possible __NR_* name (as listed in syscall-names.list in glibc). > > I seem to remember having to take extra care with how the three MIPS ABIs > wire the syscalls to get it right in glibc, but I take it then this has > been now addressed reliably enough for the glibc not to care how exactly > has been arranged. This is a fairly recent change (commit 2dba5ce7b8115d6a2789bf279892263621088e74, ": Use an arch-independent system call list on Linux", first release with it is glibc 2.27). This patch is quite backportable; we have put it into our 2.17-derived glibc, and the upstream work was originally driven by downstream ordering requirements of kernel header and glibc builds. Glad to see it's useful elsewhere. The test retains the old -based macro extraction for testing purposes, but it needs that only for the actual target architecture and only the *names*, so it's easy to implement. Before that, the generation would have to carefully take into account multiple sub-targets (i386/x86-64/x32 is one of the more complicated scenarios). Presumably, you saw problem with that part. Even if you introduce breakage here, it will only affect older glibc builds. It's not something that application developers would see. Thanks, Florian