Skip to content

Commit e0b4992

Browse files
riastradhriastradh
authored andcommitted
t_signal_and_sp: Mark signalsp xfail on mips n32/n64.
The kernel takes an initially aligned stack pointer and subtracts sizeof(struct sigframe_siginfo) or sizeof(struct sigframe_siginfo32) from it -- that is, 872=0x368 or 792=0x318 bytes, respectively. But n32 and n64 require 16-byte stack alignment. PR kern/59327: user stack pointer is not aligned properly
1 parent d4ddc84 commit e0b4992

1 file changed

Lines changed: 7 additions & 2 deletions

File tree

tests/kernel/t_signal_and_sp.c

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/* $NetBSD: t_signal_and_sp.c,v 1.10 2025/04/21 12:06:08 riastradh Exp $ */
1+
/* $NetBSD: t_signal_and_sp.c,v 1.11 2025/04/24 16:57:27 riastradh Exp $ */
22

33
/*
44
* Copyright (c) 2024 The NetBSD Foundation, Inc.
@@ -27,7 +27,7 @@
2727
*/
2828

2929
#include <sys/cdefs.h>
30-
__RCSID("$NetBSD: t_signal_and_sp.c,v 1.10 2025/04/21 12:06:08 riastradh Exp $");
30+
__RCSID("$NetBSD: t_signal_and_sp.c,v 1.11 2025/04/24 16:57:27 riastradh Exp $");
3131

3232
#include <sys/wait.h>
3333

@@ -389,6 +389,11 @@ ATF_TC_BODY(signalsp, tc)
389389
#if defined STACK_ALIGNBYTES && defined HAVE_SIGNALSPHANDLER
390390
struct sigaction sa;
391391

392+
#if defined __mips_n32 || defined __mips_n64 /* 16-byte, vs 8-byte o32 */
393+
atf_tc_expect_fail("PR kern/59327:"
394+
" user stack pointer is not aligned properly");
395+
#endif
396+
392397
memset(&sa, 0, sizeof(sa));
393398
sa.sa_handler = &signalsphandler;
394399
RL(sigaction(SIGUSR1, &sa, NULL));

0 commit comments

Comments
 (0)