Skip to contentSkip to conversation

PATCH Vineet Gupta 1 participant 1 message Mar 7, 2014 Synopsys ARC architecture

lore
Share & tools
lore
#0 lore raw

Hi Linus,

This patch fixes a subtle issue with cache flush which could potentially cause random userspace crashes because of stale icache lines.

Please apply for 3.14, it's marked for stable as well.

Thx,
-Vineet

-------------->8------------

Quoted 1 line

From 036837642ed6df39f6a063ad10327787b60d4a0f Mon Sep 17 00:00:00 2001

From: Vineet Gupta <[email protected]>
Date: Fri, 7 Mar 2014 13:22:22 +0530
Subject: [PATCH] ARC: Use correct PTAG register for icache flush

This error crept in when consolidating the cache flush code

Fixes bd12976c3664 (ARC: cacheflush refactor #3: Unify the {d,i}cache)
---
 arch/arc/mm/cache_arc700.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
arch/arc/mm/cache_arc700.c +2 -2
index 6b58c1de7577..400c663b21c2 100644
@@ -282,7 +282,7 @@ static inline void __cache_line_loop(unsigned long paddr, unsigned long vaddr,
 #else
 	/* if V-P const for loop, PTAG can be written once outside loop */
 	if (full_page_op)
-		write_aux_reg(ARC_REG_DC_PTAG, paddr);
+		write_aux_reg(aux_tag, paddr);
 #endif
 
 	while (num_lines-- > 0) {
@@ -296,7 +296,7 @@ static inline void __cache_line_loop(unsigned long paddr, unsigned long vaddr,
 		write_aux_reg(aux_cmd, vaddr);
 		vaddr += L1_CACHE_BYTES;
 #else
-		write_aux_reg(aux, paddr);
+		write_aux_reg(aux_cmd, paddr);
 		paddr += L1_CACHE_BYTES;
 #endif
 	}
Signature · 1 line
1.8.3.2