public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: corbet@lwn.net (Jonathan Corbet)
To: Al Viro <viro@ZenIV.linux.org.uk>
Cc: Pavel Emelyanov <xemul@openvz.org>,
	Linux Containers <containers@lists.osdl.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Cedric Le Goater <clg@fr.ibm.com>,
	drepper@redhat.com, Serge Hallyn <serue@us.ibm.com>,
	Andrew Morton <akpm@linux-foundation.org>
Subject: Extending syscalls (was: [PATCH 1/2] Extend sys_clone and sys_unshare system calls API)
Date: Thu, 17 Jan 2008 08:02:05 -0700	[thread overview]
Message-ID: <25712.1200582125@vena.lwn.net> (raw)
In-Reply-To: Your message of "Thu, 17 Jan 2008 03:48:44 GMT." <20080117034844.GA27894@ZenIV.linux.org.uk>

Al Viro sez:

> Nah, just put an XML parser into the kernel to have the form match the
> contents...
> 
> Al "perhaps we should newgroup alt.tasteless.api for all that stuff" Viro

Heh, indeed.  But we do seem to have a recurring problem of people
wanting to extend sys_foo() beyond the confines of its original API.
I've observed a few ways of doing that:

 - create sys_foo2() (or sys_foo64(), or sys_fooat(), or sys_pfoo(),
   or...) and add the new stuff there.

 - Put a version number into the API somewhere - wireless extensions,
   for example.

 - Set a flag saying "I've stashed some additional parameters somewhere
   else."  That's sys_indirect() and the current proposal for extending
   clone().

 - Just do it all with a kernel-based XML parser.  I think we should
   call this approach sys_viro() in honor of its champion.

 - Do it all in sysfs

The first approach has traditionally been the most popular.  If we have
a consensus that this is the way to extend system calls in the future,
it would be nice to set that down somewhere.  We could avoid a lot of
API blind alleys that way.

jon

  parent reply	other threads:[~2008-01-17 15:02 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-01-16 12:58 [PATCH 1/2] Extend sys_clone and sys_unshare system calls API Pavel Emelyanov
2008-01-16 13:00 ` [PATCH 2/2] Propagate the long_clone_arg up to the create_new_namespaces Pavel Emelyanov
2008-01-16 14:23 ` [PATCH 1/2] Extend sys_clone and sys_unshare system calls API Jonathan Corbet
2008-01-16 15:05   ` Pavel Emelyanov
2008-01-17  3:48   ` Al Viro
2008-01-17  9:28     ` Cedric Le Goater
2008-01-17 15:02     ` Jonathan Corbet [this message]
2008-01-17 19:26       ` Extending syscalls H. Peter Anvin
2008-01-23 20:59 ` [PATCH 1/2] Extend sys_clone and sys_unshare system calls API Pavel Machek
2008-01-24 17:09   ` Cedric Le Goater
2008-01-24 17:24     ` Dave Hansen
2008-01-24 17:37       ` Pavel Machek
2008-01-24 17:46         ` Dave Hansen
2008-01-24 17:50           ` Pavel Machek

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=25712.1200582125@vena.lwn.net \
    --to=corbet@lwn.net \
    --cc=akpm@linux-foundation.org \
    --cc=clg@fr.ibm.com \
    --cc=containers@lists.osdl.org \
    --cc=drepper@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=serue@us.ibm.com \
    --cc=viro@ZenIV.linux.org.uk \
    --cc=xemul@openvz.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox