Skip to contentSkip to conversation

m68k: use CPU_HAS_NO_BITFIELDS for signal functions

PATCH New [email protected] 1 participant 1 message Jul 4, 2011 m68k architecture

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 m68k: use CPU_HAS_NO_BITFIELDS for signal functions

From: Greg Ungerer <[email protected]>

When reworking bitops.h to be clean for all processor types we introduced a CONFIG_CPU_HAS_NO_BITFIELDS define to signal whether this processor type supported the bit field instructions. The ARCH_SIG_BITOPS functions for m68k use these instruction types. We should base the use of these functions (or the generic versions) on the CONFIG_CPU_HAS_NO_BITFIELDS define.

---
 arch/m68k/include/asm/signal.h |   15 +++++++--------
 1 files changed, 7 insertions(+), 8 deletions(-)
arch/m68k/include/asm/signal.h +7 -8
index 5bc09c7..60e8866 100644
@@ -150,7 +150,7 @@ typedef struct sigaltstack {
 #ifdef __KERNEL__
 #include <asm/sigcontext.h>
 
-#ifndef __uClinux__
+#ifndef CONFIG_CPU_HAS_NO_BITFIELDS
 #define __HAVE_ARCH_SIG_BITOPS
 
 static inline void sigaddset(sigset_t *set, int _sig)
@@ -199,15 +199,14 @@ static inline int sigfindinword(unsigned long word)
 	return word ^ 31;
 }
 
-struct pt_regs;
-extern void ptrace_signal_deliver(struct pt_regs *regs, void *cookie);
+#endif /* !CONFIG_CPU_HAS_NO_BITFIELDS */
 
-#else
-
-#undef __HAVE_ARCH_SIG_BITOPS
+#ifdef __uClinux__
 #define ptrace_signal_deliver(regs, cookie) do { } while (0)
-
+#else
+struct pt_regs;
+extern void ptrace_signal_deliver(struct pt_regs *regs, void *cookie);
 #endif /* __uClinux__ */
-#endif /* __KERNEL__ */
 
+#endif /* __KERNEL__ */
 #endif /* _M68K_SIGNAL_H */
Signature · 1 line
1.7.0.4