OrangePi_CM5/include/asm-generic
Nathan Chancellor 516f9f2300 vmlinux.lds.h: Fix placement of '.data..decrypted' section
commit 000f8870a47bdc36730357883b6aef42bced91ee upstream.

Commit d4c639990036 ("vmlinux.lds.h: Avoid orphan section with !SMP")
fixed an orphan section warning by adding the '.data..decrypted' section
to the linker script under the PERCPU_DECRYPTED_SECTION define but that
placement introduced a panic with !SMP, as the percpu sections are not
instantiated with that configuration so attempting to access variables
defined with DEFINE_PER_CPU_DECRYPTED() will result in a page fault.

Move the '.data..decrypted' section to the DATA_MAIN define so that the
variables in it are properly instantiated at boot time with
CONFIG_SMP=n.

Cc: stable@vger.kernel.org
Fixes: d4c639990036 ("vmlinux.lds.h: Avoid orphan section with !SMP")
Link: https://lore.kernel.org/cbbd3548-880c-d2ca-1b67-5bb93b291d5f@huawei.com/
Debugged-by: Ard Biesheuvel <ardb@kernel.org>
Reported-by: Zhao Wenhui <zhaowenhui8@huawei.com>
Tested-by: xiafukun <xiafukun@huawei.com>
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
Signed-off-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/20221108174934.3384275-1-nathan@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-11-16 09:57:16 +01:00
..
bitops locking/atomic: Make test_and_*_bit() ordered on failure 2022-08-25 11:38:10 +02:00
vdso
…
Kbuild local64.h: make <asm/local64.h> mandatory 2021-01-12 20:18:16 +01:00
asm-offsets.h
…
asm-prototypes.h
…
atomic-instrumented.h locking/atomics: Use read-write instrumentation for atomic RMWs 2020-08-24 15:09:59 -07:00
atomic-long.h
…
atomic.h locking/atomic: Move ATOMIC_INIT into linux/types.h 2020-07-29 16:14:18 +02:00
atomic64.h
…
audit_change_attr.h
…
audit_dir_write.h
…
audit_read.h
…
audit_signal.h
…
audit_write.h
…
barrier.h compiler.h: fix barrier_data() on clang 2020-11-14 11:26:03 -08:00
bitops.h
…
bitsperlong.h
…
bug.h treewide: Convert macro and uses of __section(foo) to __section("foo") 2020-10-25 14:51:49 -07:00
bugs.h
…
cache.h
…
cacheflush.h
…
checksum.h unify generic instances of csum_partial_copy_nocheck() 2020-08-20 15:45:14 -04:00
cmpxchg-local.h
…
cmpxchg.h
…
compat.h compat: lift compat_s64 and compat_u64 to <asm-generic/compat.h> 2020-09-17 13:00:46 -04:00
current.h
…
delay.h
…
device.h
…
div64.h
…
dma-mapping.h
…
dma.h
…
early_ioremap.h
…
emergency-restart.h
…
error-injection.h treewide: Convert macro and uses of __section(foo) to __section("foo") 2020-10-25 14:51:49 -07:00
exec.h
…
export.h
…
extable.h
…
fb.h
…
fixmap.h
…
flat.h
…
ftrace.h
…
futex.h
…
getorder.h
…
gpio.h
…
hardirq.h
…
hugetlb.h
…
hw_irq.h
…
hyperv-tlfs.h
…
ide_iops.h
…
int-ll64.h
…
io.h asm-generic/io.h: Fix !CONFIG_GENERIC_IOMAP pci_iounmap() implementation 2020-10-05 09:44:16 +01:00
ioctl.h
…
iomap.h iomap: constify ioreadX() iomem argument (as in generic implementation) 2020-08-14 19:56:57 -07:00
irq.h
…
irq_regs.h
…
irq_work.h
…
irqflags.h
…
kdebug.h
…
kmap_types.h
…
kprobes.h treewide: Convert macro and uses of __section(foo) to __section("foo") 2020-10-25 14:51:49 -07:00
kvm_para.h
…
kvm_types.h
…
linkage.h
…
local.h
…
local64.h
…
mcs_spinlock.h
…
memory_model.h
…
mm-arch-hooks.h
…
mm_hooks.h
…
mmiowb.h
…
mmiowb_types.h
…
mmu.h
…
mmu_context.h
…
module.h
…
module.lds.h kbuild: preprocess module linker script 2020-09-25 00:36:41 +09:00
mshyperv.h Drivers: hv: vmbus: Add parsing of VMbus interrupt in ACPI DSDT 2020-10-14 19:14:51 +00:00
msi.h
…
page.h
…
param.h
…
parport.h
…
pci.h
…
pci_iomap.h
…
percpu.h asm-generic: percpu: avoid Wshadow warning 2020-10-26 23:54:48 +00:00
pgalloc.h asm-generic: pgalloc.h: use correct #ifdef to enable pud_alloc_one() 2020-08-14 19:56:55 -07:00
pgtable-nop4d.h
…
pgtable-nopmd.h
…
pgtable-nopud.h
…
pgtable_uffd.h
…
preempt.h sched/core: Initialize the idle task with preemption disabled 2021-07-14 16:55:50 +02:00
qrwlock.h
…
qrwlock_types.h
…
qspinlock.h powerpc updates for 5.9 2020-08-07 10:33:50 -07:00
qspinlock_types.h locking/qspinlock: Do not include atomic.h from qspinlock_types.h 2020-07-29 16:14:19 +02:00
resource.h
…
rwonce.h
…
seccomp.h
…
sections.h asm-generic: sections: refactor memory_intersects 2022-08-31 17:15:22 +02:00
serial.h
…
set_memory.h
…
shmparam.h
…
signal.h
…
simd.h
…
spinlock.h
…
statfs.h
…
string.h
…
switch_to.h
…
syscall.h
…
syscalls.h
…
termios-base.h
…
termios.h
…
timex.h
…
tlb.h tlb: hugetlb: Add more sizes to tlb_remove_huge_tlb_entry 2022-04-20 09:23:22 +02:00
tlbflush.h
…
topology.h
…
trace_clock.h
…
uaccess.h asm-generic: mark __{get,put}_user_fn as __always_inline 2020-10-27 16:13:09 +01:00
unaligned.h
…
user.h
…
vermagic.h
…
vga.h
…
vmlinux.lds.h vmlinux.lds.h: Fix placement of '.data..decrypted' section 2022-11-16 09:57:16 +01:00
vtime.h
…
word-at-a-time.h
…
xor.h
…