Re: [patch 2/4] syscalls, x86: Add __NR_kcmp syscall v8

From: Andrew Morton
Date: Wed Feb 15 2012 - 16:53:13 EST


On Wed, 15 Feb 2012 11:24:54 +0400
Cyrill Gorcunov <gorcunov@xxxxxxxxxx> wrote:

> On Wed, Feb 15, 2012 at 11:04:27AM +0400, Cyrill Gorcunov wrote:
> > On Tue, Feb 14, 2012 at 10:55:55PM -0800, hpanvin@xxxxxxxxx wrote:
> > >
> > > What? <linux/unistd.h> should be used, and it should handle
> > > the inclusions.
> > >
> >
> > Peter, I maybe missing something which directories I should
> > add to -I option, letme recheck (but without headers_intall
> > target the syscall number is unresolved for me).
> >
>
> Ah, I missed to add
>
> +CFLAGS += -I../../../../arch/x86/include/
>
> into Makefile. Andrew, should I send update as a separate
> patch?
>

That worked.

What's with all those warnings, btw?


From: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
Subject: syscalls-x86-add-__nr_kcmp-syscall-v8-fix-fix-fix

kcmp_test.c: In function 'main':
kcmp_test.c:69: warning: format '%2d' expects type 'int', but argument 4 has type 'long int'
kcmp_test.c:69: warning: format '%2d' expects type 'int', but argument 5 has type 'long int'
kcmp_test.c:69: warning: format '%2d' expects type 'int', but argument 6 has type 'long int'
kcmp_test.c:69: warning: format '%2d' expects type 'int', but argument 7 has type 'long int'
kcmp_test.c:69: warning: format '%2d' expects type 'int', but argument 8 has type 'long int'
kcmp_test.c:69: warning: format '%2d' expects type 'int', but argument 9 has type 'long int'
kcmp_test.c:69: warning: format '%2d' expects type 'int', but argument 10 has type 'long int'
kcmp_test.c:69: warning: format '%2d' expects type 'int', but argument 11 has type 'long int'

Cc: "Eric W. Biederman" <ebiederm@xxxxxxxxxxxx>
Cc: Cyrill Gorcunov <gorcunov@xxxxxxxxxx>
Cc: Frederic Weisbecker <fweisbec@xxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

tools/testing/selftests/kcmp/kcmp_test.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)

--- a/tools/testing/selftests/kcmp/kcmp_test.c~syscalls-x86-add-__nr_kcmp-syscall-v8-fix-fix-fix
+++ a/tools/testing/selftests/kcmp/kcmp_test.c
@@ -54,8 +54,9 @@ int main(int argc, char **argv)
}

/* An example of output and arguments */
- printf("pid1: %6d pid2: %6d FD: %2d FILES: %2d VM: %2d FS: %2d "
- "SIGHAND: %2d IO: %2d SYSVSEM: %2d INV: %2d\n",
+ printf("pid1: %6d pid2: %6d FD: %2ld FILES: %2ld VM: %2ld "
+ "FS: %2ld SIGHAND: %2ld IO: %2ld SYSVSEM: %2ld "
+ "INV: %2ld\n",
pid1, pid2,
sys_kcmp(pid1, pid2, KCMP_FILE, fd1, fd2),
sys_kcmp(pid1, pid2, KCMP_FILES, 0, 0),
_

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/