Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1217464 > unrolled thread
| Started by | Geert Uytterhoeven <geert@linux-m68k.org> |
|---|---|
| First post | 2015-09-02 11:50 +0200 |
| Last post | 2015-09-03 12:10 +0200 |
| Articles | 3 — 3 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: [PATCH] x86: Wire up 32-bit direct socket calls Geert Uytterhoeven <geert@linux-m68k.org> - 2015-09-02 11:50 +0200
Re: [PATCH] x86: Wire up 32-bit direct socket calls "H. Peter Anvin" <hpa@zytor.com> - 2015-09-02 22:20 +0200
RE: [PATCH] x86: Wire up 32-bit direct socket calls David Laight <David.Laight@ACULAB.COM> - 2015-09-03 12:10 +0200
| From | Geert Uytterhoeven <geert@linux-m68k.org> |
|---|---|
| Date | 2015-09-02 11:50 +0200 |
| Subject | Re: [PATCH] x86: Wire up 32-bit direct socket calls |
| Message-ID | <q4cQ2-1iy-25@gated-at.bofh.it> |
On Wed, Jul 15, 2015 at 12:24 AM, Andy Lutomirski <luto@kernel.org> wrote:
> On x86_64, there's no socketcall syscall; instead all of the socket
> calls are real syscalls. For 32-bit programs, we're stuck offering
> the socketcall syscall, but it would be nice to expose the direct
> calls as well. This will enable seccomp to filter socket calls (for
> new userspace only, but that's fine for some applications) and it
> will provide a tiny performance boost.
>
> Signed-off-by: Andy Lutomirski <luto@kernel.org>
> ---
> arch/x86/entry/syscalls/syscall_32.tbl | 15 +++++++++++++++
> 1 file changed, 15 insertions(+)
>
> diff --git a/arch/x86/entry/syscalls/syscall_32.tbl b/arch/x86/entry/syscalls/syscall_32.tbl
> index ef8187f9d28d..25e3cf1cd8fd 100644
> --- a/arch/x86/entry/syscalls/syscall_32.tbl
> +++ b/arch/x86/entry/syscalls/syscall_32.tbl
> @@ -365,3 +365,18 @@
> 356 i386 memfd_create sys_memfd_create
> 357 i386 bpf sys_bpf
> 358 i386 execveat sys_execveat stub32_execveat
> +359 i386 socket sys_socket
> +360 i386 socketpair sys_socketpair
> +361 i386 bind sys_bind
> +362 i386 connect sys_connect
> +363 i386 listen sys_listen
> +364 i386 accept4 sys_accept4
> +365 i386 getsockopt sys_getsockopt compat_sys_getsockopt
> +366 i386 setsockopt sys_setsockopt compat_sys_setsockopt
> +367 i386 getsockname sys_getsockname
> +368 i386 getpeername sys_getpeername
> +369 i386 sendto sys_sendto
> +370 i386 sendmsg sys_sendmsg compat_sys_sendmsg
> +371 i386 recvfrom sys_recvfrom compat_sys_recvfrom
> +372 i386 recvmsg sys_recvmsg compat_sys_recvmsg
> +373 i386 shutdown sys_shutdown
Should all other architectures follow suit?
Or should we follow the s390 approach:
commit 5a7ff75a0c63222d138d944240146dc49a9624e1
Author: Heiko Carstens <heiko.carstens@de.ibm.com>
Date: Tue Aug 4 09:15:58 2015 +0200
s390/syscalls: ignore syscalls reachable via sys_socketcall
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [next] | [standalone]
| From | "H. Peter Anvin" <hpa@zytor.com> |
|---|---|
| Date | 2015-09-02 22:20 +0200 |
| Message-ID | <q4mFH-773-15@gated-at.bofh.it> |
| In reply to | #1217464 |
On 09/02/2015 02:48 AM, Geert Uytterhoeven wrote: > > Should all other architectures follow suit? > Or should we follow the s390 approach: > It is up to the maintainer(s), largely dependent on how likely you are going to want to support this in your libc, but in general, socketcall is an abomination which there is no reason not to bypass. So follow suit unless you have a strong reason not to. -hpa -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [next] | [standalone]
| From | David Laight <David.Laight@ACULAB.COM> |
|---|---|
| Date | 2015-09-03 12:10 +0200 |
| Message-ID | <q4zCW-r9-31@gated-at.bofh.it> |
| In reply to | #1217837 |
RnJvbTogUGV0ZXIgQW52aW4NCj4gU2VudDogMDIgU2VwdGVtYmVyIDIwMTUgMjE6MTYNCj4gT24g MDkvMDIvMjAxNSAwMjo0OCBBTSwgR2VlcnQgVXl0dGVyaG9ldmVuIHdyb3RlOg0KPiA+DQo+ID4g U2hvdWxkIGFsbCBvdGhlciBhcmNoaXRlY3R1cmVzIGZvbGxvdyBzdWl0Pw0KPiA+IE9yIHNob3Vs ZCB3ZSBmb2xsb3cgdGhlIHMzOTAgYXBwcm9hY2g6DQo+ID4NCj4gDQo+IEl0IGlzIHVwIHRvIHRo ZSBtYWludGFpbmVyKHMpLCBsYXJnZWx5IGRlcGVuZGVudCBvbiBob3cgbGlrZWx5IHlvdSBhcmUN Cj4gZ29pbmcgdG8gd2FudCB0byBzdXBwb3J0IHRoaXMgaW4geW91ciBsaWJjLCBidXQgaW4gZ2Vu ZXJhbCwgc29ja2V0Y2FsbA0KPiBpcyBhbiBhYm9taW5hdGlvbiB3aGljaCB0aGVyZSBpcyBubyBy ZWFzb24gbm90IHRvIGJ5cGFzcy4NCg0KVGhlIG90aGVyICh3b3JzZSkgYWJvbWluYXRpb24gaXMg dGhlIHdheSBTQ1RQIG92ZXJsb2FkcyBzZXRzb2Nrb3B0KCkNCnRvIHBlcmZvcm0gYWN0aW9ucyB0 aGF0IGNoYW5nZSBzdGF0ZS4NClJhdGhlciB1bmZvcnR1bmF0ZWx5IHRoYXQgZ290IGRvY3VtZW50 ZWQgaW4gdGhlIHByb3RvY29sIHN0YW5kYXJkIDotKA0KDQoJRGF2aWQNCg0K -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web