Commit 878a23b1 authored by Dave Jones's avatar Dave Jones Committed by Dave Jones

[CPUFREQ] Disable smi_detect_freqs() call on systems which do not support it [BUG #1422]

Dominik Brodowski.
parent a0e211b5
......@@ -85,6 +85,9 @@ static int speedstep_smi_ownership (void)
/**
* speedstep_smi_get_freqs - get SpeedStep preferred & current freq.
* Only available on later SpeedStep-enabled systems, returns false results or
* even hangs [cf. bugme.osdl.org # 1422] on earlier systems. Empirical testing
* shows that the latter occurs if !(ist_info.event & 0xFFFF).
*
*/
static int speedstep_smi_get_freqs (unsigned int *low, unsigned int *high)
......@@ -93,6 +96,9 @@ static int speedstep_smi_get_freqs (unsigned int *low, unsigned int *high)
u32 state=0;
u32 function = GET_SPEEDSTEP_FREQS;
if (!(ist_info.event & 0xFFFF))
return -ENODEV;
command = (smi_sig & 0xffffff00) | (smi_cmd & 0xff);
__asm__ __volatile__("movl $0, %%edi\n"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment