[PATCH] ARM: 2784/1: Fix the block cache flush operation range

Patch from Catalin Marinas

The range for the ARMv6 block cache operations is inclusive but the
kernel doesn't re-calculate the end address, causing a page fault when
used (this only happens with support for cache aliasing, otherwise the
blk_flush_kern_dcache_page() is not called). This patch subtracts
L1_CACHE_BYTES from the end address.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>

authored by Catalin Marinas and committed by Russell King 0d670b41 75f631dc

+2 -1
+2 -1
arch/arm/mm/blockops.c
··· 25 25 { 26 26 asm( 27 27 "add r1, r0, %0 \n\ 28 + sub r1, r1, %1 \n\ 28 29 1: .word 0xec401f0e @ mcrr p15, 0, r0, r1, c14, 0 @ blocking \n\ 29 30 mov r0, #0 \n\ 30 31 mcr p15, 0, r0, c7, c5, 0 \n\ 31 32 mcr p15, 0, r0, c7, c10, 4 \n\ 32 33 mov pc, lr" 33 34 : 34 - : "I" (PAGE_SIZE)); 35 + : "I" (PAGE_SIZE), "I" (L1_CACHE_BYTES)); 35 36 } 36 37 37 38 /*