* [PATCH] x86: use compat version for preadv2 and pwritev2
@ 2016-05-11 8:48 Dmitry V. Levin
2016-05-11 10:14 ` Thomas Gleixner
` (2 more replies)
0 siblings, 3 replies; 8+ messages in thread
From: Dmitry V. Levin @ 2016-05-11 8:48 UTC (permalink / raw)
To: Thomas Gleixner, Ingo Molnar, H. Peter Anvin, x86
Cc: Christoph Hellwig, linux-kernel
Similar to preadv and pwritev, preadv2 and pwritev2 need compat entries
in the 32-bit syscall table.
This bug was found by strace test suite.
Fixes: 4babf2c5efb7 ("x86: wire up preadv2 and pwritev2")
Signed-off-by: Dmitry V. Levin <ldv@altlinux.org>
---
arch/x86/entry/syscalls/syscall_32.tbl | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/x86/entry/syscalls/syscall_32.tbl b/arch/x86/entry/syscalls/syscall_32.tbl
index b30dd81..4cddd17 100644
--- a/arch/x86/entry/syscalls/syscall_32.tbl
+++ b/arch/x86/entry/syscalls/syscall_32.tbl
@@ -384,5 +384,5 @@
375 i386 membarrier sys_membarrier
376 i386 mlock2 sys_mlock2
377 i386 copy_file_range sys_copy_file_range
-378 i386 preadv2 sys_preadv2
-379 i386 pwritev2 sys_pwritev2
+378 i386 preadv2 sys_preadv2 compat_sys_preadv2
+379 i386 pwritev2 sys_pwritev2 compat_sys_pwritev2
--
ldv
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH] x86: use compat version for preadv2 and pwritev2
2016-05-11 8:48 [PATCH] x86: use compat version for preadv2 and pwritev2 Dmitry V. Levin
@ 2016-05-11 10:14 ` Thomas Gleixner
2016-05-11 10:25 ` Dmitry V. Levin
2016-05-12 7:31 ` Christoph Hellwig
2016-05-12 7:30 ` Christoph Hellwig
2016-05-12 12:33 ` [tip:x86/urgent] x86: Use " tip-bot for Dmitry V. Levin
2 siblings, 2 replies; 8+ messages in thread
From: Thomas Gleixner @ 2016-05-11 10:14 UTC (permalink / raw)
To: Dmitry V. Levin
Cc: Ingo Molnar, H. Peter Anvin, x86, Christoph Hellwig, LKML,
Milosz Tanski, Al Viro
On Wed, 11 May 2016, Dmitry V. Levin wrote:
> Similar to preadv and pwritev, preadv2 and pwritev2 need compat entries
> in the 32-bit syscall table.
So this is 2016 and we added a syscalls which require compat support. What's
wrong here?
Thanks,
tglx
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] x86: use compat version for preadv2 and pwritev2
2016-05-11 10:14 ` Thomas Gleixner
@ 2016-05-11 10:25 ` Dmitry V. Levin
2016-05-11 11:01 ` Thomas Gleixner
2016-05-12 7:31 ` Christoph Hellwig
1 sibling, 1 reply; 8+ messages in thread
From: Dmitry V. Levin @ 2016-05-11 10:25 UTC (permalink / raw)
To: Thomas Gleixner
Cc: Ingo Molnar, H. Peter Anvin, x86, Christoph Hellwig, LKML,
Milosz Tanski, Al Viro
On Wed, May 11, 2016 at 12:14:11PM +0200, Thomas Gleixner wrote:
> On Wed, 11 May 2016, Dmitry V. Levin wrote:
> > Similar to preadv and pwritev, preadv2 and pwritev2 need compat entries
> > in the 32-bit syscall table.
>
> So this is 2016 and we added a syscalls which require compat support. What's
> wrong here?
I'm not sure I understand your question, it looks to me as "why do we add
syscalls that require compat support". If that's what you are asking,
I have no idea, I'm a strace man.
--
ldv
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] x86: use compat version for preadv2 and pwritev2
2016-05-11 10:25 ` Dmitry V. Levin
@ 2016-05-11 11:01 ` Thomas Gleixner
0 siblings, 0 replies; 8+ messages in thread
From: Thomas Gleixner @ 2016-05-11 11:01 UTC (permalink / raw)
To: Dmitry V. Levin
Cc: Ingo Molnar, H. Peter Anvin, x86, Christoph Hellwig, LKML,
Milosz Tanski, Al Viro
On Wed, 11 May 2016, Dmitry V. Levin wrote:
> On Wed, May 11, 2016 at 12:14:11PM +0200, Thomas Gleixner wrote:
> > On Wed, 11 May 2016, Dmitry V. Levin wrote:
> > > Similar to preadv and pwritev, preadv2 and pwritev2 need compat entries
> > > in the 32-bit syscall table.
> >
> > So this is 2016 and we added a syscalls which require compat support. What's
> > wrong here?
>
> I'm not sure I understand your question, it looks to me as "why do we add
> syscalls that require compat support". If that's what you are asking,
Yes, that question was directed at the people who added this in the first
place.
> I have no idea, I'm a strace man.
I know, you are just the messenger :)
Thanks,
tglx
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] x86: use compat version for preadv2 and pwritev2
2016-05-11 8:48 [PATCH] x86: use compat version for preadv2 and pwritev2 Dmitry V. Levin
2016-05-11 10:14 ` Thomas Gleixner
@ 2016-05-12 7:30 ` Christoph Hellwig
2016-05-12 10:55 ` Dmitry V. Levin
2016-05-12 12:33 ` [tip:x86/urgent] x86: Use " tip-bot for Dmitry V. Levin
2 siblings, 1 reply; 8+ messages in thread
From: Christoph Hellwig @ 2016-05-12 7:30 UTC (permalink / raw)
To: Dmitry V. Levin
Cc: Thomas Gleixner, Ingo Molnar, H. Peter Anvin, x86,
Christoph Hellwig, linux-kernel
On Wed, May 11, 2016 at 11:48:17AM +0300, Dmitry V. Levin wrote:
> Similar to preadv and pwritev, preadv2 and pwritev2 need compat entries
> in the 32-bit syscall table.
>
> This bug was found by strace test suite.
Looks fine, thanks.
Btw, can we have a sensible format for the syscalls list that explicitly
requires adding _something_ for the compat entry so that errors by
ommision like this can't happen?
Reviewed-by: Christoph Hellwig <hch@lst.de>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] x86: use compat version for preadv2 and pwritev2
2016-05-11 10:14 ` Thomas Gleixner
2016-05-11 10:25 ` Dmitry V. Levin
@ 2016-05-12 7:31 ` Christoph Hellwig
1 sibling, 0 replies; 8+ messages in thread
From: Christoph Hellwig @ 2016-05-12 7:31 UTC (permalink / raw)
To: Thomas Gleixner
Cc: Dmitry V. Levin, Ingo Molnar, H. Peter Anvin, x86,
Christoph Hellwig, LKML, Milosz Tanski, Al Viro
On Wed, May 11, 2016 at 12:14:11PM +0200, Thomas Gleixner wrote:
> On Wed, 11 May 2016, Dmitry V. Levin wrote:
> > Similar to preadv and pwritev, preadv2 and pwritev2 need compat entries
> > in the 32-bit syscall table.
>
> So this is 2016 and we added a syscalls which require compat support. What's
> wrong here?
Nothing. It's and extension of readv/writev and uses struct iovec,
which is different for compat vs native. We have efficient infrastructure
to deal with that in the kernel, while in userspace people would have
to copy around all the iovecs for every I/O, which would be a nightmare.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] x86: use compat version for preadv2 and pwritev2
2016-05-12 7:30 ` Christoph Hellwig
@ 2016-05-12 10:55 ` Dmitry V. Levin
0 siblings, 0 replies; 8+ messages in thread
From: Dmitry V. Levin @ 2016-05-12 10:55 UTC (permalink / raw)
To: Christoph Hellwig
Cc: Thomas Gleixner, Ingo Molnar, H. Peter Anvin, x86, linux-kernel
On Thu, May 12, 2016 at 09:30:37AM +0200, Christoph Hellwig wrote:
> On Wed, May 11, 2016 at 11:48:17AM +0300, Dmitry V. Levin wrote:
> > Similar to preadv and pwritev, preadv2 and pwritev2 need compat entries
> > in the 32-bit syscall table.
> >
> > This bug was found by strace test suite.
>
> Looks fine, thanks.
BTW, x32 hasn't got entries for preadv2/pwritev2 at all.
Not a problem, just a reminder.
--
ldv
^ permalink raw reply [flat|nested] 8+ messages in thread
* [tip:x86/urgent] x86: Use compat version for preadv2 and pwritev2
2016-05-11 8:48 [PATCH] x86: use compat version for preadv2 and pwritev2 Dmitry V. Levin
2016-05-11 10:14 ` Thomas Gleixner
2016-05-12 7:30 ` Christoph Hellwig
@ 2016-05-12 12:33 ` tip-bot for Dmitry V. Levin
2 siblings, 0 replies; 8+ messages in thread
From: tip-bot for Dmitry V. Levin @ 2016-05-12 12:33 UTC (permalink / raw)
To: linux-tip-commits; +Cc: tglx, ldv, linux-kernel, mingo, hpa, hch
Commit-ID: 9a7a076e8e4ffcfec05e3cafe4c4e31d41ddbaa0
Gitweb: http://git.kernel.org/tip/9a7a076e8e4ffcfec05e3cafe4c4e31d41ddbaa0
Author: Dmitry V. Levin <ldv@altlinux.org>
AuthorDate: Wed, 11 May 2016 11:48:17 +0300
Committer: Thomas Gleixner <tglx@linutronix.de>
CommitDate: Thu, 12 May 2016 14:27:13 +0200
x86: Use compat version for preadv2 and pwritev2
Similar to preadv and pwritev, preadv2 and pwritev2 need compat entries
in the 32-bit syscall table.
This bug was found by strace test suite.
Fixes: 4babf2c5efb7 ("x86: wire up preadv2 and pwritev2")
Signed-off-by: Dmitry V. Levin <ldv@altlinux.org>
Acked-by: Christoph Hellwig <hch@lst.de>
Link: http://lkml.kernel.org/r/20160511084817.GA29823@altlinux.org
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
---
arch/x86/entry/syscalls/syscall_32.tbl | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/x86/entry/syscalls/syscall_32.tbl b/arch/x86/entry/syscalls/syscall_32.tbl
index b30dd81..4cddd17 100644
--- a/arch/x86/entry/syscalls/syscall_32.tbl
+++ b/arch/x86/entry/syscalls/syscall_32.tbl
@@ -384,5 +384,5 @@
375 i386 membarrier sys_membarrier
376 i386 mlock2 sys_mlock2
377 i386 copy_file_range sys_copy_file_range
-378 i386 preadv2 sys_preadv2
-379 i386 pwritev2 sys_pwritev2
+378 i386 preadv2 sys_preadv2 compat_sys_preadv2
+379 i386 pwritev2 sys_pwritev2 compat_sys_pwritev2
^ permalink raw reply related [flat|nested] 8+ messages in thread
end of thread, other threads:[~2016-05-12 12:34 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-05-11 8:48 [PATCH] x86: use compat version for preadv2 and pwritev2 Dmitry V. Levin
2016-05-11 10:14 ` Thomas Gleixner
2016-05-11 10:25 ` Dmitry V. Levin
2016-05-11 11:01 ` Thomas Gleixner
2016-05-12 7:31 ` Christoph Hellwig
2016-05-12 7:30 ` Christoph Hellwig
2016-05-12 10:55 ` Dmitry V. Levin
2016-05-12 12:33 ` [tip:x86/urgent] x86: Use " tip-bot for Dmitry V. Levin
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.