Bug 697273 - Unable to set ondemand governor on Atom-based server
Unable to set ondemand governor on Atom-based server
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: powertop (Show other bugs)
6.0
Unspecified Unspecified
low Severity low
: rc
: ---
Assigned To: Jaroslav Škarvada
Jeff Bastian
: Patch
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2011-04-17 08:04 EDT by Lukas Zapletal
Modified: 2014-01-30 04:21 EST (History)
7 users (show)

See Also:
Fixed In Version: powertop-2.3-1.el6
Doc Type: Bug Fix
Doc Text:
Cause: The upstream code doesn't take into account whether the ondemand governor is usable on the platform. Consequence: The powertop could suggest ondemand governor even if it is not possible to use it on the platform. Fix: The code was patched and two checks were added. The ondemand governor is additionally not suggested if it is not in the list of available governors (this means there is no kernel support - the driver is either not compiled for the kernel or there is no implementation for the platform) or if the CPU transition time from one frequency to another is above the maximal limit allowed by the ondemand governor. Result: The ondemand governor is no longer suggested in the tuning suggestions if it cannot be activated on the current kernel / HW.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-11-21 02:52:40 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Proposed patch (1.32 KB, patch)
2011-04-18 05:48 EDT, Jaroslav Škarvada
no flags Details | Diff
powertop-2.X: proposed fix (1.24 KB, patch)
2013-06-28 08:20 EDT, Jaroslav Škarvada
no flags Details | Diff

  None (edit)
Description Lukas Zapletal 2011-04-17 08:04:27 EDT
Description of problem:

Hello, got a Atom-based server disc array and there's a problewm when setting ondemand or conservative governor. 

Version-Release number of selected component (if applicable):

Red Hat Enterprise Linux Server release 6.0 (Santiago)

Intel(R) Atom(TM) CPU D410   @ 1.66GHz

Linux box 2.6.32-71.18.2.el6.i686 #1 SMP Wed Mar 2 14:38:52 EST 2011 i686 i686 i386 GNU/Linux

tried also on 2.6.32-71.24.1.el6

How reproducible:

echo ondemand > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

Actual results:

# dmesg
ondemand governor failed, too long transition latency of HW, fallback to performance governor

Additional info:

Not a fatal error. Low prio.
Comment 3 Jaroslav Škarvada 2011-04-17 17:28:05 EDT
This CPU seems not to have the Enhanced Intel SpeedStep (http://ark.intel.com/Product.aspx?id=43517), thus the kernel is probably right because the high transition latency can affect the CPU performance under ondemand governor. AFAIK you should be able to use the userspace governor and control the frequencies by hand or by user space daemon.
Comment 4 Jaroslav Škarvada 2011-04-17 17:45:32 EDT
Please, what is your:
# cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors
# cat /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_transition_latency

The PowerTOP could be patched not to suggest ondemand in such cases.
Comment 5 RHEL Product and Program Management 2011-04-18 02:00:11 EDT
Since RHEL 6.1 External Beta has begun, and this bug remains
unresolved, it has been rejected as it is not proposed as
exception or blocker.

Red Hat invites you to ask your support representative to
propose this request, if appropriate and relevant, in the
next release of Red Hat Enterprise Linux.
Comment 6 Lukas Zapletal 2011-04-18 03:25:19 EDT
@Jaroslav:

Which userspace daemon should I use then?

Here is the output:

[root@xxx ~]# cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors 
ondemand conservative userspace performance 

[root@xxx ~]# cat /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_transition_latency 
10000001


[root@box ~]# cat /proc/cpuinfo 
processor	: 0
vendor_id	: GenuineIntel
cpu family	: 6
model		: 28
model name	: Intel(R) Atom(TM) CPU D410   @ 1.66GHz
stepping	: 10
cpu MHz		: 1666.670
cache size	: 512 KB
physical id	: 0
siblings	: 2
core id		: 0
cpu cores	: 1
apicid		: 0
initial apicid	: 0
fdiv_bug	: no
hlt_bug		: no
f00f_bug	: no
coma_bug	: no
fpu		: yes
fpu_exception	: yes
cpuid level	: 10
wp		: yes
flags		: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe nx lm constant_tsc arch_perfmon pebs bts aperfmperf pni dtes64 monitor ds_cpl tm2 ssse3 cx16 xtpr pdcm movbe lahf_lm
bogomips	: 3332.96
clflush size	: 64
cache_alignment	: 64
address sizes	: 36 bits physical, 48 bits virtual
power management:

processor	: 1
vendor_id	: GenuineIntel
cpu family	: 6
model		: 28
model name	: Intel(R) Atom(TM) CPU D410   @ 1.66GHz
stepping	: 10
cpu MHz		: 1666.670
cache size	: 512 KB
physical id	: 0
siblings	: 2
core id		: 0
cpu cores	: 1
apicid		: 1
initial apicid	: 1
fdiv_bug	: no
hlt_bug		: no
f00f_bug	: no
coma_bug	: no
fpu		: yes
fpu_exception	: yes
cpuid level	: 10
wp		: yes
flags		: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe nx lm constant_tsc arch_perfmon pebs bts aperfmperf pni dtes64 monitor ds_cpl tm2 ssse3 cx16 xtpr pdcm movbe lahf_lm
bogomips	: 3332.83
clflush size	: 64
cache_alignment	: 64
address sizes	: 36 bits physical, 48 bits virtual
power management:

Thanks for helping me out.
Comment 7 Jaroslav Škarvada 2011-04-18 05:48:40 EDT
Created attachment 492841 [details]
Proposed patch

With the attached patch it shouldn't suggest ondemand governor if it is not supported or the cpu transition latency is higher than the ondemand governor max_transition_latency (10ms).

Please test this patch, the experimental build with this patch applied:
https://brewweb.devel.redhat.com/taskinfo?taskID=3264418

For cpufreq switching on your system you can use e.g. cpuspeed daemon:
# yum install cpuspeed
# chkconfig cpuspeed on
And change your default governor in /etc/sysconfig/cpuspeed to:
GOVERNOR=userspace
Comment 8 Lukas Zapletal 2011-04-18 08:00:54 EDT
I just installed i686 version of your RPM and I can confirm this helped.

Your patch works just great.

ps - the cpuspeed runs fine too

Many thanks :-)
Comment 17 Jaroslav Škarvada 2013-06-28 08:20:45 EDT
Created attachment 766551 [details]
powertop-2.X: proposed fix

It doesn't seem to be fixed in powertop-2.X. Proposed fix sent upstream.
Comment 21 Lukas Zapletal 2013-07-04 12:25:55 EDT
I can confirm it does work now, although I see some floods with this message over powertop screen sometimes:

timer_expire_entry event returned no function value?

This is another story, perhaps. Thanks for help! :-D
Comment 22 Jaroslav Škarvada 2013-07-04 18:11:41 EDT
(In reply to Lukas Zapletal from comment #21)
> I can confirm it does work now, although I see some floods with this message
> over powertop screen sometimes:
> 
> timer_expire_entry event returned no function value?
> 
> This is another story, perhaps. Thanks for help! :-D

Thanks for testing. You need updated kernel, this is tracked by bug 881030.
Comment 24 errata-xmlrpc 2013-11-21 02:52:40 EST
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2013-1575.html

Note You need to log in before you can comment on or make changes to this bug.