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

MIPS: Loongson: Fix phys_mem_access_prot() check

The check used to determine if uncached accelerated should be used or not
is wrong. The parenthesis are misplaced and making the test fail.

Signed-off-by: Arnaud Patard <apatard@mandriva.com>
To: linux-mips@linux-mips.org
Patchwork: http://patchwork.linux-mips.org/patch/1161/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>

authored by

Arnaud Patard and committed by
Ralf Baechle
514b6d0c ff40ad72

+1 -1
+1 -1
arch/mips/loongson/common/mem.c
··· 75 75 unsigned long end = offset + size; 76 76 77 77 if (__uncached_access(file, offset)) { 78 - if (((uca_start && offset) >= uca_start) && 78 + if (uca_start && (offset >= uca_start) && 79 79 (end <= uca_end)) 80 80 return __pgprot((pgprot_val(vma_prot) & 81 81 ~_CACHE_MASK) |