瀏覽代碼

sparc32, leon: Require separate snoop tags set to regard snooping to be enabled

Even if data snooping is enabled, without separate snoop tags snooping will not
work when the MMU is enabled.

Signed-off-by: Andreas Larsson <andreas@gaisler.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Andreas Larsson 12 年之前
父節點
當前提交
e8e2bfd103
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      arch/sparc/include/asm/leon.h

+ 1 - 1
arch/sparc/include/asm/leon.h

@@ -108,7 +108,7 @@ static inline int sparc_leon3_snooping_enabled(void)
 {
 	u32 cctrl;
 	__asm__ __volatile__("lda [%%g0] 2, %0\n\t" : "=r"(cctrl));
-        return (cctrl >> 23) & 1;
+	return ((cctrl >> 23) & 1) && ((cctrl >> 17) & 1);
 };
 
 static inline void sparc_leon3_disable_cache(void)