1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-11-21 07:15:49 +00:00

freebsd32: struct siginfo32 -> struct __siginfo32

In the next commit I will update syscalls.master to use struct __siginfo
(which actually exists) so this update will be needed to make
generated files (from make sysent) align.

Reviewed by:	kib
Differential Revision:	https://reviews.freebsd.org/D44380
This commit is contained in:
Brooks Davis 2024-03-18 21:37:39 +00:00
parent 7936d4e4d0
commit d060b420e0
10 changed files with 22 additions and 21 deletions

View File

@ -439,7 +439,7 @@ static void
freebsd4_ia32_sendsig(sig_t catcher, ksiginfo_t *ksi, sigset_t *mask)
{
struct ia32_freebsd4_sigframe sf, *sfp;
struct siginfo32 siginfo;
struct __siginfo32 siginfo;
struct proc *p;
struct thread *td;
struct sigacts *psp;
@ -550,7 +550,7 @@ void
ia32_sendsig(sig_t catcher, ksiginfo_t *ksi, sigset_t *mask)
{
struct ia32_sigframe sf, *sfp;
struct siginfo32 siginfo;
struct __siginfo32 siginfo;
struct proc *p;
struct thread *td;
struct sigacts *psp;

View File

@ -49,7 +49,8 @@
_Static_assert(sizeof(mcontext32_t) == 208, "mcontext32_t size incorrect");
_Static_assert(sizeof(ucontext32_t) == 260, "ucontext32_t size incorrect");
_Static_assert(sizeof(struct siginfo32) == 64, "struct siginfo32 size incorrect");
_Static_assert(sizeof(struct __siginfo32) == 64,
"struct __siginfo32 size incorrect");
extern void freebsd32_sendsig(sig_t catcher, ksiginfo_t *ksi, sigset_t *mask);
@ -351,7 +352,7 @@ freebsd32_sendsig(sig_t catcher, ksiginfo_t *ksi, sigset_t *mask)
struct trapframe *tf;
struct sigframe32 *fp, frame;
struct sigacts *psp;
struct siginfo32 siginfo;
struct __siginfo32 siginfo;
struct sysentvec *sysent;
int onstack;
int sig;

View File

@ -70,7 +70,7 @@ struct frame {
#ifdef COMPAT_FREEBSD32
struct sigframe32 {
struct siginfo32 sf_si;
struct __siginfo32 sf_si;
ucontext32_t sf_uc;
mcontext32_vfp_t sf_vfp;
};

View File

@ -247,7 +247,7 @@ freebsd32_wait6(struct thread *td, struct freebsd32_wait6_args *uap)
{
struct __wrusage32 wru32;
struct __wrusage wru, *wrup;
struct siginfo32 si32;
struct __siginfo32 si32;
struct __siginfo si, *sip;
int error, status;
@ -1026,7 +1026,7 @@ freebsd32_ptrace(struct thread *td, struct freebsd32_ptrace_args *uap)
*/
data = sizeof(r.pl);
if (uap->data < offsetof(struct ptrace_lwpinfo32, pl_siginfo) +
sizeof(struct siginfo32))
sizeof(struct __siginfo32))
data = offsetof(struct ptrace_lwpinfo, pl_siginfo);
break;
case PT_GETREGS:
@ -3271,7 +3271,7 @@ freebsd32_thr_suspend(struct thread *td, struct freebsd32_thr_suspend_args *uap)
}
void
siginfo_to_siginfo32(const siginfo_t *src, struct siginfo32 *dst)
siginfo_to_siginfo32(const siginfo_t *src, struct __siginfo32 *dst)
{
bzero(dst, sizeof(*dst));
dst->si_signo = src->si_signo;
@ -3320,7 +3320,7 @@ freebsd32_sigtimedwait(struct thread *td, struct freebsd32_sigtimedwait_args *ua
struct timespec *timeout;
sigset_t set;
ksiginfo_t ksi;
struct siginfo32 si32;
struct __siginfo32 si32;
int error;
if (uap->timeout) {
@ -3343,7 +3343,7 @@ freebsd32_sigtimedwait(struct thread *td, struct freebsd32_sigtimedwait_args *ua
if (uap->info) {
siginfo_to_siginfo32(&ksi.ksi_info, &si32);
error = copyout(&si32, uap->info, sizeof(struct siginfo32));
error = copyout(&si32, uap->info, sizeof(struct __siginfo32));
}
if (error == 0)
@ -3358,7 +3358,7 @@ int
freebsd32_sigwaitinfo(struct thread *td, struct freebsd32_sigwaitinfo_args *uap)
{
ksiginfo_t ksi;
struct siginfo32 si32;
struct __siginfo32 si32;
sigset_t set;
int error;
@ -3372,7 +3372,7 @@ freebsd32_sigwaitinfo(struct thread *td, struct freebsd32_sigwaitinfo_args *uap)
if (uap->info) {
siginfo_to_siginfo32(&ksi.ksi_info, &si32);
error = copyout(&si32, uap->info, sizeof(struct siginfo32));
error = copyout(&si32, uap->info, sizeof(struct __siginfo32));
}
if (error == 0)
td->td_retval[0] = ksi.ksi_signo;

View File

@ -61,6 +61,6 @@ struct sigevent32 {
struct sigevent;
int convert_sigevent32(struct sigevent32 *sig32, struct sigevent *sig);
void siginfo_to_siginfo32(const siginfo_t *src, struct siginfo32 *dst);
void siginfo_to_siginfo32(const siginfo_t *src, struct __siginfo32 *dst);
#endif /* !_COMPAT_FREEBSD32_SIGNAL_H_ */

View File

@ -154,7 +154,7 @@ struct ia32_freebsd4_sigframe {
uint32_t sf_addr; /* undocumented 4th arg */
uint32_t sf_ah; /* action/handler pointer */
struct ia32_freebsd4_ucontext sf_uc; /* = *sf_ucontext */
struct siginfo32 sf_si; /* = *sf_siginfo (SA_SIGINFO case) */
struct __siginfo32 sf_si; /* = *sf_siginfo (SA_SIGINFO case) */
};
struct ia32_sigframe {
@ -165,7 +165,7 @@ struct ia32_sigframe {
uint32_t sf_ah; /* action/handler pointer */
/* Beware, hole due to ucontext being 16 byte aligned! */
struct ia32_ucontext sf_uc; /* = *sf_ucontext */
struct siginfo32 sf_si; /* = *sf_siginfo (SA_SIGINFO case) */
struct __siginfo32 sf_si; /* = *sf_siginfo (SA_SIGINFO case) */
};
struct ia32_osiginfo {

View File

@ -76,7 +76,7 @@
CTASSERT(sizeof(struct ia32_mcontext) == 640);
CTASSERT(sizeof(struct ia32_ucontext) == 704);
CTASSERT(sizeof(struct ia32_sigframe) == 800);
CTASSERT(sizeof(struct siginfo32) == 64);
CTASSERT(sizeof(struct __siginfo32) == 64);
#ifdef COMPAT_FREEBSD4
CTASSERT(sizeof(struct ia32_freebsd4_mcontext) == 260);
CTASSERT(sizeof(struct ia32_freebsd4_ucontext) == 324);

View File

@ -117,7 +117,7 @@ typedef struct __ucontext32 {
struct sigframe32 {
ucontext32_t sf_uc;
struct siginfo32 sf_si;
struct __siginfo32 sf_si;
};
static int grab_mcontext32(struct thread *td, mcontext32_t *, int flags);
@ -138,7 +138,7 @@ _Static_assert(sizeof(siginfo_t) == 80, "siginfo_t size incorrect");
#ifdef COMPAT_FREEBSD32
_Static_assert(sizeof(mcontext32_t) == 1224, "mcontext32_t size incorrect");
_Static_assert(sizeof(ucontext32_t) == 1280, "ucontext32_t size incorrect");
_Static_assert(sizeof(struct siginfo32) == 64, "struct siginfo32 size incorrect");
_Static_assert(sizeof(struct __siginfo32) == 64, "struct __siginfo32 size incorrect");
#endif /* COMPAT_FREEBSD32 */
#else /* powerpc */
_Static_assert(sizeof(mcontext_t) == 1224, "mcontext_t size incorrect");
@ -155,7 +155,7 @@ sendsig(sig_t catcher, ksiginfo_t *ksi, sigset_t *mask)
struct thread *td;
struct proc *p;
#ifdef COMPAT_FREEBSD32
struct siginfo32 siginfo32;
struct __siginfo32 siginfo32;
struct sigframe32 sf32;
#endif
size_t sfpsize;

View File

@ -150,7 +150,7 @@ struct ptrace_lwpinfo32 {
int pl_flags; /* LWP flags. */
sigset_t pl_sigmask; /* LWP signal mask */
sigset_t pl_siglist; /* LWP pending signal */
struct siginfo32 pl_siginfo; /* siginfo for signal */
struct __siginfo32 pl_siginfo; /* siginfo for signal */
char pl_tdname[MAXCOMLEN + 1]; /* LWP name. */
pid_t pl_child_pid; /* New child pid */
u_int pl_syscall_code;

View File

@ -274,7 +274,7 @@ typedef struct __siginfo {
#define si_syscall _reason._capsicum._syscall
#if defined(_WANT_LWPINFO32) || (defined(_KERNEL) && defined(__LP64__))
struct siginfo32 {
struct __siginfo32 {
int si_signo; /* signal number */
int si_errno; /* errno association */
int si_code; /* signal code */