[PATCH glibc] Fix hurd i686 build breakage caused by 4fedebc9110809b5965e42f659d3477f4c89def8

2023-02-16 Thread Flavio Cruz
We already use the mach/machine include pattern in some other places so seems fine to make it consistent here too. --- sysdeps/mach/hurd/i386/htl/pt-machdep.c | 4 ++-- sysdeps/mach/hurd/i386/tls.h| 2 +- sysdeps/mach/hurd/x86/ioperm.c | 2 +- 3 files changed, 4 insertions(+),

Re: checking whether mig supports the retcode keyword... no

2023-02-16 Thread Flávio Cruz
On Thu, Feb 16, 2023 at 4:19 AM Sergey Bugaev wrote: > On Thu, Feb 16, 2023 at 10:27 AM Flávio Cruz wrote: > >> On that note: right now, MIG-generated stubs are broken on x86_64. MIG > >> built from master complains about time_value_t (which GCC says is 16 > >> bytes-, but MIG expects to be 12 b

[PATCH mig] Also align mach_msg_type_long_t to complex_alignof

2023-02-16 Thread Flavio Cruz
This was a miss in the previous patch given that mach_msg_type_long_t is 12 bytes long so won't neatly align to 8 bytes. --- utils.c | 12 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/utils.c b/utils.c index f2f45f6..9af78e9 100644 --- a/utils.c +++ b/utils.c @@ -304,

Re: [PATCH 4/4] x86_64: set user segments as 64-bit if ! USER32

2023-02-16 Thread Samuel Thibault
Applied, thanks! Luca Dariz, le jeu. 16 févr. 2023 22:33:18 +0100, a ecrit: > * i386/i386/ldt.c: set the L bit if user-space is 64-bit > --- > i386/i386/ldt.c | 10 -- > 1 file changed, 8 insertions(+), 2 deletions(-) > > diff --git a/i386/i386/ldt.c b/i386/i386/ldt.c > index 70fa24e2..b

Re: [PATCH 3/4] x86_64: fix argument passing to bootstrap modules if ! USER32

2023-02-16 Thread Samuel Thibault
Applied, thanks! Luca Dariz, le jeu. 16 févr. 2023 22:33:17 +0100, a ecrit: > * kern/bootstrap.c: replace integers with long/vm_offset_t > --- > kern/bootstrap.c | 10 +- > 1 file changed, 5 insertions(+), 5 deletions(-) > > diff --git a/kern/bootstrap.c b/kern/bootstrap.c > index 91f424

Re: [PATCH 2/4] x86_64: load Elf64 bootstrap modules if ! USER32

2023-02-16 Thread Samuel Thibault
Applied, thanks! Luca Dariz, le jeu. 16 févr. 2023 22:33:16 +0100, a ecrit: > * i386/include/mach/i386/exec/elf.h: add Elf64 definitions and define > common Elf structures, corresponding to 32/64 bit variants at > compile time. > * include/mach/exec/elf.h: add Elf64 definitions > * kern/elf-lo

Re: [PATCH 1/4] x86_64: fix some compiler warnings

2023-02-16 Thread Samuel Thibault
Applied, thanks! Luca Dariz, le jeu. 16 févr. 2023 22:33:15 +0100, a ecrit: > * i386/include/mach/i386/vm_param.h: extend the vm constants to ULL on > x86_64 to avoid a shift overflow warning > * i386/intel/pmap.c: fix cast and unused variables > --- > i386/include/mach/i386/vm_param.h | 4 ++--

[PATCH 4/4] x86_64: set user segments as 64-bit if ! USER32

2023-02-16 Thread Luca Dariz
* i386/i386/ldt.c: set the L bit if user-space is 64-bit --- i386/i386/ldt.c | 10 -- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/i386/i386/ldt.c b/i386/i386/ldt.c index 70fa24e2..b86a0e3c 100644 --- a/i386/i386/ldt.c +++ b/i386/i386/ldt.c @@ -45,6 +45,12 @@ extern #endi

[PATCH 3/4] x86_64: fix argument passing to bootstrap modules if ! USER32

2023-02-16 Thread Luca Dariz
* kern/bootstrap.c: replace integers with long/vm_offset_t --- kern/bootstrap.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/kern/bootstrap.c b/kern/bootstrap.c index 91f4241e..8f66a4b5 100644 --- a/kern/bootstrap.c +++ b/kern/bootstrap.c @@ -579,7 +579,7 @@ build

[PATCH 1/4] x86_64: fix some compiler warnings

2023-02-16 Thread Luca Dariz
* i386/include/mach/i386/vm_param.h: extend the vm constants to ULL on x86_64 to avoid a shift overflow warning * i386/intel/pmap.c: fix cast and unused variables --- i386/include/mach/i386/vm_param.h | 4 ++-- i386/intel/pmap.c | 8 +++- 2 files changed, 5 insertions(+), 7 d

[PATCH 2/4] x86_64: load Elf64 bootstrap modules if ! USER32

2023-02-16 Thread Luca Dariz
* i386/include/mach/i386/exec/elf.h: add Elf64 definitions and define common Elf structures, corresponding to 32/64 bit variants at compile time. * include/mach/exec/elf.h: add Elf64 definitions * kern/elf-load.c: use common Elf structures --- i386/include/mach/i386/exec/elf.h | 20 +++

Re: [PATCH mig] Make MIG work for pure 64 bit kernel and userland.

2023-02-16 Thread Luca Dariz
Hi Sergey, thanks a lot for the detailed explanation! Il 12/02/23 19:16, Sergey Bugaev ha scritto: But look at what Apple MIG does: typedef struct { mach_msg_header_t Head; /* start of the kernel processed data */ mach_msg_body_t msgh_body; mach_msg_port_descriptor_t port_a

Re: [RFC PATCH glibc 9/12] mach: Look for mach_i386.defs on x86_64 too

2023-02-16 Thread Joseph Myers
This commit broke the glibc build for i686-gnu. There are errors of the form: In file included from ../hurd/hurd/threadvar.h:23, from ../sysdeps/mach/hurd/mig-reply.c:20: ../sysdeps/mach/hurd/i386/tls.h:104:11: fatal error: mach/i386/mach_i386.h: No such file or directory 104

Re: [PATCH gnumach] trap: Fix Wformat issues

2023-02-16 Thread Samuel Thibault
Applied, thanks! Damien Zammit, le jeu. 16 févr. 2023 07:02:14 +, a ecrit: > --- > i386/i386/trap.c | 10 +- > 1 file changed, 5 insertions(+), 5 deletions(-) > > diff --git a/i386/i386/trap.c b/i386/i386/trap.c > index 9a35fb42..34ccb6a5 100644 > --- a/i386/i386/trap.c > +++ b/i386/

Re: checking whether mig supports the retcode keyword... no

2023-02-16 Thread Sergey Bugaev
On Thu, Feb 16, 2023 at 10:27 AM Flávio Cruz wrote: >> On that note: right now, MIG-generated stubs are broken on x86_64. MIG >> built from master complains about time_value_t (which GCC says is 16 >> bytes-, but MIG expects to be 12 bytes- sized). If I set >> desired_max_alignof to 8 (which it mu