public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libc/28938] New: [csky, microblaze, or1k, powerpc] typedef for greg_t missing in sys/ucontext.h on some architectures
@ 2022-03-03 14:19 Arfrever.FTA at GMail dot Com
  2022-03-03 15:05 ` [Bug libc/28938] " schwab@linux-m68k.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Arfrever.FTA at GMail dot Com @ 2022-03-03 14:19 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=28938

            Bug ID: 28938
           Summary: [csky, microblaze, or1k, powerpc] typedef for greg_t
                    missing in sys/ucontext.h on some architectures
           Product: glibc
           Version: unspecified
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: libc
          Assignee: unassigned at sourceware dot org
          Reporter: Arfrever.FTA at GMail dot Com
                CC: drepper.fsp at gmail dot com
  Target Milestone: ---

Original bug report: https://bugs.gentoo.org/834450

> In file included from include/libucontext/libucontext.h:5,
>                  from arch/ppc/makecontext.c:19:
> include/libucontext/bits.h:8:9: error: unknown type name 'greg_t'
>     8 | typedef greg_t libucontext_greg_t;
>       |         ^~~~~~


In glibc 2.35:

The following sys/ucontext.h files define both greg_t and gregset_t:

sysdeps/arm/sys/ucontext.h
sysdeps/i386/sys/ucontext.h
sysdeps/m68k/sys/ucontext.h
sysdeps/mips/sys/ucontext.h
sysdeps/unix/sysv/linux/aarch64/sys/ucontext.h
sysdeps/unix/sysv/linux/alpha/sys/ucontext.h
sysdeps/unix/sysv/linux/arm/sys/ucontext.h
sysdeps/unix/sysv/linux/hppa/sys/ucontext.h
sysdeps/unix/sysv/linux/m68k/sys/ucontext.h
sysdeps/unix/sysv/linux/mips/sys/ucontext.h
sysdeps/unix/sysv/linux/riscv/sys/ucontext.h
sysdeps/unix/sysv/linux/s390/sys/ucontext.h
sysdeps/unix/sysv/linux/sh/sys/ucontext.h
sysdeps/unix/sysv/linux/sparc/sys/ucontext.h
sysdeps/unix/sysv/linux/x86/sys/ucontext.h

The following sys/ucontext.h files define gregset_t, but not greg_t:

sysdeps/unix/sysv/linux/csky/sys/ucontext.h
sysdeps/unix/sysv/linux/powerpc/sys/ucontext.h

The following sys/ucontext.h files do not define greg_t or gregset_t:

sysdeps/generic/sys/ucontext.h
sysdeps/unix/sysv/linux/arc/sys/ucontext.h
sysdeps/unix/sysv/linux/ia64/sys/ucontext.h
sysdeps/unix/sysv/linux/microblaze/sys/ucontext.h
sysdeps/unix/sysv/linux/nios2/sys/ucontext.h
sysdeps/unix/sysv/linux/or1k/sys/ucontext.h


In musl, sys/ucontext.h includes ucontext.h, which includes signal.h, which
includes bits/signal.h.

In musl, the following bits/signal.h files define greg_t and gregset_t:

arch/aarch64/bits/signal.h
arch/arm/bits/signal.h
arch/i386/bits/signal.h
arch/m68k/bits/signal.h
arch/microblaze/bits/signal.h
arch/mips/bits/signal.h
arch/mips64/bits/signal.h
arch/mipsn32/bits/signal.h
arch/or1k/bits/signal.h
arch/powerpc/bits/signal.h
arch/powerpc64/bits/signal.h
arch/riscv64/bits/signal.h
arch/s390x/bits/signal.h
arch/sh/bits/signal.h
arch/x32/bits/signal.h
arch/x86_64/bits/signal.h


In glibc, typedef for greg_t needs to be added at least in:

sysdeps/unix/sysv/linux/powerpc/sys/ucontext.h
  (In musl, in arch/powerpc/bits/signal.h: 'typedef unsigned long greg_t,
gregset_t[48]')
  (In musl, in arch/powerpc64/bits/signal.h: 'typedef unsigned long greg_t,
gregset_t[48]')

And probably also in:

sysdeps/unix/sysv/linux/csky/sys/ucontext.h
  (Not supported by musl, but 'typedef unsigned long greg_t' seems obvious.)
sysdeps/unix/sysv/linux/microblaze/sys/ucontext.h
  (In musl: 'typedef unsigned long greg_t, gregset_t[38]')
sysdeps/unix/sysv/linux/or1k/sys/ucontext.h
  (In musl: 'typedef unsigned long greg_t, gregset_t[34]')

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug libc/28938] [csky, microblaze, or1k, powerpc] typedef for greg_t missing in sys/ucontext.h on some architectures
  2022-03-03 14:19 [Bug libc/28938] New: [csky, microblaze, or1k, powerpc] typedef for greg_t missing in sys/ucontext.h on some architectures Arfrever.FTA at GMail dot Com
@ 2022-03-03 15:05 ` schwab@linux-m68k.org
  2022-03-03 16:24 ` sam at gentoo dot org
  2022-06-30  2:16 ` matoro_bugzilla_glibc at matoro dot tk
  2 siblings, 0 replies; 4+ messages in thread
From: schwab@linux-m68k.org @ 2022-03-03 15:05 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=28938

--- Comment #1 from Andreas Schwab <schwab@linux-m68k.org> ---
I don't think the set of definitions expected from <sys/ucontext.h> is well
defined.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug libc/28938] [csky, microblaze, or1k, powerpc] typedef for greg_t missing in sys/ucontext.h on some architectures
  2022-03-03 14:19 [Bug libc/28938] New: [csky, microblaze, or1k, powerpc] typedef for greg_t missing in sys/ucontext.h on some architectures Arfrever.FTA at GMail dot Com
  2022-03-03 15:05 ` [Bug libc/28938] " schwab@linux-m68k.org
@ 2022-03-03 16:24 ` sam at gentoo dot org
  2022-06-30  2:16 ` matoro_bugzilla_glibc at matoro dot tk
  2 siblings, 0 replies; 4+ messages in thread
From: sam at gentoo dot org @ 2022-03-03 16:24 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=28938

Sam James <sam at gentoo dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |sam at gentoo dot org

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug libc/28938] [csky, microblaze, or1k, powerpc] typedef for greg_t missing in sys/ucontext.h on some architectures
  2022-03-03 14:19 [Bug libc/28938] New: [csky, microblaze, or1k, powerpc] typedef for greg_t missing in sys/ucontext.h on some architectures Arfrever.FTA at GMail dot Com
  2022-03-03 15:05 ` [Bug libc/28938] " schwab@linux-m68k.org
  2022-03-03 16:24 ` sam at gentoo dot org
@ 2022-06-30  2:16 ` matoro_bugzilla_glibc at matoro dot tk
  2 siblings, 0 replies; 4+ messages in thread
From: matoro_bugzilla_glibc at matoro dot tk @ 2022-06-30  2:16 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=28938

matoro <matoro_bugzilla_glibc at matoro dot tk> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |matoro_bugzilla_glibc@mator
                   |                            |o.tk

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-06-30  2:16 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-03 14:19 [Bug libc/28938] New: [csky, microblaze, or1k, powerpc] typedef for greg_t missing in sys/ucontext.h on some architectures Arfrever.FTA at GMail dot Com
2022-03-03 15:05 ` [Bug libc/28938] " schwab@linux-m68k.org
2022-03-03 16:24 ` sam at gentoo dot org
2022-06-30  2:16 ` matoro_bugzilla_glibc at matoro dot tk

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).