2007-05-08 18:52:05

by Chris Wedgwood

[permalink] [raw]
Subject: [PATCH] [x86-64] Add getcpu and epoll_pwait system calls.

Signed-off-by: Chris Wedgwood <[email protected]>
---
include/asm-x86_64/unistd.h | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/include/asm-x86_64/unistd.h b/include/asm-x86_64/unistd.h
index 26e23e0..aa7d4bf 100644
--- a/include/asm-x86_64/unistd.h
+++ b/include/asm-x86_64/unistd.h
@@ -619,6 +619,10 @@ __SYSCALL(__NR_sync_file_range, sys_sync_file_range)
__SYSCALL(__NR_vmsplice, sys_vmsplice)
#define __NR_move_pages 279
__SYSCALL(__NR_move_pages, sys_move_pages)
+#define __NR_getcpu 280
+__SYSCALL(__NR_getcpu, sys_getcpu)
+#define __NR_epoll_pwait 281
+__SYSCALL(__NR_epoll_pwait, sys_epoll_pwait)

#ifndef __NO_STUBS
#define __ARCH_WANT_OLD_READDIR
--
1.5.1.3


2007-05-08 21:28:14

by Chris Wedgwood

[permalink] [raw]
Subject: Re: [PATCH] [x86-64] Add getcpu and epoll_pwait system calls.

On Tue, May 08, 2007 at 11:37:26AM -0700, Chris Wedgwood wrote:

> +#define __NR_getcpu 280

I see something was merged just now that uses 280. Should I resubmit
this using 281 & 282?

2007-05-08 22:13:55

by Andi Kleen

[permalink] [raw]
Subject: Re: [PATCH] [x86-64] Add getcpu and epoll_pwait system calls.

On Tue, May 08, 2007 at 11:37:26AM -0700, Chris Wedgwood wrote:
> Signed-off-by: Chris Wedgwood <[email protected]>
> ---
> include/asm-x86_64/unistd.h | 4 ++++
> 1 files changed, 4 insertions(+), 0 deletions(-)
> diff --git a/include/asm-x86_64/unistd.h b/include/asm-x86_64/unistd.h
> index 26e23e0..aa7d4bf 100644
> --- a/include/asm-x86_64/unistd.h
> +++ b/include/asm-x86_64/unistd.h
> @@ -619,6 +619,10 @@ __SYSCALL(__NR_sync_file_range, sys_sync_file_range)
> __SYSCALL(__NR_vmsplice, sys_vmsplice)
> #define __NR_move_pages 279
> __SYSCALL(__NR_move_pages, sys_move_pages)
> +#define __NR_getcpu 280
> +__SYSCALL(__NR_getcpu, sys_getcpu)

Nope. There already is a getcpu vsyscall. This is not needed.

> +#define __NR_epoll_pwait 281
> +__SYSCALL(__NR_epoll_pwait, sys_epoll_pwait)


Will add thanks

-Andi

2007-05-08 22:19:20

by Chris Wedgwood

[permalink] [raw]
Subject: Re: [PATCH] [x86-64] Add getcpu and epoll_pwait system calls.

On Wed, May 09, 2007 at 12:13:48AM +0200, Andi Kleen wrote:

> Nope. There already is a getcpu vsyscall. This is not needed.

The kbuild magic that checks for missing syscalls needs to be taught
about this then I take it?

2007-05-08 22:24:37

by Andi Kleen

[permalink] [raw]
Subject: Re: [PATCH] [x86-64] Add getcpu and epoll_pwait system calls.

On Tue, May 08, 2007 at 03:16:56PM -0700, Chris Wedgwood wrote:
> On Wed, May 09, 2007 at 12:13:48AM +0200, Andi Kleen wrote:
>
> > Nope. There already is a getcpu vsyscall. This is not needed.
>
> The kbuild magic that checks for missing syscalls needs to be taught
> about this then I take it?
>

Somehow yes. But i'm not going to add a useless syscall just to shut it up.

-Andi

2007-05-08 22:43:31

by Chris Wedgwood

[permalink] [raw]
Subject: Re: [PATCH] [x86-64] Add getcpu and epoll_pwait system calls.

On Wed, May 09, 2007 at 12:24:32AM +0200, Andi Kleen wrote:

> Somehow yes. But i'm not going to add a useless syscall just to
> shut it up.

It turns out this has come up in other places. Sam has a suggestion
on how to silence this per-arch so I'll post a patch once that change
is in.

2007-05-09 08:44:05

by Russell King

[permalink] [raw]
Subject: Re: [PATCH] [x86-64] Add getcpu and epoll_pwait system calls.

On Tue, May 08, 2007 at 03:43:22PM -0700, Chris Wedgwood wrote:
> On Wed, May 09, 2007 at 12:24:32AM +0200, Andi Kleen wrote:
>
> > Somehow yes. But i'm not going to add a useless syscall just to
> > shut it up.
>
> It turns out this has come up in other places. Sam has a suggestion
> on how to silence this per-arch so I'll post a patch once that change
> is in.

We knew about this when David and myself designed the detection
method, and a method of ignoring those calls which were never going
to be implemented on a particular architecture.

Just add:

#define __IGNORE_getcpu

to asm/unistd.h, preferably in a __KERNEL__ protected area.

--
Russell King
Linux kernel 2.6 ARM Linux - http://www.arm.linux.org.uk/
maintainer of: