public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] remove timerd() syscall number
@ 2007-09-17 16:58 Michael Kerrisk
  2007-09-17 20:43 ` Andrew Morton
  0 siblings, 1 reply; 3+ messages in thread
From: Michael Kerrisk @ 2007-09-17 16:58 UTC (permalink / raw)
  To: Andrew Morton
  Cc: davidel, vda.linux, rdunlap, tglx, linux-kernel, torvalds,
	drepper, stable, hch, jengelh, corbet, stable

Hi Andrew

I hope I've done this right...  This patch, against 2.6.23-rc6,
removes the timerfd() syscall (which in any case had a bug
on its 2.6.22 release) from all architectures, so that we
can have some breathing space to think about the API design.
All of the existing timerfd() code is left intact.

Please apply, so that 2.6.23 does not expose timerfd().

Cheers,

Michael

diff -pur linux-2.6.23-rc6/include/asm/unistd.h linux-2.6.23-rc6-new/include/asm/unistd.h
--- linux-2.6.23-rc6/include/asm/unistd.h	2007-09-13 18:43:41.000000000 +0200
+++ linux-2.6.23-rc6-new/include/asm/unistd.h	2007-09-14 10:51:38.000000000 +0200
@@ -327,7 +327,8 @@
 #define __NR_epoll_pwait	319
 #define __NR_utimensat		320
 #define __NR_signalfd		321
-#define __NR_timerfd		322
+/* Let's pause a moment before we decide on the final timerfd API */
+/* #define __NR_timerfd		322 */
 #define __NR_eventfd		323
 #define __NR_fallocate		324

diff -pur linux-2.6.23-rc6/include/asm-alpha/unistd.h linux-2.6.23-rc6-new/include/asm-alpha/unistd.h
--- linux-2.6.23-rc6/include/asm-alpha/unistd.h	2007-07-28 23:59:39.000000000 +0200
+++ linux-2.6.23-rc6-new/include/asm-alpha/unistd.h	2007-09-13 22:12:18.000000000 +0200
@@ -431,7 +431,7 @@
 #define __NR_epoll_pwait		474
 #define __NR_utimensat			475
 #define __NR_signalfd			476
-#define __NR_timerfd			477
+/* #define __NR_timerfd			477 */
 #define __NR_eventfd			478

 #ifdef __KERNEL__
diff -pur linux-2.6.23-rc6/include/asm-arm/unistd.h linux-2.6.23-rc6-new/include/asm-arm/unistd.h
--- linux-2.6.23-rc6/include/asm-arm/unistd.h	2007-09-13 18:43:40.000000000 +0200
+++ linux-2.6.23-rc6-new/include/asm-arm/unistd.h	2007-09-13 22:12:22.000000000 +0200
@@ -376,7 +376,7 @@
 #define __NR_kexec_load			(__NR_SYSCALL_BASE+347)
 #define __NR_utimensat			(__NR_SYSCALL_BASE+348)
 #define __NR_signalfd			(__NR_SYSCALL_BASE+349)
-#define __NR_timerfd			(__NR_SYSCALL_BASE+350)
+/* #define __NR_timerfd			(__NR_SYSCALL_BASE+350) */
 #define __NR_eventfd			(__NR_SYSCALL_BASE+351)

 /*
diff -pur linux-2.6.23-rc6/include/asm-avr32/unistd.h linux-2.6.23-rc6-new/include/asm-avr32/unistd.h
--- linux-2.6.23-rc6/include/asm-avr32/unistd.h	2007-07-28 23:59:46.000000000 +0200
+++ linux-2.6.23-rc6-new/include/asm-avr32/unistd.h	2007-09-13 22:12:29.000000000 +0200
@@ -297,7 +297,7 @@

 #define __NR_utimensat		278
 #define __NR_signalfd		279
-#define __NR_timerfd		280
+/* #define __NR_timerfd		280 */
 #define __NR_eventfd		281

 #ifdef __KERNEL__
diff -pur linux-2.6.23-rc6/include/asm-frv/unistd.h linux-2.6.23-rc6-new/include/asm-frv/unistd.h
--- linux-2.6.23-rc6/include/asm-frv/unistd.h	2007-09-13 18:43:41.000000000 +0200
+++ linux-2.6.23-rc6-new/include/asm-frv/unistd.h	2007-09-13 22:12:53.000000000 +0200
@@ -328,7 +328,7 @@
 #define __NR_epoll_pwait	319
 #define __NR_utimensat		320
 #define __NR_signalfd		321
-#define __NR_timerfd		322
+/* #define __NR_timerfd		322 */
 #define __NR_eventfd		323
 #define __NR_fallocate		324

diff -pur linux-2.6.23-rc6/include/asm-i386/unistd.h linux-2.6.23-rc6-new/include/asm-i386/unistd.h
--- linux-2.6.23-rc6/include/asm-i386/unistd.h	2007-09-13 18:43:41.000000000 +0200
+++ linux-2.6.23-rc6-new/include/asm-i386/unistd.h	2007-09-14 10:51:38.000000000 +0200
@@ -327,7 +327,8 @@
 #define __NR_epoll_pwait	319
 #define __NR_utimensat		320
 #define __NR_signalfd		321
-#define __NR_timerfd		322
+/* Let's pause a moment before we decide on the final timerfd API */
+/* #define __NR_timerfd		322 */
 #define __NR_eventfd		323
 #define __NR_fallocate		324

diff -pur linux-2.6.23-rc6/include/asm-ia64/unistd.h linux-2.6.23-rc6-new/include/asm-ia64/unistd.h
--- linux-2.6.23-rc6/include/asm-ia64/unistd.h	2007-09-13 18:43:41.000000000 +0200
+++ linux-2.6.23-rc6-new/include/asm-ia64/unistd.h	2007-09-13 22:13:03.000000000 +0200
@@ -297,7 +297,7 @@
 #define __NR_epoll_pwait		1305
 #define __NR_utimensat			1306
 #define __NR_signalfd			1307
-#define __NR_timerfd			1308
+/* #define __NR_timerfd			1308 */
 #define __NR_eventfd			1309

 #ifdef __KERNEL__
diff -pur linux-2.6.23-rc6/include/asm-mips/unistd.h linux-2.6.23-rc6-new/include/asm-mips/unistd.h
--- linux-2.6.23-rc6/include/asm-mips/unistd.h	2007-09-13 18:43:42.000000000 +0200
+++ linux-2.6.23-rc6-new/include/asm-mips/unistd.h	2007-09-13 22:13:16.000000000 +0200
@@ -338,7 +338,7 @@
 #define __NR_ioprio_get			(__NR_Linux + 315)
 #define __NR_utimensat			(__NR_Linux + 316)
 #define __NR_signalfd			(__NR_Linux + 317)
-#define __NR_timerfd			(__NR_Linux + 318)
+/* #define __NR_timerfd			(__NR_Linux + 318) */
 #define __NR_eventfd			(__NR_Linux + 319)
 #define __NR_fallocate			(__NR_Linux + 320)

@@ -635,7 +635,7 @@
 #define __NR_ioprio_get			(__NR_Linux + 274)
 #define __NR_utimensat			(__NR_Linux + 275)
 #define __NR_signalfd			(__NR_Linux + 276)
-#define __NR_timerfd			(__NR_Linux + 277)
+/* #define __NR_timerfd			(__NR_Linux + 277) */
 #define __NR_eventfd			(__NR_Linux + 278)
 #define __NR_fallocate			(__NR_Linux + 279)

@@ -936,7 +936,7 @@
 #define __NR_ioprio_get			(__NR_Linux + 278)
 #define __NR_utimensat			(__NR_Linux + 279)
 #define __NR_signalfd			(__NR_Linux + 280)
-#define __NR_timerfd			(__NR_Linux + 281)
+/* #define __NR_timerfd			(__NR_Linux + 281) */
 #define __NR_eventfd			(__NR_Linux + 282)
 #define __NR_fallocate			(__NR_Linux + 283)

diff -pur linux-2.6.23-rc6/include/asm-parisc/unistd.h linux-2.6.23-rc6-new/include/asm-parisc/unistd.h
--- linux-2.6.23-rc6/include/asm-parisc/unistd.h	2007-07-28 23:59:57.000000000 +0200
+++ linux-2.6.23-rc6-new/include/asm-parisc/unistd.h	2007-09-13 22:13:23.000000000 +0200
@@ -795,7 +795,7 @@
 #define __NR_kexec_load		(__NR_Linux + 300)
 #define __NR_utimensat		(__NR_Linux + 301)
 #define __NR_signalfd		(__NR_Linux + 302)
-#define __NR_timerfd		(__NR_Linux + 303)
+/* #define __NR_timerfd		(__NR_Linux + 303) */
 #define __NR_eventfd		(__NR_Linux + 304)

 #define __NR_Linux_syscalls	(__NR_eventfd + 1)
diff -pur linux-2.6.23-rc6/include/asm-powerpc/unistd.h linux-2.6.23-rc6-new/include/asm-powerpc/unistd.h
--- linux-2.6.23-rc6/include/asm-powerpc/unistd.h	2007-09-13 18:43:43.000000000 +0200
+++ linux-2.6.23-rc6-new/include/asm-powerpc/unistd.h	2007-09-13 22:13:27.000000000 +0200
@@ -328,7 +328,7 @@
 #define __NR_epoll_pwait	303
 #define __NR_utimensat		304
 #define __NR_signalfd		305
-#define __NR_timerfd		306
+/* #define __NR_timerfd		306 */
 #define __NR_eventfd		307
 #define __NR_sync_file_range2	308
 #define __NR_fallocate		309
diff -pur linux-2.6.23-rc6/include/asm-s390/unistd.h linux-2.6.23-rc6-new/include/asm-s390/unistd.h
--- linux-2.6.23-rc6/include/asm-s390/unistd.h	2007-09-13 18:43:43.000000000 +0200
+++ linux-2.6.23-rc6-new/include/asm-s390/unistd.h	2007-09-13 22:13:30.000000000 +0200
@@ -254,7 +254,7 @@
 #define __NR_fallocate		314
 #define __NR_utimensat		315
 #define __NR_signalfd		316
-#define __NR_timerfd		317
+/* #define __NR_timerfd		317 */
 #define __NR_eventfd		318
 #define NR_syscalls 319

diff -pur linux-2.6.23-rc6/include/asm-sh/unistd.h linux-2.6.23-rc6-new/include/asm-sh/unistd.h
--- linux-2.6.23-rc6/include/asm-sh/unistd.h	2007-09-13 18:43:43.000000000 +0200
+++ linux-2.6.23-rc6-new/include/asm-sh/unistd.h	2007-09-13 22:13:34.000000000 +0200
@@ -330,7 +330,7 @@
 #define __NR_epoll_pwait	319
 #define __NR_utimensat		320
 #define __NR_signalfd		321
-#define __NR_timerfd		322
+/* #define __NR_timerfd		322 */
 #define __NR_eventfd		323
 #define __NR_fallocate		324

diff -pur linux-2.6.23-rc6/include/asm-sh64/unistd.h linux-2.6.23-rc6-new/include/asm-sh64/unistd.h
--- linux-2.6.23-rc6/include/asm-sh64/unistd.h	2007-09-13 18:43:43.000000000 +0200
+++ linux-2.6.23-rc6-new/include/asm-sh64/unistd.h	2007-09-13 22:13:43.000000000 +0200
@@ -372,7 +372,7 @@
 #define __NR_epoll_pwait	347
 #define __NR_utimensat		348
 #define __NR_signalfd		349
-#define __NR_timerfd		350
+/* #define __NR_timerfd		350 */
 #define __NR_eventfd		351
 #define __NR_fallocate		352

diff -pur linux-2.6.23-rc6/include/asm-sparc/unistd.h linux-2.6.23-rc6-new/include/asm-sparc/unistd.h
--- linux-2.6.23-rc6/include/asm-sparc/unistd.h	2007-09-13 18:43:43.000000000 +0200
+++ linux-2.6.23-rc6-new/include/asm-sparc/unistd.h	2007-09-13 22:13:48.000000000 +0200
@@ -327,7 +327,7 @@
 #define __NR_epoll_pwait	309
 #define __NR_utimensat		310
 #define __NR_signalfd		311
-#define __NR_timerfd		312
+/* #define __NR_timerfd		312 */
 #define __NR_eventfd		313
 #define __NR_fallocate		314

diff -pur linux-2.6.23-rc6/include/asm-sparc64/unistd.h linux-2.6.23-rc6-new/include/asm-sparc64/unistd.h
--- linux-2.6.23-rc6/include/asm-sparc64/unistd.h	2007-09-13 18:43:43.000000000 +0200
+++ linux-2.6.23-rc6-new/include/asm-sparc64/unistd.h	2007-09-13 22:13:59.000000000 +0200
@@ -329,7 +329,7 @@
 #define __NR_epoll_pwait	309
 #define __NR_utimensat		310
 #define __NR_signalfd		311
-#define __NR_timerfd		312
+/* #define __NR_timerfd		312 */
 #define __NR_eventfd		313
 #define __NR_fallocate		314

diff -pur linux-2.6.23-rc6/include/asm-x86_64/unistd.h linux-2.6.23-rc6-new/include/asm-x86_64/unistd.h
--- linux-2.6.23-rc6/include/asm-x86_64/unistd.h	2007-09-13 18:43:44.000000000 +0200
+++ linux-2.6.23-rc6-new/include/asm-x86_64/unistd.h	2007-09-13 22:14:09.000000000 +0200
@@ -626,8 +626,8 @@ __SYSCALL(__NR_utimensat, sys_utimensat)
 __SYSCALL(__NR_epoll_pwait, sys_epoll_pwait)
 #define __NR_signalfd		282
 __SYSCALL(__NR_signalfd, sys_signalfd)
-#define __NR_timerfd		283
-__SYSCALL(__NR_timerfd, sys_timerfd)
+/* #define __NR_timerfd		283
+__SYSCALL(__NR_timerfd, sys_timerfd) */
 #define __NR_eventfd		284
 __SYSCALL(__NR_eventfd, sys_eventfd)
 #define __NR_fallocate		285




^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] remove timerd() syscall number
  2007-09-17 16:58 [PATCH] remove timerd() syscall number Michael Kerrisk
@ 2007-09-17 20:43 ` Andrew Morton
  2007-09-17 21:02   ` Michael Kerrisk
  0 siblings, 1 reply; 3+ messages in thread
From: Andrew Morton @ 2007-09-17 20:43 UTC (permalink / raw)
  To: Michael Kerrisk
  Cc: davidel, vda.linux, rdunlap, tglx, linux-kernel, torvalds,
	drepper, stable, hch, jengelh, corbet

On Mon, 17 Sep 2007 18:58:58 +0200
Michael Kerrisk <mtk-manpages@gmx.net> wrote:

> I hope I've done this right...  This patch, against 2.6.23-rc6,
> removes the timerfd() syscall (which in any case had a bug
> on its 2.6.22 release) from all architectures, so that we
> can have some breathing space to think about the API design.
> All of the existing timerfd() code is left intact.

I think a minimally-intrusive implementation would be

--- a/fs/timerfd.c~a
+++ a/fs/timerfd.c
@@ -159,6 +159,8 @@ asmlinkage long sys_timerfd(int ufd, int
 	struct inode *inode;
 	struct itimerspec ktmr;
 
+	return -ENOSYS;
+
 	if (copy_from_user(&ktmr, utmr, sizeof(ktmr)))
 		return -EFAULT;
 
_

or, better,

--- a/init/Kconfig~a
+++ a/init/Kconfig
@@ -491,6 +491,7 @@ config SIGNALFD
 
 config TIMERFD
 	bool "Enable timerfd() system call" if EMBEDDED
+	depends on BROKEN
 	select ANON_INODES
 	default y
 	help
_


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] remove timerd() syscall number
  2007-09-17 20:43 ` Andrew Morton
@ 2007-09-17 21:02   ` Michael Kerrisk
  0 siblings, 0 replies; 3+ messages in thread
From: Michael Kerrisk @ 2007-09-17 21:02 UTC (permalink / raw)
  To: Andrew Morton
  Cc: corbet, jengelh, hch, stable, drepper, torvalds, linux-kernel,
	tglx, rdunlap, vda.linux, davidel

> > I hope I've done this right...  This patch, against 2.6.23-rc6,
> > removes the timerfd() syscall (which in any case had a bug
> > on its 2.6.22 release) from all architectures, so that we
> > can have some breathing space to think about the API design.
> > All of the existing timerfd() code is left intact.
> 
> I think a minimally-intrusive implementation would be
> 
> --- a/fs/timerfd.c~a
> +++ a/fs/timerfd.c
> @@ -159,6 +159,8 @@ asmlinkage long sys_timerfd(int ufd, int
>  	struct inode *inode;
>  	struct itimerspec ktmr;
>  
> +	return -ENOSYS;
> +
>  	if (copy_from_user(&ktmr, utmr, sizeof(ktmr)))
>  		return -EFAULT;
>  
> _
> 
> or, better,
> 
> --- a/init/Kconfig~a
> +++ a/init/Kconfig
> @@ -491,6 +491,7 @@ config SIGNALFD
>  
>  config TIMERFD
>  	bool "Enable timerfd() system call" if EMBEDDED
> +	depends on BROKEN
>  	select ANON_INODES
>  	default y
>  	help
> _

Cough!  Right then.  I take it you'll apply one of those then?
-- 
Michael Kerrisk
maintainer of Linux man pages Sections 2, 3, 4, 5, and 7 

Want to help with man page maintenance?  
Grab the latest tarball at
http://www.kernel.org/pub/linux/docs/manpages , 
read the HOWTOHELP file and grep the source 
files for 'FIXME'.


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2007-09-17 21:02 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-09-17 16:58 [PATCH] remove timerd() syscall number Michael Kerrisk
2007-09-17 20:43 ` Andrew Morton
2007-09-17 21:02   ` Michael Kerrisk

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox