ARM: 6436/1: AT91: Fix power-saving in idle-mode on 926T processors

According to Atmel, their 926T processors (AT91 post RM9200) requires
'Wait for Interrupt' mode be entered right after disabling the processor clock
in order to minimise current consumption when idle, so do both provided we're
not running on a 920T (an RM9200).

Furthermore, get rid of the #ifndef CONFIG_DEBUG_KERNEL, since arch_idle()
can be turned off completely with the kernel parameter 'nohlt'.

Cc: Andrew Victor <avictor.za@gmail.com>
Signed-off-by: Anders Larsen <al@alarsen.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>

authored by Anders Larsen and committed by Russell King 5c189208 cdaf9a2f

+3 -4
+3 -4
arch/arm/mach-at91/include/mach/system.h
··· 28 29 static inline void arch_idle(void) 30 { 31 - #ifndef CONFIG_DEBUG_KERNEL 32 /* 33 * Disable the processor clock. The processor will be automatically 34 * re-enabled by an interrupt or by a reset. 35 */ 36 at91_sys_write(AT91_PMC_SCDR, AT91_PMC_PCK); 37 - #else 38 /* 39 * Set the processor (CP15) into 'Wait for Interrupt' mode. 40 - * Unlike disabling the processor clock via the PMC (above) 41 - * this allows the processor to be woken via JTAG. 42 */ 43 cpu_do_idle(); 44 #endif
··· 28 29 static inline void arch_idle(void) 30 { 31 /* 32 * Disable the processor clock. The processor will be automatically 33 * re-enabled by an interrupt or by a reset. 34 */ 35 at91_sys_write(AT91_PMC_SCDR, AT91_PMC_PCK); 36 + #ifndef CONFIG_CPU_ARM920T 37 /* 38 * Set the processor (CP15) into 'Wait for Interrupt' mode. 39 + * Post-RM9200 processors need this in conjunction with the above 40 + * to save power when idle. 41 */ 42 cpu_do_idle(); 43 #endif