Bug 49971 - no Turbo CORE on AMD C-60
Summary: no Turbo CORE on AMD C-60
Status: ASSIGNED
Alias: None
Product: ACPI
Classification: Unclassified
Component: Config-Processors (show other bugs)
Hardware: x86-64 Linux
: P1 normal
Assignee: herrmann.der.user
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-11-02 09:50 UTC by Jonathan
Modified: 2016-10-17 20:56 UTC (History)
5 users (show)

See Also:
Kernel Version: 3.2.0
Subsystem:
Regression: No
Bisected commit-id:


Attachments
output of "grep . /sys/devices/system/cpu/cpu*/cpufreq/*" (2.03 KB, text/plain)
2012-11-28 20:47 UTC, Jonathan
Details
acpidump (194.67 KB, text/plain)
2013-04-25 04:53 UTC, Jonathan
Details

Description Jonathan 2012-11-02 09:50:50 UTC
The AMD C-60 processor is supposed to overclock itself under high loads to 1.333GHz, but this function does not seem to activate in linux, with a maximum speed of 1GHz available.

See e.g. https://bugs.launchpad.net/ubuntu/+source/linux/+bug/748098/comments/5 and http://de.wikipedia.org/wiki/AMD_Turbo_Core for some additional information.
Comment 1 Zhang Rui 2012-11-28 16:53:10 UTC
please attach the output of "grep . /sys/devices/system/cpu/cpu*/cpufreq/*"
Comment 2 Jonathan 2012-11-28 20:47:03 UTC
Created attachment 87621 [details]
output of "grep . /sys/devices/system/cpu/cpu*/cpufreq/*"
Comment 3 Jonathan 2013-01-30 18:02:47 UTC
I noticed this bug is still marked as NEEDINFO.  If someone can tell me what info is needed, I will do my best to provide it.
Comment 4 Zhang Rui 2013-04-25 02:02:23 UTC
please attach the acpidump output of this laptop.
please build in the acpi processor driver and try boot with "processor.ignore_ppc=1" and see if it helps.
Comment 5 Jonathan 2013-04-25 04:53:47 UTC
Created attachment 99971 [details]
acpidump
Comment 6 Jonathan 2013-04-25 04:56:51 UTC
For building the acpi processor driver, should I compile myself a new kernel from scratch, or is there a simpler way to add that specific driver to my default debian kernel (i.e., without trying to guess at all the options it's compiled with, so I can change *just* that option)?
Comment 7 Jonathan 2013-04-25 05:21:34 UTC
Actually, it looks like I already have the processor module compiled as part of my default kernel.  I passed processor.ignore_ppc=1 to the boot line and I don't notice any change.  By all accounts, the max CPU speed is still 1000MHz.
Comment 8 Jonathan 2013-04-25 05:37:21 UTC
Sorry, I realise passing that to the boot line won't activate the option in a module loaded later.  However, I added the option in a file in /etc/modprobe.d and can confirm that there's no effect.

The contents of /sys/module/processor/parameters are ignore_ppc,ignore_tpc,latency_factor and the output of "cat /sys/devices/system/cpu/cpu*/cpufreq/cpuinfo_max_freq" is 1000000\n1000000.
Comment 9 Zhang Rui 2013-04-25 06:40:58 UTC
please attach the output of
grep . /sys/module/processor/parameters/*
to see if ignore_ppc is set correctly.
Comment 10 Jonathan 2013-04-25 06:44:48 UTC
/sys/module/processor/parameters/ignore_ppc:1
/sys/module/processor/parameters/ignore_tpc:0
/sys/module/processor/parameters/latency_factor:2
Comment 11 Jonathan 2013-10-22 06:08:10 UTC
Is info still needed?
Comment 12 Zhang Rui 2014-06-03 02:53:43 UTC
(In reply to Jonathan from comment #2)
> Created attachment 87621 [details]
> output of "grep . /sys/devices/system/cpu/cpu*/cpufreq/*"

/sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies:1000000 800000 

it seems that the driver only detects two available frequencies.
Comment 13 Zhang Rui 2014-06-03 02:55:49 UTC
re-assign to Andreas Herrmann, the author of powernow_k8 driver.
Comment 14 herrmann.der.user 2014-06-18 16:33:22 UTC
The attribute
/sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies
shows only the frequencies belonging to Pstates that are selectable
by software.

To display the frequency when a core is boosted you have to use
a tool like turbostat.

Example

cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies
3101000 3100000 3000000 2900000 2800000 2700000 2600000 2500000 2300000 2200000 2100000 2000000 1900000 1800000 1700000 1600000

~/projects/repos/linux/tools/power/x86/turbostat$ sudo ./turbostat
    Core     CPU Avg_MHz   %Busy Bzy_MHz TSC_MHz     SMI  CPU%c1 ...
       -       -     488   12.52    3896    3101       0   12.60 ...
       0       0    3894   99.74    3904    3106       0    0.26 ...
       0       4       0    0.00    3474    3100       0  100.00
       1       1       4    0.10    3740    3100       0    0.05 ...
       1       5       0    0.01    3254    3100       0    0.14
       2       2       5    0.12    3752    3100       0    0.07 ...
       2       6       0    0.01    3127    3100       0    0.19
       3       3       1    0.02    3536    3100       0    0.05 ...
       3       7       0    0.01    2789    3100       0    0.06

...

    Core     CPU Avg_MHz   %Busy Bzy_MHz TSC_MHz     SMI  CPU%c1 ...
       -       -       1    0.07    1600    3100       0    0.10
       0       0       0    0.01    1600    3100       0    0.03 ...
       0       4       0    0.01    1600    3100       0    0.03
       1       1       3    0.16    1600    3100       0    0.05 ...
       1       5       0    0.02    1600    3100       0    0.19
       2       2       4    0.25    1600    3100       0    0.07 ...
       2       6       0    0.01    1600    3100       0    0.31
       3       3       1    0.04    1600    3100       0    0.04 ...
       3       7       0    0.02    1599    3100       0    0.07

(That's an example from an Intel box.)
Comment 15 herrmann.der.user 2014-06-18 16:46:13 UTC
And here an example from an AMD system

# pinning some heavy load on CPU0 I always get (as expected) just frequencies
# of the software visible Pstates (provided via ACPI):

$ cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies
2800000 2200000 1500000 800000 

# But turbostat can determine the effective frequency via APERF/MPERF MSRs
# and shows that core 0 is really boosted (3.3 GHz in this example)
$ sudo ./turbostat
cor CPU   GHz  TSC
        2.62 2.81
  0   0 3.30 2.81
  1   1 0.80 2.81
  2   2 0.80 2.81
  3   3 0.80 2.81
  4   4 0.80 2.81
  5   5 0.80 2.81
...
Comment 16 Jonathan 2014-07-07 00:22:04 UTC
I've been having trouble finding where the tool turbostat is available.  Could someone point me in the right direction so I can test it?
Comment 17 Len Brown 2014-10-28 03:47:29 UTC
turbostat is published in the linux kernel source tree under
tools/power/turbosat/
it is also included in a number of distros,
eg. on ubuntu...
sudo apt-get install turbostat
Comment 18 gompa 2015-04-02 07:23:50 UTC
    Core     CPU Avg_MHz Bzy_MHz TSC_MHz   time
       -       -     866     989     998      1**
       0       0     802     981     997      1**
       1       1     930     995     998
    Core     CPU Avg_MHz Bzy_MHz TSC_MHz   time
       -       -     666     959     997      1**
       0       0     587     946     997      1**
       1       1     745     970     998
    Core     CPU Avg_MHz Bzy_MHz TSC_MHz   time
       -       -     868     982     998      1**
       0       0     827     973     998      1**
       1       1     908     990     998
    Core     CPU Avg_MHz Bzy_MHz TSC_MHz   time
       -       -     830     978     997      1**
       0       0     997     997     997      1**
       1       1     663     951     998
    Core     CPU Avg_MHz Bzy_MHz TSC_MHz   time
       -       -     786     976     998      1**
       0       0     853     982     998      1**
       1       1     718     969     998
    Core     CPU Avg_MHz Bzy_MHz TSC_MHz   time
       -       -     832     983     998      1**
       0       0     829     984     998      1**
       1       1     835     982     998
    Core     CPU Avg_MHz Bzy_MHz TSC_MHz   time
       -       -     807     982     997      1**
       0       0     621     958     997      1**
       1       1     993     998     998
Comment 19 gompa 2015-04-02 07:40:26 UTC
this is still the case on 4.0rc6 (and any other kernel)
Comment 20 Sébastien Villemot 2016-10-17 20:56:29 UTC
Bug still present on 4.7.5:

$ sudo ./turbostat
     CPU Avg_MHz   Busy% Bzy_MHz TSC_MHz
       -     154   16.35     945     997
       0     146   15.42     950     997
       1     162   17.29     940     997
     CPU Avg_MHz   Busy% Bzy_MHz TSC_MHz
       -     400   42.12     949     997
       0     417   43.59     956     997
       1     383   40.65     942     997
     CPU Avg_MHz   Busy% Bzy_MHz TSC_MHz
       -     667   66.26    1007     997
       0     725   70.93    1023     997
       1     609   61.59     989     997
     CPU Avg_MHz   Busy% Bzy_MHz TSC_MHz
       -     418   44.07     948     997
       0     452   47.20     957     997
       1     383   40.94     936     997
     CPU Avg_MHz   Busy% Bzy_MHz TSC_MHz
       -     415   43.53     953     997
       0     413   43.50     950     997
       1     416   43.56     956     997
     CPU Avg_MHz   Busy% Bzy_MHz TSC_MHz
       -     617   63.65     969     997
       0     631   64.86     974     997
       1     603   62.44     965     997
     CPU Avg_MHz   Busy% Bzy_MHz TSC_MHz
       -     997   99.97     997     997
       0     997  100.00     997     997
       1     997   99.95     997     997
     CPU Avg_MHz   Busy% Bzy_MHz TSC_MHz
       -     947   95.23     994     997
       0     949   95.51     994     997
       1     944   94.94     994     997

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