Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp6949305imu; Wed, 14 Nov 2018 09:20:20 -0800 (PST) X-Google-Smtp-Source: AJdET5cKpBU5YeahNliIH3DR4CCokcbrOxXogt73gH4n3b6JCiBGhhhUlCgF9np3uA3V4ACIDvRg X-Received: by 2002:a63:8549:: with SMTP id u70mr2525515pgd.401.1542216019883; Wed, 14 Nov 2018 09:20:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1542216019; cv=none; d=google.com; s=arc-20160816; b=YgffFrIzebkpj4qwfcZMWhr0Q+ctG5ODjLDhu1tiEb03swdAqfOsSc1zaZOzEURO4q jP1ETSUy7ZCwI0HJBqhXtiNTCaDezX+oeWAwzfM8Xw1TO0r4QW9u9ps9IzFVYqemA9J4 ce09rTZ+uSTkdOZN1iWgw6q7Iqc6WJLdH1jqAMtgm72sQFyAyPhYoOZmsps/utDo4OT5 N1r4KxUZVHboDxpvv1Qr7nqVzrP48Uyn4SzTcOCVvoWwnRZAKjLPqAioBLmf0PpCEZKD nq/tT+38aMb0ok7nWvAiq/ygdTm5edZrwZqyH1EJUreZE/+/VBDMZMP2l9jc1zOsQZzJ WSNw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version; bh=sHz0yCVMU206e0kUS3dS54a4/XNAYhpN3p3RpaFMfs4=; b=PAU+sVCpJzNxqzoQIAeafB6ajzYdTIdoBhbQz1m6Wa6a3EYwtIIdoxcrwKU5OM5nTD P1xgNsJbhojdjSd+URFpgvCSJggskAZbypjrqirvkrB1zlglzmL2c97S+9kS2anfiuOC 7kySFOscQqwK2SOBwuOpMlOkJj7S0cJs3uparC6ks+tllpik5Q1mQkNPoEAs8GihkzdA RA649QW49JED8q955I4U1J/2vC6Ryw5RZcdSH3MKRj+dpy5OAF8br204/WhEqh1Peh5D 1Bnj7HpYr48HUhwaWUZpr6Bqss+i+ymev54PJnKSnJpmKIAv9VHY3QUplgOiRRku/unO n3iA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z14si24932327pgz.180.2018.11.14.09.19.45; Wed, 14 Nov 2018 09:20:19 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732840AbeKODT4 (ORCPT + 99 others); Wed, 14 Nov 2018 22:19:56 -0500 Received: from mail-qk1-f196.google.com ([209.85.222.196]:43623 "EHLO mail-qk1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726823AbeKODT4 (ORCPT ); Wed, 14 Nov 2018 22:19:56 -0500 Received: by mail-qk1-f196.google.com with SMTP id r71so27077980qkr.10; Wed, 14 Nov 2018 09:15:53 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=sHz0yCVMU206e0kUS3dS54a4/XNAYhpN3p3RpaFMfs4=; b=Cr/SrZxDFLyA+Etdm43Whq0/grwGHW8yCt7J5ESQbVIH0C/tyk7qkGld3dQGXkcDT6 N1HPRGjbm6hFOIU7cBD+srQTlrPAAyFnwswi19n7iQusb3pBf4ARFt6M9HAxxvFfWapp UN84EAd3MS4jph4+EpeH1tZL6DySEAticgYFsitgx/MusJDTseJ/0xjbJV41JpdnVEZu vGzzgh3mxG+H0MPSfc0zZcldA5c+psJO7BexY/V5QM/CwXVRlfZhzOlfq+C2kDYFEqDv ek8t46A2rKYUJArD6D7aPKMDpg7TTAz0/LRzmXT0WZ0ePFOyQjsJ2cX+wCgCT6SBac+e yQBg== X-Gm-Message-State: AGRZ1gKp2s/byKMiMIXv7Mm6af6SgigE73jvVJwyiu16BKCbxcjomlGw SZQh6KS3pWbF7JfebrNct8pnFjs8vIK7dcCxewg= X-Received: by 2002:ac8:7451:: with SMTP id h17mr2550347qtr.319.1542215752520; Wed, 14 Nov 2018 09:15:52 -0800 (PST) MIME-Version: 1.0 References: <877ehjx447.fsf@oldenburg.str.redhat.com> <875zx2vhpd.fsf@oldenburg.str.redhat.com> <20181113193859.GJ3505@e103592.cambridge.arm.com> <5853c297-9d84-86e5-dede-aa2957562c6b@arm.com> In-Reply-To: From: Arnd Bergmann Date: Wed, 14 Nov 2018 09:15:34 -0800 Message-ID: Subject: Re: Official Linux system wrapper library? To: carlos@redhat.com Cc: Szabolcs Nagy , Dave Martin , dancol@google.com, nd@arm.com, Florian Weimer , Michael Kerrisk , Linux Kernel Mailing List , Joel Fernandes , Linux API , Willy Tarreau , Vlastimil Babka , GNU C Library , Firoz Khan Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Nov 14, 2018 at 6:58 AM Carlos O'Donell wrote: > On 11/14/18 6:58 AM, Szabolcs Nagy wrote: > > an actual proposal in the thread that i think is > > worth considering is to make the linux syscall > > design process involve libc devs so the c api is > > designed together with the syscall abi. > > * Programmatic / Machine readable description of syscalls. > This way the kernel gives users the ability to autogenerate > all the wrappers *if they want to* in a consistent way that > matches this syscall description format. Firoz Khan is in the process of doing part of this, by changing the in-kernel per-architecture unistd.h and syscall.S files into a architecture independent machine-readable format that is used to generate the existing files. The format will be similar to what we have on arm/s390/x86 in the syscall.tbl files already. This is of course only part of the picture, it answers the question of which syscalls are implemented on an architecture, which number they have and (ideally) whether they use a standard implementation or a custom one, but it does not yet relate to the prototype. Once this work is merged, we can follow up by coming up with a way to add prototypes and enforcing that the user space wrapper uses the same argument types as the in-kernel entry point. Arnd