Comment 7 for bug 1928183

Revision history for this message
Po-Hsu Lin (cypressyew) wrote :

Hi David,

I found a laptop with AMD Ryzen 5 APU and gave it a try, before this patch turbostat will terminate with return code 243:

Welcome to Ubuntu Impish Indri (development branch) (GNU/Linux 5.11.0-16-generic x86_64)
$ sudo turbostat
turbostat version 20.09.30 - Len Brown <email address hidden>
CPUID(0): AuthenticAMD 0x10 CPUID levels; 0x80000020 xlevels; family:model:stepping 0x17:60:1 (23:96:1)
CPUID(1): SSE3 MONITOR - - - TSC MSR - HT -
CPUID(6): APERF, No-TURBO, No-DTS, No-PTM, No-HWP, No-HWPnotify, No-HWPwindow, No-HWPepp, No-HWPpkg, No-EPB
CPUID(7): No-SGX
RAPL: 234 sec. Joule Counter Range, at 280 Watts
/dev/cpu_dma_latency: 2000000000 usec (default)
current_driver: acpi_idle
current_governor: menu
current_governor_ro: menu
cpu4: POLL: CPUIDLE CORE POLL IDLE
cpu4: C1: ACPI FFH MWAIT 0x0
cpu4: C2: ACPI IOPORT 0x414
cpu4: C3: ACPI IOPORT 0x415
cpu4: cpufreq driver: acpi-cpufreq
cpu4: cpufreq governor: schedutil
cpufreq boost: 1
cpu0: MSR_RAPL_PWR_UNIT: 0x000a1003 (0.125000 Watts, 0.000015 Joules, 0.000977 sec.)
$ echo $?
243

After installing debs from https://people.canonical.com/~phlin/kernel/lp-1928183-turbostat-cezanne/ and reboot to 5.11.0-18, the turbostat command seems to be working (not terminate early with 243):
$ sudo turbostat
turbostat version 20.09.30 - Len Brown <email address hidden>
CPUID(0): AuthenticAMD 0x10 CPUID levels; 0x80000020 xlevels; family:model:stepping 0x17:60:1 (23:96:1)
CPUID(1): SSE3 MONITOR - - - TSC MSR - HT -
CPUID(6): APERF, No-TURBO, No-DTS, No-PTM, No-HWP, No-HWPnotify, No-HWPwindow, No-HWPepp, No-HWPpkg, No-EPB
CPUID(7): No-SGX
RAPL: 234 sec. Joule Counter Range, at 280 Watts
/dev/cpu_dma_latency: 2000000000 usec (default)
current_driver: acpi_idle
current_governor: menu
current_governor_ro: menu
cpu4: POLL: CPUIDLE CORE POLL IDLE
cpu4: C1: ACPI FFH MWAIT 0x0
cpu4: C2: ACPI IOPORT 0x414
cpu4: C3: ACPI IOPORT 0x415
cpu4: cpufreq driver: acpi-cpufreq
cpu4: cpufreq governor: schedutil
cpufreq boost: 1
cpu0: MSR_RAPL_PWR_UNIT: 0x000a1003 (0.125000 Watts, 0.000015 Joules, 0.000977 sec.)
Core CPU Avg_MHz Busy% Bzy_MHz TSC_MHz IRQ POLL C1 C2 C3 POLL% C1% C2% C3% CorWatt PkgWatt
- - 2 0.08 1920 3716 542 22 67 0 457 0.00 0.06 0.00 99.81 0.01 3.66
0 0 2 0.10 1873 3717 50 0 3 0 48 0.00 0.04 0.00 99.84 0.00 3.66
0 1 0 0.03 1860 3717 15 0 0 0 15 0.00 0.00 0.00 99.93
1 2 1 0.04 2759 3717 28 0 2 0 26 0.00 0.01 0.00 99.91 0.00
1 3 0 0.02 2636 3717 12 1 1 0 10 0.00 0.01 0.00 99.93
2 4 1 0.02 3079 3717 22 1 6 0 15 0.00 0.01 0.00 99.92 0.00
2 5 1 0.04 2790 3717 30 0 13 0 20 0.00 0.37 0.00 99.55
4 6 2 0.14 1738 3717 74 4 12 0 60 0.00 0.07 0.00 99.79 0.00
4 7 2 0.10 1747 3717 48 4 9 0 35 0.02 0.05 0.00 99.82
5 8 1 0.04 2305 3717 19 0 0 0 19 0.00 0.00 0.00 99.93 0.00
5 9 2 0.09 1876 3717 46 3 5 0 38 0.00 0.04 0.00 99.84
6 10 2 0.09 2114 3717 50 4 7 0 39 0.02 0.07 0.00 99.81 0.00
6 11 5 0.31 1657 3717 148 5 9 0 132 0.01 0.08 0.00 99.65