]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
s390/percpu: Get rid of ARCH_MODULE_NEEDS_WEAK_PER_CPU
authorHeiko Carstens <hca@linux.ibm.com>
Wed, 19 Nov 2025 14:37:56 +0000 (15:37 +0100)
committerHeiko Carstens <hca@linux.ibm.com>
Mon, 24 Nov 2025 10:45:20 +0000 (11:45 +0100)
Since the rework of the kernel virtual address space [1] the module area
and the kernel image are within the same 4GB area. Therefore there is no
need for the weak per cpu workaround for modules anymore. Remove it.

[1] commit c98d2ecae08f ("s390/mm: Uncouple physical vs virtual address spaces")

Acked-by: Alexander Gordeev <agordeev@linux.ibm.com>
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
arch/s390/Kconfig
arch/s390/include/asm/percpu.h
include/linux/percpu-defs.h

index 9914db771e4505b4acbc6d5b4fb6ade4dc4037ec..cb143bf782f8b85211760f299ac29b0dba8e75fa 100644 (file)
@@ -140,7 +140,6 @@ config S390
        select ARCH_INLINE_WRITE_UNLOCK_IRQ
        select ARCH_INLINE_WRITE_UNLOCK_IRQRESTORE
        select ARCH_MHP_MEMMAP_ON_MEMORY_ENABLE
-       select ARCH_MODULE_NEEDS_WEAK_PER_CPU
        select ARCH_STACKWALK
        select ARCH_SUPPORTS_ATOMIC_RMW
        select ARCH_SUPPORTS_DEBUG_PAGEALLOC
index 965886dfe954a6d67b80cb841e07d0c532ec8d28..5899f57f17d16fd066eb82c1a635f44be0ab2017 100644 (file)
  */
 #define __my_cpu_offset get_lowcore()->percpu_offset
 
-/*
- * For 64 bit module code, the module may be more than 4G above the
- * per cpu area, use weak definitions to force the compiler to
- * generate external references.
- * Therefore, we have enabled CONFIG_ARCH_MODULE_NEEDS_WEAK_PER_CPU
- * in the Kconfig.
- */
-
 /*
  * We use a compare-and-swap loop since that uses less cpu cycles than
  * disabling and enabling interrupts like the generic variant would do.
index 12d90360f6db936f27074a662f2607c63187b497..43c854a273c3aa4cb266393c4f5f9d0c3667946d 100644 (file)
@@ -52,7 +52,7 @@
        __section(".discard") __attribute__((unused))
 
 /*
- * s390 and alpha modules require percpu variables to be defined as
+ * alpha modules require percpu variables to be defined as
  * weak to force the compiler to generate GOT based external
  * references for them.  This is necessary because percpu sections
  * will be located outside of the usually addressable area.