All of lore.kernel.org
 help / color / mirror / Atom feed
From: sukadev@us.ibm.com
To: "H. Peter Anvin" <hpa@zytor.com>
Cc: Andrew Morton <akpm@osdl.org>,
	clg@fr.ibm.com, serue@us.ibm.com,
	"David C. Hansen" <haveblue@us.ibm.com>,
	Pavel Emelyanov <xemul@openvz.org>,
	Containers <containers@lists.osdl.org>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 0/3] clone64() and unshare64() system calls
Date: Wed, 9 Apr 2008 18:07:17 -0700	[thread overview]
Message-ID: <20080410010717.GA28477@us.ibm.com> (raw)
In-Reply-To: <47FD5899.2040206@zytor.com>

H. Peter Anvin [hpa@zytor.com] wrote:
> sukadev@us.ibm.com wrote:
>> This is a resend of the patch set Cedric had sent earlier. I ported
>> the patch set to 2.6.25-rc8-mm1 and tested on x86 and x86_64.
>> ---
>> We have run out of the 32 bits in clone_flags !
>> This patchset introduces 2 new system calls which support 64bit 
>> clone-flags.
>>      long sys_clone64(unsigned long flags_high, unsigned long flags_low,
>> 		unsigned long newsp);
>>      long sys_unshare64(unsigned long flags_high, unsigned long 
>> flags_low);
>> The current version of clone64() does not support CLONE_PARENT_SETTID and 
>> CLONE_CHILD_CLEARTID because we would exceed the 6 registers limit of some 
>> arches. It's possible to get around this limitation but we might not
>> need it as we already have clone()
>
> I really dislike this interface.
>
> If you're going to make it a 64-bit pass it in as a 64-bit number, instead 
> of breaking it into two numbers.

Maybe I am missing your point. The glibc interface could take a 64bit
parameter, but don't we need to pass 32-bit values into the system call 
on 32 bit systems ?

> Better yet, IMO, would be to pass a pointer to a structure like:
>
> struct shared {
> 	unsigned long nwords;
> 	unsigned long flags[];
> };
>
> ... which can be expanded indefinitely.

Yes, this was discussed before in the context of Pavel Emelyanov's patch

	http://lkml.org/lkml/2008/1/16/109

along with sys_indirect().  While there was no consensus, it looked like
adding a new system call was better than open ended interfaces.

  reply	other threads:[~2008-04-10  1:07 UTC|newest]

Thread overview: 35+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-04-09 22:26 [PATCH 0/3] clone64() and unshare64() system calls sukadev
2008-04-09 22:32 ` [PATCH 1/3] change clone_flags type to u64 sukadev
2008-04-10  8:25   ` Andi Kleen
2008-04-10 12:25     ` Cedric Le Goater
2008-04-10 12:52       ` Andi Kleen
     [not found]         ` <20080410125205.GG10019-qrUzlfsMFqo/4alezvVtWx2eb7JE58TQ@public.gmane.org>
2008-04-10 13:11           ` Kirill Korotaev
2008-04-10 13:11             ` Kirill Korotaev
2008-04-10 13:23             ` Cedric Le Goater
2008-04-10 13:18         ` Cedric Le Goater
2008-04-10 17:14         ` Serge E. Hallyn
2008-04-10 22:13           ` Daniel Hokka Zakrisson
2008-04-10 22:49             ` Serge E. Hallyn
2008-04-11  8:45               ` Daniel Hokka Zakrisson
2008-04-11  8:45                 ` Daniel Hokka Zakrisson
2008-04-09 22:34 ` [PATCH 2/3] add do_unshare() sukadev
2008-04-09 22:34 ` [PATCH 3/3] add the clone64() and unshare64() syscalls sukadev
     [not found]   ` <20080409223459.GC28267-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
2008-04-09 23:07     ` Jakub Jelinek
2008-04-09 23:07       ` Jakub Jelinek
2008-04-10  2:15       ` sukadev
     [not found]         ` <20080410021523.GB28477-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
2008-04-10  3:40           ` H. Peter Anvin
2008-04-10  3:40             ` H. Peter Anvin
     [not found] ` <20080409222611.GA28087-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
2008-04-10  0:00   ` [PATCH 0/3] clone64() and unshare64() system calls H. Peter Anvin
2008-04-10  0:00     ` H. Peter Anvin
2008-04-10  1:07     ` sukadev [this message]
     [not found]       ` <20080410010717.GA28477-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
2008-04-10  1:10         ` H. Peter Anvin
2008-04-10  1:10           ` H. Peter Anvin
2008-04-10  2:38           ` sukadev
2008-04-10  2:43             ` Paul Menage
2008-04-10 18:26               ` sukadev
     [not found]                 ` <20080410182616.GF28477-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
2008-04-10 18:31                   ` H. Peter Anvin
2008-04-10 18:31                     ` H. Peter Anvin
2008-04-10 12:33           ` Cedric Le Goater
     [not found]             ` <47FE0906.8080102-NmTC/0ZBporQT0dZR+AlfA@public.gmane.org>
2008-04-10 16:00               ` H. Peter Anvin
2008-04-10 16:00                 ` H. Peter Anvin
2008-04-10  6:48     ` Cedric Le Goater

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=20080410010717.GA28477@us.ibm.com \
    --to=sukadev@us.ibm.com \
    --cc=akpm@osdl.org \
    --cc=clg@fr.ibm.com \
    --cc=containers@lists.osdl.org \
    --cc=haveblue@us.ibm.com \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=serue@us.ibm.com \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.