Skip to contentSkip to conversation

MIPS 20Kc and WAIT instruction

DISCUSSION Aurelien Jarno 2 participants 2 messages Jun 11, 2007 – Jun 12, 2007 MIPS

lore
Share & tools
lore
#0 lore raw

Hi all,

The latest kernels from kernel.org or linux-mips.org do not enter low power mode when the CPU is idle on a MIPS 20Kc CPU.

Looking at the code in arch/mips/kernel/cpu-probe.c, the "case" corresponding to the 20Kc CPU is commented out:

case CPU_5KC:
/* case CPU_20KC:*/

        case CPU_24K:

According to the datasheet this CPU supports the WAIT instruction, so I don't really understand why it is disabled in the kernel. Does anybody know why?

Thanks,
Aurelien

Signature · 4 lines
  .''`.  Aurelien Jarno	            | GPG: 1024D/F1BCDB73
 : :' :  Debian developer           | Electrical Engineer
 `. `'   [email protected]         | [email protected]
   `-    people.debian.org/~aurel32 | www.aurel32.net
#1 lore raw
Quoted 6 lines · Aurelien Jarno

The latest kernels from kernel.org or linux-mips.org do not enter low power mode when the CPU is idle on a MIPS 20Kc CPU.

Looking at the code in arch/mips/kernel/cpu-probe.c, the "case" corresponding to the 20Kc CPU is commented out:

Quoted 7 lines

case CPU_5KC:
/* case CPU_20KC:*/

        case CPU_24K:

According to the datasheet this CPU supports the WAIT instruction, so I don't really understand why it is disabled in the kernel. Does anybody know why?

CPU_20KC is MIPS64 so by definition supports a WAIT instruction - even though an implementation would be legal as per architecture spec.

As for why it's commented out, I don't know. The original patch to add support was submitted by Carsten Langgaard ([email protected]) in 2002 and already had the CPU_20KC commented out. As for why one would do something like that - my guess is as good as your's :-) Trying to find out more.

Ralf