From: Thomas Weißschuh Date: Sat, 14 Mar 2026 12:16:28 +0000 (+0100) Subject: m68k: uapi: Add ucontext.h X-Git-Tag: ceph-for-7.1-rc4~220^2~4 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=5247c783dc11eba298b3a6c03470125a67bf8cda;p=ceph-client.git m68k: uapi: Add ucontext.h ucontext.h should be an UAPI header as it is used for the kernel's signal handling interface. Move the header to the uapi/ directory. While at it, also add some necessary includes to the new header. Signed-off-by: Thomas Weißschuh Reviewed-by: Geert Uytterhoeven Link: https://patch.msgid.link/20260314-uapi-ucontext-m68k-v1-1-1b8b0e082b79@weissschuh.net Signed-off-by: Geert Uytterhoeven --- diff --git a/arch/m68k/include/asm/ucontext.h b/arch/m68k/include/asm/ucontext.h deleted file mode 100644 index 1523a8e5ff22..000000000000 --- a/arch/m68k/include/asm/ucontext.h +++ /dev/null @@ -1,31 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0 */ -#ifndef _M68K_UCONTEXT_H -#define _M68K_UCONTEXT_H - -typedef int greg_t; -#define NGREG 18 -typedef greg_t gregset_t[NGREG]; - -typedef struct fpregset { - int f_fpcntl[3]; - int f_fpregs[8*3]; -} fpregset_t; - -struct mcontext { - int version; - gregset_t gregs; - fpregset_t fpregs; -}; - -#define MCONTEXT_VERSION 2 - -struct ucontext { - unsigned long uc_flags; - struct ucontext *uc_link; - stack_t uc_stack; - struct mcontext uc_mcontext; - unsigned long uc_filler[80]; - sigset_t uc_sigmask; /* mask last for extensibility */ -}; - -#endif diff --git a/arch/m68k/include/uapi/asm/ucontext.h b/arch/m68k/include/uapi/asm/ucontext.h new file mode 100644 index 000000000000..ffac691604b4 --- /dev/null +++ b/arch/m68k/include/uapi/asm/ucontext.h @@ -0,0 +1,34 @@ +/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ +#ifndef _M68K_UCONTEXT_H +#define _M68K_UCONTEXT_H + +#include +#include + +typedef int greg_t; +#define NGREG 18 +typedef greg_t gregset_t[NGREG]; + +typedef struct fpregset { + int f_fpcntl[3]; + int f_fpregs[8*3]; +} fpregset_t; + +struct mcontext { + int version; + gregset_t gregs; + fpregset_t fpregs; +}; + +#define MCONTEXT_VERSION 2 + +struct ucontext { + unsigned long uc_flags; + struct ucontext *uc_link; + stack_t uc_stack; + struct mcontext uc_mcontext; + unsigned long uc_filler[80]; + sigset_t uc_sigmask; /* mask last for extensibility */ +}; + +#endif