OpenCloudOS-Kernel/arch/parisc
John David Anglin 798082be69 parisc: Fix patch code locking and flushing
This change fixes the following:

1) The flags variable is not initialized. Always use raw_spin_lock_irqsave
and raw_spin_unlock_irqrestore to serialize patching.

2) flush_kernel_vmap_range is primarily intended for DMA flushes.
The whole cache flush in flush_kernel_vmap_range is only possible
when interrupts are enabled on SMP machines. Since __patch_text_multiple
calls flush_kernel_vmap_range with interrupts disabled, it is better
to directly call flush_kernel_dcache_range_asm and
flush_kernel_icache_range_asm.

3) The final call to flush_icache_range is unnecessary.

Tested with `[PATCH, V3] parisc: Rewrite cache flush code for
PA8800/PA8900' change on rp3440, c8000 and c3750 (32 and 64-bit).

Note by Helge:
This patch had been temporarily reverted shortly before v5.18-rc6 in order
to fix boot issues. Now it can be re-applied.

Signed-off-by: John David Anglin <dave.anglin@bell.net>
Signed-off-by: Helge Deller <deller@gmx.de>
2022-05-17 21:52:59 +02:00
..
boot Kbuild updates for v5.17 2022-01-19 11:15:19 +02:00
configs parisc: Update 32- and 64-bit defconfigs 2022-05-08 20:01:11 +02:00
include parisc: Rewrite cache flush code for PA8800/PA8900 2022-05-17 21:52:47 +02:00
kernel parisc: Fix patch code locking and flushing 2022-05-17 21:52:59 +02:00
lib parisc: Use constants to encode the space registers like SR_KERNEL 2022-03-11 19:49:31 +01:00
math-emu parisc: Fix typos in comments 2022-05-08 20:01:12 +02:00
mm parisc: Disable debug code regarding cache flushes in handle_nadtlb_fault() 2022-05-17 21:49:06 +02:00
Kbuild kbuild: use more subdir- for visiting subdirectories while cleaning 2021-10-24 13:49:46 +09:00
Kconfig parisc: Re-enable GENERIC_CPU_DEVICES for !SMP 2022-05-08 20:01:11 +02:00
Kconfig.debug tracing: Refactor TRACE_IRQFLAGS_SUPPORT in Kconfig 2021-08-16 11:37:21 -04:00
Makefile parisc: Detect hppa-suse-linux-gcc compiler for cross-building 2022-03-29 21:37:12 +02:00
defpalo.conf parisc: switch to gzip-compressed vmlinuz kernel 2013-07-09 22:09:20 +02:00
install.sh parisc: Fix "make install" on newer debian releases 2021-12-04 21:36:04 +01:00
nm