From c0b9bae9d18980afa1797fb7b75adb4fbc837b66 Mon Sep 17 00:00:00 2001 From: Franck Bui-Huu Date: Mon, 5 Feb 2007 15:24:21 +0100 Subject: [MIPS] signal: clean up sigframe structure This patch makes 'struct sigframe' declaration avalaible for all signals code. It allows signal32 to not have its own declaration. This patch also removes all ICACHE_REFILLS_WORKAROUND_WAR tests in structure declaration and hopefully make them more readable. Signed-off-by: Franck Bui-Huu Signed-off-by: Ralf Baechle --- arch/mips/kernel/signal-common.h | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) (limited to 'arch/mips/kernel/signal-common.h') diff --git a/arch/mips/kernel/signal-common.h b/arch/mips/kernel/signal-common.h index 03d2b603fb8..6700bde0605 100644 --- a/arch/mips/kernel/signal-common.h +++ b/arch/mips/kernel/signal-common.h @@ -11,6 +11,32 @@ #ifndef __SIGNAL_COMMON_H #define __SIGNAL_COMMON_H +/* + * Horribly complicated - with the bloody RM9000 workarounds enabled + * the signal trampolines is moving to the end of the structure so we can + * increase the alignment without breaking software compatibility. + */ +#if ICACHE_REFILLS_WORKAROUND_WAR == 0 + +struct sigframe { + u32 sf_ass[4]; /* argument save space for o32 */ + u32 sf_code[2]; /* signal trampoline */ + struct sigcontext sf_sc; + sigset_t sf_mask; +}; + +#else /* ICACHE_REFILLS_WORKAROUND_WAR */ + +struct sigframe { + u32 sf_ass[4]; /* argument save space for o32 */ + u32 sf_pad[2]; + struct sigcontext sf_sc; /* hw context */ + sigset_t sf_mask; + u32 sf_code[8] ____cacheline_aligned; /* signal trampoline */ +}; + +#endif /* !ICACHE_REFILLS_WORKAROUND_WAR */ + /* * handle hardware context */ -- cgit v1.2.3