diff mbox

[v2] ARM: Define wfi() macro for v6 processors

Message ID 1297162885-2975-1-git-send-email-dave.martin@linaro.org (mailing list archive)
State Superseded
Delegated to: Kevin Hilman
Headers show

Commit Message

tip-bot for Dave Martin Feb. 8, 2011, 11:01 a.m. UTC
None
diff mbox

Patch

diff --git a/arch/arm/include/asm/system.h b/arch/arm/include/asm/system.h
index 97f6d60..f39cf09 100644
--- a/arch/arm/include/asm/system.h
+++ b/arch/arm/include/asm/system.h
@@ -129,6 +129,9 @@  extern unsigned int user_debug;
 #define sev()	__asm__ __volatile__ ("sev" : : : "memory")
 #define wfe()	__asm__ __volatile__ ("wfe" : : : "memory")
 #define wfi()	__asm__ __volatile__ ("wfi" : : : "memory")
+#elif __LINUX_ARM_ARCH__ == 6
+#define wfi() __asm__ __volatile__ ("mcr p15, 0, %0, c7, c0, 4" \
+				    : : "r" (0) : "memory")
 #endif
 
 #if __LINUX_ARM_ARCH__ >= 7