Re: [PATCH 1/3] Add a new exec_exec_file_name RPC

2014-04-11 Thread Samuel Thibault
Hello, As a reminder, here is the issue: “ $ cat bar #!/bin/sh echo \$0: $0 $ cat foo.c ... char *arg[] = { argv[1], NULL }; execv (*arg, arg); perror (execv); ... $ ./foo ./bar $0: ./bar $ ./foo bar $0: /dev/fd/3 Having /dev/fd/N in $0 instead of the real file name is

[PATCH] include: fix the definition of device_open

2014-04-11 Thread Justus Winter
Previously, every userspace server implementing the device protocol filtered the device definitions to replace the device_t type with mach_port_send_t to make the device argument of device_open polymorphic. Rather than doing that, which makes it impossible to use translation functions, fix the

[PATCH] boot: remove the ourdevice hack

2014-04-11 Thread Justus Winter
Previously, the device definitions were filtered using sed to replace the device_t type with mach_port_send_t to make the device argument of device_open polymorphic. Rather than doing that, which makes it impossible to use translation functions, the definition of device_open has been amended. *

Re: Hurd support in libpcap

2014-04-11 Thread Richard Braun
On Thu, Apr 10, 2014 at 02:01:17AM +0200, Richard Braun wrote: The first issue that can be noticed is that, despite the filter being filled with both NETF_IN and NETF_OUT, only incoming packets seem to be captured. This is probably a minor bug in libbpf but I didn't investigate yet. The issue

Re: GDB: warning: Can't wait for pid ???: No child processes (was: GNU accepted as a mentoring organization in GSOC 2014)

2014-04-11 Thread Zhang Cong
Hi, On Wed, Apr 9, 2014 at 8:57 PM, Yue Lu hacklu.newb...@gmail.com wrote: The reason is that the native _GDB_ doesn't work either on Hurd. So as gdbserver. You can try to attach to a exist process by GDB, you will get that warnning. In detail, there is no distinct difference between the

Hurd port for gcc go PATCH 0-3 (9)

2014-04-11 Thread Svante Signell
Hi, Attached are patches to enable gccgo to build properly on Debian GNU/Hurd on gcc-4.9 (4.9-20140406). With split stack disabled around 70 libgo tests PASS and 50 FAIL (result seems to be somewhat random, alignment problems there too?). With split stack enabled _all_ tests fail, see

Re: GDB: warning: Can't wait for pid ???: No child processes

2014-04-11 Thread Thomas Schwinge
Hi! On Fri, 11 Apr 2014 20:18:19 +0800, Zhang Cong congzh...@mathphoenix.com wrote: On Wed, Apr 9, 2014 at 8:57 PM, Yue Lu hacklu.newb...@gmail.com wrote: So, The question left is why the code was not merge to upstream, And if it can do, many hurder will thank you. The upstream reject

Hurd port for gcc go PATCH 4-6 (9)

2014-04-11 Thread Svante Signell
(continued) patch4.diff: src/libgo/go/syscall/libcall_posix-1.go: New file, a copy of libcall_posix.go with the mount call removed. mount/umount functionality exists but is currently part of Hurd utilities. patch5.diff: src/libgo/go/net/sock_gnu.go Create a dummy function for

Hurd port for gcc go PATCH 7-9 (9)

2014-04-11 Thread Svante Signell
(continued) patch7.diff: src/libgo/go/syscall/wait.c Set WCONTINUED to zero if not defined (same fix as for lto in gcc-4.9) patch8.diff: src/libgo/mksysinfo.sh Add special treatment of EWOULDBLOCK, SYS_FCNTL and st_dev since they are either not defined or defined differently for the script to

Cleaning up dde for the Hurd (was: Hurd support in libpcap)

2014-04-11 Thread Justus Winter
Hi :) Quoting Richard Braun (2014-04-11 11:42:47) On Thu, Apr 10, 2014 at 02:01:17AM +0200, Richard Braun wrote: The first issue that can be noticed is that, despite the filter being filled with both NETF_IN and NETF_OUT, only incoming packets seem to be captured. This is probably a minor

[PATCH 4/6] libmachdev: remove unused function

2014-04-11 Thread Justus Winter
* libmachdev/ds_routines.c (mach_device_reference): Remove unused function. --- libmachdev/ds_routines.c | 6 -- 1 file changed, 6 deletions(-) diff --git a/libmachdev/ds_routines.c b/libmachdev/ds_routines.c index a1fb058..66e5756 100644 --- a/libmachdev/ds_routines.c +++

[PATCH 2/6] eth-multiplexer: fix receiver lookups

2014-04-11 Thread Justus Winter
Previously, the device definitions were filtered using sed to replace the device_t type with mach_port_send_t to make the device argument of device_open polymorphic. Rather than doing that, which makes it impossible to use translation functions, the definition of device_open has been amended. *

[PATCH 1/6] eth-filter: fix receiver lookups

2014-04-11 Thread Justus Winter
Previously, the device definitions were filtered using sed to replace the device_t type with mach_port_send_t to make the device argument of device_open polymorphic. Rather than doing that, which makes it impossible to use translation functions, the definition of device_open has been amended. *

dde cleanups

2014-04-11 Thread Justus Winter
Here are some patches for the dde stuff currently residing in the incubator repo. Justus

[PATCH 6/6] libmachdev: fix function declaration

2014-04-11 Thread Justus Winter
* libmachdev/ds_routines.c: Include mig-generated device_S.h. (ds_device_intr_register): Fix function declaration. --- libmachdev/ds_routines.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libmachdev/ds_routines.c b/libmachdev/ds_routines.c index e415cdb..bbf5488 100644

[PATCH 5/6] libmachdev: fix receiver lookups

2014-04-11 Thread Justus Winter
Previously, the device definitions were filtered using sed to replace the device_t type with mach_port_send_t to make the device argument of device_open polymorphic. Rather than doing that, which makes it impossible to use translation functions, the definition of device_open has been amended. *

[PATCH 3/6] libmachdev: avoid doing pointer arithmetic to get the port_info

2014-04-11 Thread Justus Winter
Previously, mach_convert_port_to_device would return a pointer to struct emul_device, which is embedded in struct mach_device. In order to get to the port_info structure which is right before that, device_to_pi would subtract offsetof (struct mach_device, dev) from the pointer. Avoid that by

Re: Cleaning up dde for the Hurd (was: Hurd support in libpcap)

2014-04-11 Thread Richard Braun
On Fri, Apr 11, 2014 at 03:13:02PM +0200, Justus Winter wrote: This is most likely just an oversight. I started going over the dde code. Zheng Da got lot's of little details wrong. This is not meant to sound harsh, I'm full of respect that he got dde-based drivers up and running during a

Re: Circular dependency with glibc libpthread libihash

2014-04-11 Thread Ludovic Courtès
Manolis Ragkousis manolis...@gmail.com skribis: When libpthread tries to link against libihash.so I get the error: /lib/libihash.so: file not recognized: File format not recognized. This happens because libihash was built using the native compiler. So I changed the flag in libihash

Re: Circular dependency with glibc libpthread libihash

2014-04-11 Thread Manolis Ragkousis
0:00 Ludovic Courtès l...@gnu.org: Could you show what test tries to compile a program? (Send config.log.) Here it is This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. It was created by GNU Hurd configure 0.5, which

Re: Circular dependency with glibc libpthread libihash

2014-04-11 Thread Ludovic Courtès
Manolis Ragkousis manolis...@gmail.com skribis: 0:00 Ludovic Courtès l...@gnu.org: Could you show what test tries to compile a program? (Send config.log.) Here it is Thanks. This file contains any messages produced by compilers while running configure, to aid debugging if configure

Re: problem on shut-down

2014-04-11 Thread Riccardo Mottola
Hi, Justus Winter wrote: appears to be something with my xinted/telnetd! Could you please specify which packages you are using? Debian has three telnetd packages, and I don't seem to be able to locate the xinetd package at all. Justus dpkg-query shows me: ii telnet

Re: Hurd support in libpcap

2014-04-11 Thread Samuel Thibault
Richard Braun, le Fri 11 Apr 2014 11:42:47 +0200, a écrit : On Thu, Apr 10, 2014 at 02:01:17AM +0200, Richard Braun wrote: The first issue that can be noticed is that, despite the filter being filled with both NETF_IN and NETF_OUT, only incoming packets seem to be captured. This is probably

Re: [PATCH 6/6] libmachdev: fix function declaration

2014-04-11 Thread Samuel Thibault
Justus Winter, le Fri 11 Apr 2014 15:34:14 +0200, a écrit : * libmachdev/ds_routines.c: Include mig-generated device_S.h. (ds_device_intr_register): Fix function declaration. Ack. --- libmachdev/ds_routines.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git

Re: [PATCH 1/6] eth-filter: fix receiver lookups

2014-04-11 Thread Samuel Thibault
Justus Winter, le Fri 11 Apr 2014 15:34:09 +0200, a écrit : -DIST_FILES = ourdevice.defs notify.defs +DIST_FILES = device.defs notify.defs Mmm, why keeping device.defs? Shouldn't we be using the one from gnumach? Samuel

Re: [PATCH] include: fix the definition of device_open

2014-04-11 Thread Samuel Thibault
Justus Winter, le Fri 11 Apr 2014 09:32:30 +0200, a écrit : Previously, every userspace server implementing the device protocol filtered the device definitions to replace the device_t type with mach_port_send_t to make the device argument of device_open polymorphic. Rather than doing that,

Re: Hurd port for gcc go PATCH 0-3 (9)

2014-04-11 Thread Samuel Thibault
Svante Signell, le Fri 11 Apr 2014 14:47:21 +0200, a écrit : #ifdef TARGET_LIBC_PROVIDES_SSP +/* i386 glibc provides __stack_chk_guard in %gs:0x14. */ +#define TARGET_THREAD_SSP_OFFSET 0x14 Err, not the Hurd variant, no. Is it really needed? @@ -682,7 +686,7 @@ go_net_cgo_file =

Re: Hurd port for gcc go PATCH 7-9 (9)

2014-04-11 Thread Samuel Thibault
Svante Signell, le Fri 11 Apr 2014 14:57:35 +0200, a écrit : --- a/src/libgo/mksysinfo.sh +++ b/src/libgo/mksysinfo.sh Err, these seem to get applied to all systems, not just GNU/Hurd, isn't that a concern? @@ -210,6 +210,11 @@ egrep '#define E[A-Z0-9_]+ ' | \ sed -e 's/^#define

[PATCH 2/8] devnode: fix argp_program_version, remove argp_program_bug_address

2014-04-11 Thread Justus Winter
* devnode/devnode.c: Fix argp_program_version, remove argp_program_bug_address. --- devnode/devnode.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/devnode/devnode.c b/devnode/devnode.c index 101675d..dbbd40e 100644 --- a/devnode/devnode.c +++ b/devnode/devnode.c @@

[PATCH 1/8] devnode: remove the ourdevice hack

2014-04-11 Thread Justus Winter
Previously, the device definitions were filtered using sed to replace the device_t type with mach_port_send_t to make the device argument of device_open polymorphic. Rather than doing that, which makes it impossible to use translation functions, the definition of device_open has been amended. *

[PATCH 4/8] eth-multiplexer: fix argp_program_version, remove argp_program_bug_address

2014-04-11 Thread Justus Winter
* eth-multiplexer/multiplexer.c: Fix argp_program_version, remove argp_program_bug_address. --- eth-multiplexer/multiplexer.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/eth-multiplexer/multiplexer.c b/eth-multiplexer/multiplexer.c index c36ab78..a133f45 100644 ---

[PATCH 3/8] eth-filter: fix argp_program_version, remove argp_program_bug_address

2014-04-11 Thread Justus Winter
* eth-filter/filter.c: Fix argp_program_version, remove argp_program_bug_address. --- eth-filter/filter.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/eth-filter/filter.c b/eth-filter/filter.c index 8c76c7b..7a25c10 100644 --- a/eth-filter/filter.c +++

[PATCH 7/8] eth-filter: improve the demuxer function

2014-04-11 Thread Justus Winter
Handle multiple request types as recommended by the Mach Server Writer's Guide section 4, subsection Handling Multiple Request Types. This avoids initializing the reply message in every X_server function. The reply message has already been properly initialized in libports, so there is no need to

[PATCH 8/8] eth-multiplexer: improve the demuxer function

2014-04-11 Thread Justus Winter
Handle multiple request types as recommended by the Mach Server Writer's Guide section 4, subsection Handling Multiple Request Types. This avoids initializing the reply message in every X_server function. The reply message has already been properly initialized in libports, so there is no need to

[PATCH 6/8] libmachdev: improve the demuxer functions

2014-04-11 Thread Justus Winter
Handle multiple request types as recommended by the Mach Server Writer's Guide section 4, subsection Handling Multiple Request Types. This avoids initializing the reply message in every X_server function. The reply message has already been properly initialized in libports, so there is no need to

[PATCH 5/8] devnode: improve the demuxer function

2014-04-11 Thread Justus Winter
Handle multiple request types as recommended by the Mach Server Writer's Guide section 4, subsection Handling Multiple Request Types. This avoids initializing the reply message in every X_server function. The reply message has already been properly initialized in libports, so there is no need to

Re: [PATCH] include: fix the definition of device_open

2014-04-11 Thread Justus Winter
Quoting Samuel Thibault (2014-04-11 22:27:09) Justus Winter, le Fri 11 Apr 2014 09:32:30 +0200, a écrit : Previously, every userspace server implementing the device protocol filtered the device definitions to replace the device_t type with mach_port_send_t to make the device argument of

Re: [PATCH 4/8] eth-multiplexer: fix argp_program_version, remove argp_program_bug_address

2014-04-11 Thread Samuel Thibault
Justus Winter, le Fri 11 Apr 2014 23:09:54 +0200, a écrit : * eth-multiplexer/multiplexer.c: Fix argp_program_version, remove argp_program_bug_address. Ack. --- eth-multiplexer/multiplexer.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git

Re: [PATCH 3/8] eth-filter: fix argp_program_version, remove argp_program_bug_address

2014-04-11 Thread Samuel Thibault
Justus Winter, le Fri 11 Apr 2014 23:09:53 +0200, a écrit : * eth-filter/filter.c: Fix argp_program_version, remove argp_program_bug_address. Ack. --- eth-filter/filter.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/eth-filter/filter.c b/eth-filter/filter.c

Re: [PATCH 5/8] devnode: improve the demuxer function

2014-04-11 Thread Samuel Thibault
Justus Winter, le Fri 11 Apr 2014 23:09:55 +0200, a écrit : Handle multiple request types as recommended by the Mach Server Writer's Guide section 4, subsection Handling Multiple Request Types. This avoids initializing the reply message in every X_server function. The reply message has

Re: [PATCH 6/8] libmachdev: improve the demuxer functions

2014-04-11 Thread Samuel Thibault
Justus Winter, le Fri 11 Apr 2014 23:09:56 +0200, a écrit : Handle multiple request types as recommended by the Mach Server Writer's Guide section 4, subsection Handling Multiple Request Types. This avoids initializing the reply message in every X_server function. The reply message has

Re: [PATCH 8/8] eth-multiplexer: improve the demuxer function

2014-04-11 Thread Samuel Thibault
Justus Winter, le Fri 11 Apr 2014 23:09:58 +0200, a écrit : Handle multiple request types as recommended by the Mach Server Writer's Guide section 4, subsection Handling Multiple Request Types. This avoids initializing the reply message in every X_server function. The reply message has

Re: [PATCH 7/8] eth-filter: improve the demuxer function

2014-04-11 Thread Samuel Thibault
Justus Winter, le Fri 11 Apr 2014 23:09:57 +0200, a écrit : Handle multiple request types as recommended by the Mach Server Writer's Guide section 4, subsection Handling Multiple Request Types. This avoids initializing the reply message in every X_server function. The reply message has

Re: GCC's -fsplit-stack disturbing Mach's vm_allocate

2014-04-11 Thread Samuel Thibault
Thomas Schwinge, le Wed 09 Apr 2014 09:36:42 +0200, a écrit : Well, the first step is to verify that TARGET_THREAD_SPLIT_STACK_OFFSET and similar configury is correct for the Hurd, It's not. I've checked what TARGET_THREAD_SPLIT_STACK_OFFSET is, it's an offset inside the tcbhead_t structure,