Re: [PATCH 5/5] trans/fakeroot: remove dead code

2013-12-10 Thread Samuel Thibault
Justus Winter, le Tue 10 Dec 2013 17:50:30 +0100, a écrit : > * trans/fakeroot.c (netfs_S_dir_lookup): Remove dead code. Ack. > --- > trans/fakeroot.c |6 ++ > 1 file changed, 2 insertions(+), 4 deletions(-) > > diff --git a/trans/fakeroot.c b/trans/fakeroot.c > index 58f1112..203f2c1 1

Re: [PATCH 4/5] trans/fakeroot: remove dead code

2013-12-10 Thread Samuel Thibault
Justus Winter, le Tue 10 Dec 2013 17:50:29 +0100, a écrit : > * trans/fakeroot.c (netfs_S_dir_lookup): Remove dead code. Ack. > --- > trans/fakeroot.c | 67 > +++--- > 1 file changed, 29 insertions(+), 38 deletions(-) > > diff --git a/trans/fak

Re: [PATCH] utils/settrans: fix the teardown of chrooted environments

2013-12-10 Thread Samuel Thibault
Justus Winter, le Tue 10 Dec 2013 18:08:13 +0100, a écrit : > Previously, settrans --chroot would just exec the target. Create a > new process for that purpose. Wait for its completion, then ask the > translator (nicely by default) to go away. If it refuses with EBUSY, > it might be because some

Re: [PATCH 3/5] trans/fakeroot: drop else

2013-12-10 Thread Samuel Thibault
Justus Winter, le Tue 10 Dec 2013 17:50:28 +0100, a écrit : > * trans/fakeroot.c (netfs_S_dir_lookup): Drop else. Ack. > --- > trans/fakeroot.c | 76 > ++ > 1 file changed, 37 insertions(+), 39 deletions(-) > > diff --git a/trans/fakeroot.c

Re: [PATCH 2/5] trans/fakeroot: fix ownership of newly created files

2013-12-10 Thread Samuel Thibault
Justus Winter, le Tue 10 Dec 2013 17:50:27 +0100, a écrit : > Previously, files created in the fakeroot environment were created > with the uid and gid of the user running fakeroot: > > % fakeroot-hurd /bin/sh -c 'touch /tmp/$$; stat --format=%u:%g /tmp/$$' > 1000:1000 > > * trans/fakeroot.c (net

Re: [PATCH 1/5] utils/settrans: fix the teardown of chrooted environments

2013-12-10 Thread Samuel Thibault
Justus Winter, le Tue 10 Dec 2013 17:50:26 +0100, a écrit : > Previously, settrans --chroot would just exec the target. Create a > new process for that purpose. Wait for its completion, then ask the > translator (nicely by default) to go away. If it refuses with EBUSY, > it might be because some

Re: [PATCH 07/13] trans: return nodes locked when creating fake nodes in fakeroot

2013-12-10 Thread Samuel Thibault
Justus Winter, le Tue 10 Dec 2013 10:20:45 +0100, a écrit : > Quoting Samuel Thibault (2013-12-10 01:08:21) > > Justus Winter, le Mon 09 Dec 2013 15:16:35 +0100, a écrit : > > > + { > > > + pthread_mutex_lock (&(*np)->lock); > > > + netfs_nref (*np); /* Return a reference to the

Re: [PATCH 04/08] i386/i386/ldt.c: remove forward declaration

2013-12-10 Thread Samuel Thibault
Marin Ramesa, le Tue 10 Dec 2013 19:19:59 +0100, a écrit : > --- a/i386/i386/ldt.h > +++ b/i386/i386/ldt.h > @@ -63,6 +63,8 @@ extern struct real_descriptor ldt[LDTSZ]; > > void ldt_init(void); > > +extern int syscall(void); I'd rather see the locore.S functions put in a separate headers. Sa

[PATCH 3/3] ipc/mach_debug.c (mach_port_kernel_object): remove unnecessary cast

2013-12-10 Thread Marin Ramesa
Member ip_kobject is of type vm_offset_t. * ipc/mach_debug.c (mach_port_kernel_object) (ip_kobject): Remove unnecessary cast. --- ipc/mach_debug.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ipc/mach_debug.c b/ipc/mach_debug.c index 7c3c129..764e95d 100644 --- a/ipc/mach

[PATCH 1/3] Cleanup of the memcpy(), memmove(), memcmp() and memset() calls

2013-12-10 Thread Marin Ramesa
Addresses were cast to (void *). Pointers uncasted. * device/ds_routines.c (ds_read_done) (memset) (start_sent): Cast to (void *) instead to (char *). Argument is an address. (ds_read_done) (memset) (end_data): Likewise. * i386/i386/pcb.c (thread_getstatus) (memcpy) (pm): Don't cast. Argument is

[PATCH 2/3] ipc/mach_debug.c (mach_port_kernel_object): remove unnecessary cast

2013-12-10 Thread Marin Ramesa
Return value from ip_kotype is an unsigned int. * ipc/mach_debug.c (mach_port_kernel_object) (ip_kotype): Remove unnecessary cast. --- ipc/mach_debug.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ipc/mach_debug.c b/ipc/mach_debug.c index 5c93cfd..7c3c129 100644 --- a/ipc

[PATCH 08/08] i386/i386at/kd_mouse.c (kd_mouse_open): remove forward declaration

2013-12-10 Thread Marin Ramesa
* i386/i386at/kd_mouse.c (kd_mouse_open) (kdintr): Remove forward declaration. --- i386/i386at/kd_mouse.c | 1 - 1 file changed, 1 deletion(-) diff --git a/i386/i386at/kd_mouse.c b/i386/i386at/kd_mouse.c index 5a80474..9aa4b81 100644 --- a/i386/i386at/kd_mouse.c +++ b/i386/i386at/kd_mouse.c @@ -

[PATCH 03/08] i386/i386/db_trace.c (db_i386_stack_trace): remove unnecessary cast

2013-12-10 Thread Marin Ramesa
Argument to INKERNEL() is already cast to vm_offset_t in the macro itself. * i386/i386/db_trace.c (db_i386_stack_trace) (INKERNEL) (callpc): Don't cast to unsigned long. (db_i386_stack_trace) (INKERNEL) (frame): Likewise. --- i386/i386/db_trace.c | 8 1 file changed, 4 insertions(+), 4

[PATCH 07/08] i386/i386at/kd.c (kdinit): remove forward declaration

2013-12-10 Thread Marin Ramesa
* i386/i386at/kd.c (kdinit) (kd_xga_init): Remove forward declaration. * i386/i386at/kd.h (kd_xga_init): Add prototype. --- i386/i386at/kd.c | 1 - i386/i386at/kd.h | 2 ++ 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/i386/i386at/kd.c b/i386/i386at/kd.c index 5f3655b..bf2ad0a 100

[PATCH 06/08] i386/i386at/kd.c (kdmmap): remove unnecessary cast

2013-12-10 Thread Marin Ramesa
Variable off is already an unsigned int. * i386/i386at/kd.c (kdmmap) (off): Remove unnecessary cast. --- i386/i386at/kd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/i386/i386at/kd.c b/i386/i386at/kd.c index 064fd22..5f3655b 100644 --- a/i386/i386at/kd.c +++ b/i386/i386at

[PATCH 04/08] i386/i386/ldt.c: remove forward declaration

2013-12-10 Thread Marin Ramesa
* i386/i386/ldt.c (syscall): Remove forward declaration. * i386/i386/ldt.h (syscall): Add prototype. --- i386/i386/ldt.c | 2 -- i386/i386/ldt.h | 2 ++ 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/i386/i386/ldt.c b/i386/i386/ldt.c index 43b9efb..069b496 100644 --- a/i386/i386/

[PATCH 02/08] i386/i386/db_trace.c: remove forward declaration

2013-12-10 Thread Marin Ramesa
* i386/Makefrag.am: List i386/i386/db_trace.h. * i386/i386/db_trace.c: Include machine/db_trace.h. (db_i386_stack_trace): Remove forward declaration. * i386/i386/db_trace.h: New file. Add copyright. [_I386_DB_TRACE_H_]: Add ifndef. (i386_frame): Declare forward. (db_i386_stack_trace): Add prototype

[PATCH 05/08] i386/i386at/kd.c: remove forward declarations

2013-12-10 Thread Marin Ramesa
* i386/i386at/kd.c (kd_getdata, state2leds, kdstart, kdstop): Remove forward declarations. * i386/i386at/kd.h (kd_getdata, state2leds, kdstart, kdstop): Add prototypes. Include device/tty.h. --- i386/i386at/kd.c | 6 -- i386/i386at/kd.h | 7 +++ 2 files changed, 7 insertions(+), 6 deleti

[PATCH 01/08] i386/i386at/kd.c (kdintr): quiet the GCC warning about signed overflow

2013-12-10 Thread Marin Ramesa
WIDTH_KMAP is the number of columns in the key_map table. Check if char_idx is less than WIDTH_KMAP and break the for loop if that is not the case. i386/i386at/kd.c (kdintr): Break the for loop if char_idx is larger or equal to WIDTH_KMAP. --- i386/i386at/kd.c | 2 +- 1 file changed, 1 insertio

updated 1st patch

2013-12-10 Thread Justus Winter
err, rather this one, which honors goaway_flags. Justus

[PATCH] utils/settrans: fix the teardown of chrooted environments

2013-12-10 Thread Justus Winter
Previously, settrans --chroot would just exec the target. Create a new process for that purpose. Wait for its completion, then ask the translator (nicely by default) to go away. If it refuses with EBUSY, it might be because some process has daemonized inside the chrooted environment. This fixes

[PATCH 5/5] trans/fakeroot: remove dead code

2013-12-10 Thread Justus Winter
* trans/fakeroot.c (netfs_S_dir_lookup): Remove dead code. --- trans/fakeroot.c |6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/trans/fakeroot.c b/trans/fakeroot.c index 58f1112..203f2c1 100644 --- a/trans/fakeroot.c +++ b/trans/fakeroot.c @@ -371,10 +371,8 @@ netfs_S_

[PATCH 4/5] trans/fakeroot: remove dead code

2013-12-10 Thread Justus Winter
* trans/fakeroot.c (netfs_S_dir_lookup): Remove dead code. --- trans/fakeroot.c | 67 +++--- 1 file changed, 29 insertions(+), 38 deletions(-) diff --git a/trans/fakeroot.c b/trans/fakeroot.c index f278db1..58f1112 100644 --- a/trans/fakeroot.c ++

[PATCH 3/5] trans/fakeroot: drop else

2013-12-10 Thread Justus Winter
* trans/fakeroot.c (netfs_S_dir_lookup): Drop else. --- trans/fakeroot.c | 76 ++ 1 file changed, 37 insertions(+), 39 deletions(-) diff --git a/trans/fakeroot.c b/trans/fakeroot.c index 6882618..f278db1 100644 --- a/trans/fakeroot.c +++ b/tra

[PATCH 2/5] trans/fakeroot: fix ownership of newly created files

2013-12-10 Thread Justus Winter
Previously, files created in the fakeroot environment were created with the uid and gid of the user running fakeroot: % fakeroot-hurd /bin/sh -c 'touch /tmp/$$; stat --format=%u:%g /tmp/$$' 1000:1000 * trans/fakeroot.c (netfs_S_dir_lookup): Fix ownership of newly created files. --- trans/fakeroo

[PATCH 1/5] utils/settrans: fix the teardown of chrooted environments

2013-12-10 Thread Justus Winter
Previously, settrans --chroot would just exec the target. Create a new process for that purpose. Wait for its completion, then ask the translator (nicely by default) to go away. If it refuses with EBUSY, it might be because some process has daemonized inside the chrooted environment. This fixes

Re: [PATCH 13/13] console-client: remove spurious pthread_spin_unlocks

2013-12-10 Thread Samuel Thibault
Justus Winter, le Tue 10 Dec 2013 11:06:22 +0100, a écrit : > Quoting Samuel Thibault (2013-12-10 01:17:02) > > Justus Winter, le Mon 09 Dec 2013 15:16:41 +0100, a écrit : > > > * console-client/trans.c (netfs_attempt_mkfile): Remove spurious > > > pthread_spin_unlock. > > > (netfs_node_norefs):

Re: [PATCH 13/13] console-client: remove spurious pthread_spin_unlocks

2013-12-10 Thread Justus Winter
Quoting Samuel Thibault (2013-12-10 01:17:02) > Justus Winter, le Mon 09 Dec 2013 15:16:41 +0100, a écrit : > > * console-client/trans.c (netfs_attempt_mkfile): Remove spurious > > pthread_spin_unlock. > > (netfs_node_norefs): Likewise. > > It seems completely spurious indeed. I've since built

Re: [PATCH 07/13] trans: return nodes locked when creating fake nodes in fakeroot

2013-12-10 Thread Justus Winter
Quoting Samuel Thibault (2013-12-10 01:08:21) > Justus Winter, le Mon 09 Dec 2013 15:16:35 +0100, a écrit : > > + { > > + pthread_mutex_lock (&(*np)->lock); > > + netfs_nref (*np); /* Return a reference to the caller. */ > > + } > >pthread_mutex_unlock (&idport_ihas