Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

parisc: Flush correct cache in cacheflush() syscall

The assembly flush instructions were swapped for I- and D-cache flags:

SYSCALL_DEFINE3(cacheflush, ...)
{
if (cache & DCACHE) {
"fic ...\n"
}
if (cache & ICACHE && error == 0) {
"fdc ...\n"
}

Fix it by using fdc for DCACHE, and fic for ICACHE flushing.

Reported-by: Felix Lechner <felix.lechner@lease-up.com>
Fixes: c6d96328fecd ("parisc: Add cacheflush() syscall")
Cc: <stable@vger.kernel.org> # v6.5+
Signed-off-by: Helge Deller <deller@gmx.de>

+2 -2
+2 -2
arch/parisc/kernel/cache.c
··· 953 953 #else 954 954 "1: cmpb,<<,n %0,%2,1b\n" 955 955 #endif 956 - " fic,m %3(%4,%0)\n" 956 + " fdc,m %3(%4,%0)\n" 957 957 "2: sync\n" 958 958 ASM_EXCEPTIONTABLE_ENTRY_EFAULT(1b, 2b, "%1") 959 959 : "+r" (start), "+r" (error) ··· 968 968 #else 969 969 "1: cmpb,<<,n %0,%2,1b\n" 970 970 #endif 971 - " fdc,m %3(%4,%0)\n" 971 + " fic,m %3(%4,%0)\n" 972 972 "2: sync\n" 973 973 ASM_EXCEPTIONTABLE_ENTRY_EFAULT(1b, 2b, "%1") 974 974 : "+r" (start), "+r" (error)