linux-stable/arch/loongarch/kernel
Huacai Chen 9d9f5b4376 LoongArch: Make WriteCombine configurable for ioremap()
commit 16c52e5030 upstream.

LoongArch maintains cache coherency in hardware, but when paired with
LS7A chipsets the WUC attribute (Weak-ordered UnCached, which is similar
to WriteCombine) is out of the scope of cache coherency machanism for
PCIe devices (this is a PCIe protocol violation, which may be fixed in
newer chipsets).

This means WUC can only used for write-only memory regions now, so this
option is disabled by default, making WUC silently fallback to SUC for
ioremap(). You can enable this option if the kernel is ensured to run on
hardware without this bug.

Kernel parameter writecombine=on/off can be used to override the Kconfig
option.

Cc: stable@vger.kernel.org
Suggested-by: WANG Xuerui <kernel@xen0n.name>
Reviewed-by: WANG Xuerui <kernel@xen0n.name>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-04-26 14:30:07 +02:00
..
.gitignore
Makefile LoongArch: Make -mstrict-align configurable 2023-04-26 14:30:07 +02:00
access-helper.h LoongArch: Add exception/interrupt handling 2022-06-03 20:09:28 +08:00
acpi.c LoongArch: Add suspend (ACPI S3) support 2022-12-14 08:41:53 +08:00
alternative.c LoongArch: Use common function sign_extend64() 2023-01-17 11:42:16 +08:00
asm-offsets.c LoongArch: Add basic STACKPROTECTOR support 2022-12-14 08:41:53 +08:00
cacheinfo.c LoongArch: Refactor cache probe and flush methods 2022-10-12 16:36:14 +08:00
cpu-probe.c LoongArch: Mark 3 symbol exports as non-GPL 2023-04-26 14:30:03 +02:00
crash_dump.c LoongArch: Add kdump support 2022-10-12 16:36:19 +08:00
dma.c LoongArch: Use acpi_arch_dma_setup() and remove ARCH_HAS_PHYS_TO_DMA 2022-09-24 18:39:21 +02:00
efi-header.S efi/loongarch: Add efistub booting support 2022-09-06 11:19:34 +02:00
efi.c LoongArch changes for v6.2 2022-12-19 08:23:27 -06:00
elf.c LoongArch: Add ELF and module support 2022-06-03 20:09:28 +08:00
entry.S LoongArch: Re-tab the assembly files 2022-07-29 18:22:32 +08:00
env.c LoongArch: Add FDT booting support from efi system table 2022-12-14 08:41:53 +08:00
fpu.S LoongArch: Consolidate __ex_table construction 2022-12-14 08:36:11 +08:00
ftrace.c LoongArch/ftrace: Add basic support 2022-12-14 08:41:53 +08:00
ftrace_dyn.c LoongArch: modules/ftrace: Initialize PLT at load time 2022-12-14 08:41:54 +08:00
genex.S LoongArch: Add generic ex-handler unwind in prologue unwinder 2023-01-17 11:42:16 +08:00
head.S efi: Put Linux specific magic number in the DOS header 2022-12-05 09:31:46 +01:00
idle.c LoongArch: Add process management 2022-06-03 20:09:28 +08:00
image-vars.h efi: loongarch: Drop exports of unused string routines 2022-11-09 12:42:02 +01:00
inst.c LoongArch: Simplify larch_insn_gen_xxx implementation 2023-01-17 11:42:16 +08:00
io.c LoongArch: Add misc common routines 2022-06-03 20:09:28 +08:00
irq.c LoongArch: SMP: Change prefix from loongson3 to loongson 2022-11-21 19:02:57 +08:00
machine_kexec.c LoongArch: Add kdump support 2022-10-12 16:36:19 +08:00
mcount.S LoongArch/ftrace: Add basic support 2022-12-14 08:41:53 +08:00
mcount_dyn.S LoongArch/ftrace: Add HAVE_DYNAMIC_FTRACE_WITH_REGS support 2022-12-14 08:41:53 +08:00
mem.c LoongArch: Add kdump support 2022-10-12 16:36:19 +08:00
module-sections.c LoongArch: modules/ftrace: Initialize PLT at load time 2022-12-14 08:41:54 +08:00
module.c LoongArch: modules/ftrace: Initialize PLT at load time 2022-12-14 08:41:54 +08:00
numa.c LoongArch changes for v6.2 2022-12-19 08:23:27 -06:00
perf_event.c LoongArch: Add perf events support 2022-10-12 16:36:14 +08:00
perf_regs.c LoongArch: Add perf events support 2022-10-12 16:36:14 +08:00
proc.c LoongArch: Fix probing of the CRC32 feature 2023-04-26 14:30:03 +02:00
process.c LoongArch: Get frame info in unwind_start() when regs is not available 2023-01-17 11:42:16 +08:00
ptrace.c LoongArch: Fix missing fcsr in ptrace's fpr_set 2022-07-29 18:22:33 +08:00
relocate_kernel.S LoongArch: Add kdump support 2022-10-12 16:36:19 +08:00
reset.c LoongArch: Add hibernation (ACPI S4) support 2022-12-14 08:41:53 +08:00
setup.c LoongArch: Make WriteCombine configurable for ioremap() 2023-04-26 14:30:07 +02:00
signal.c LoongArch: Adjust arch_do_signal_or_restart() to adapt generic entry 2022-09-03 18:01:27 +08:00
smp.c LoongArch: Add suspend (ACPI S3) support 2022-12-14 08:41:53 +08:00
stacktrace.c LoongArch: Check unwind_error() in arch_stack_walk() 2023-04-26 14:30:03 +02:00
switch.S LoongArch: Add basic STACKPROTECTOR support 2022-12-14 08:41:53 +08:00
syscall.c LoongArch: Add system call support 2022-06-03 20:09:28 +08:00
sysrq.c LoongArch: Add SysRq-x (TLB Dump) support 2022-10-12 16:36:14 +08:00
time.c LoongArch: Only call get_timer_irq() once in constant_clockevent_init() 2023-03-22 13:37:56 +01:00
topology.c LoongArch: Do not create sysfs control file for io master CPUs 2022-10-12 16:36:08 +08:00
traps.c LoongArch: Make -mstrict-align configurable 2023-04-26 14:30:07 +02:00
unaligned.c LoongArch: Add unaligned access support 2022-12-14 08:36:11 +08:00
unwind.c LoongArch: Check unwind_error() in arch_stack_walk() 2023-04-26 14:30:03 +02:00
unwind_guess.c LoongArch: Strip guess unwinder out from prologue unwinder 2023-01-17 11:42:16 +08:00
unwind_prologue.c LoongArch: Check unwind_error() in arch_stack_walk() 2023-04-26 14:30:03 +02:00
vdso.c treewide: use get_random_u32_below() instead of deprecated function 2022-11-18 02:15:15 +01:00
vmlinux.lds.S LoongArch: Add alternative runtime patching mechanism 2022-12-14 08:36:11 +08:00