Explorar o código

sh: fix futex/robust_list on nommu models

The futex cmpxchg runtime testing in kernel/futex.c depends on
accesses to address 0 producing EFAULT, which obviously does not work
on nommu. Since SH always has cmpxchg, disable the broken runtime
detection.

At some point this should be fixed at the kernel/futex.c level. UP
machines can always provide a working cmpxchg with interrupt masking,
and SMP cannot function without a working cmpxchg anyway.

Signed-off-by: Rich Felker <dalias@libc.org>
Rich Felker %!s(int64=9) %!d(string=hai) anos
pai
achega
72cc564f16
Modificáronse 1 ficheiros con 1 adicións e 0 borrados
  1. 1 0
      arch/sh/Kconfig

+ 1 - 0
arch/sh/Kconfig

@@ -45,6 +45,7 @@ config SUPERH
 	select OLD_SIGSUSPEND
 	select OLD_SIGSUSPEND
 	select OLD_SIGACTION
 	select OLD_SIGACTION
 	select HAVE_ARCH_AUDITSYSCALL
 	select HAVE_ARCH_AUDITSYSCALL
+	select HAVE_FUTEX_CMPXCHG if FUTEX
 	select HAVE_NMI
 	select HAVE_NMI
 	help
 	help
 	  The SuperH is a RISC processor targeted for use in embedded systems
 	  The SuperH is a RISC processor targeted for use in embedded systems