* [Bug 219332] New: /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy
@ 2024-09-29 13:13 bugzilla-daemon
2024-09-29 13:14 ` [Bug 219332] " bugzilla-daemon
` (10 more replies)
0 siblings, 11 replies; 12+ messages in thread
From: bugzilla-daemon @ 2024-09-29 13:13 UTC (permalink / raw)
To: linux-pm
https://bugzilla.kernel.org/show_bug.cgi?id=219332
Bug ID: 219332
Summary: /sys/devices/system/cpu/cpufreq/policy0/energy_perform
ance_preference: Device or resource busy
Product: Power Management
Version: 2.5
Hardware: AMD
OS: Linux
Status: NEW
Severity: high
Priority: P3
Component: cpufreq
Assignee: linux-pm@vger.kernel.org
Reporter: aros@gmx.com
Regression: No
Created attachment 306935
--> https://bugzilla.kernel.org/attachment.cgi?id=306935&action=edit
A dump of /sys/devices/system/cpu
I've played with various tee: /sys/devices/system/cpu/cpufreq/policy0/* options
and now on Linux 6.11 and Ryzen 7 5800X I'm getting this:
perfbias.sh power
Now: performance
Switching to: power
tee: /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference:
Device or resource busy
tee: /sys/devices/system/cpu/cpufreq/policy10/energy_performance_preference:
Device or resource busy
tee: /sys/devices/system/cpu/cpufreq/policy11/energy_performance_preference:
Device or resource busy
tee: /sys/devices/system/cpu/cpufreq/policy12/energy_performance_preference:
Device or resource busy
tee: /sys/devices/system/cpu/cpufreq/policy13/energy_performance_preference:
Device or resource busy
tee: /sys/devices/system/cpu/cpufreq/policy14/energy_performance_preference:
Device or resource busy
tee: /sys/devices/system/cpu/cpufreq/policy15/energy_performance_preference:
Device or resource busy
tee: /sys/devices/system/cpu/cpufreq/policy1/energy_performance_preference:
Device or resource busy
tee: /sys/devices/system/cpu/cpufreq/policy2/energy_performance_preference:
Device or resource busy
tee: /sys/devices/system/cpu/cpufreq/policy3/energy_performance_preference:
Device or resource busy
tee: /sys/devices/system/cpu/cpufreq/policy4/energy_performance_preference:
Device or resource busy
tee: /sys/devices/system/cpu/cpufreq/policy5/energy_performance_preference:
Device or resource busy
tee: /sys/devices/system/cpu/cpufreq/policy6/energy_performance_preference:
Device or resource busy
tee: /sys/devices/system/cpu/cpufreq/policy7/energy_performance_preference:
Device or resource busy
tee: /sys/devices/system/cpu/cpufreq/policy8/energy_performance_preference:
Device or resource busy
tee: /sys/devices/system/cpu/cpufreq/policy9/energy_performance_preference:
Device or resource busy
Result: performance
This doesn't seem right.
--
You may reply to this email to add a comment.
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug 219332] /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy
2024-09-29 13:13 [Bug 219332] New: /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy bugzilla-daemon
@ 2024-09-29 13:14 ` bugzilla-daemon
2024-09-29 13:24 ` bugzilla-daemon
` (9 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: bugzilla-daemon @ 2024-09-29 13:14 UTC (permalink / raw)
To: linux-pm
https://bugzilla.kernel.org/show_bug.cgi?id=219332
--- Comment #1 from Artem S. Tashkinov (aros@gmx.com) ---
Created attachment 306936
--> https://bugzilla.kernel.org/attachment.cgi?id=306936&action=edit
perfbias.sh
--
You may reply to this email to add a comment.
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug 219332] /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy
2024-09-29 13:13 [Bug 219332] New: /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy bugzilla-daemon
2024-09-29 13:14 ` [Bug 219332] " bugzilla-daemon
@ 2024-09-29 13:24 ` bugzilla-daemon
2024-09-29 13:50 ` bugzilla-daemon
` (8 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: bugzilla-daemon @ 2024-09-29 13:24 UTC (permalink / raw)
To: linux-pm
https://bugzilla.kernel.org/show_bug.cgi?id=219332
--- Comment #2 from Artem S. Tashkinov (aros@gmx.com) ---
What I also do NOT like at all, is that in Linux 6.11 amd-pstate gets loaded by
default and there is no information about that in dmesg.
Please kprint() that amd-pstate has been loaded and is active.
Thank you.
--
You may reply to this email to add a comment.
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug 219332] /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy
2024-09-29 13:13 [Bug 219332] New: /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy bugzilla-daemon
2024-09-29 13:14 ` [Bug 219332] " bugzilla-daemon
2024-09-29 13:24 ` bugzilla-daemon
@ 2024-09-29 13:50 ` bugzilla-daemon
2024-09-29 19:18 ` bugzilla-daemon
` (7 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: bugzilla-daemon @ 2024-09-29 13:50 UTC (permalink / raw)
To: linux-pm
https://bugzilla.kernel.org/show_bug.cgi?id=219332
--- Comment #3 from Artem S. Tashkinov (aros@gmx.com) ---
Lastly,
https://docs.kernel.org/admin-guide/pm/amd-pstate.html
Doesn't specify how the driver can be completely disabled.
I'm now using initcall_blacklist=amd_pstate_init amd_pstate.enable=0 but I'm
not sure if that's correct.
--
You may reply to this email to add a comment.
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug 219332] /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy
2024-09-29 13:13 [Bug 219332] New: /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy bugzilla-daemon
` (2 preceding siblings ...)
2024-09-29 13:50 ` bugzilla-daemon
@ 2024-09-29 19:18 ` bugzilla-daemon
2024-09-29 19:29 ` bugzilla-daemon
` (6 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: bugzilla-daemon @ 2024-09-29 19:18 UTC (permalink / raw)
To: linux-pm
https://bugzilla.kernel.org/show_bug.cgi?id=219332
--- Comment #4 from Mario Limonciello (AMD) (mario.limonciello@amd.com) ---
[laugh] Limonciello, Mario reacted to your message:
________________________________
From: bugzilla-daemon@kernel.org <bugzilla-daemon@kernel.org>
Sent: Sunday, September 29, 2024 1:50:50 PM
To: Limonciello, Mario <Mario.Limonciello@amd.com>
Subject: [Bug 219332]
/sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device
or resource busy
https://bugzilla.kernel.org/show_bug.cgi?id=219332
--- Comment #3 from Artem S. Tashkinov (aros@gmx.com) ---
Lastly,
https://docs.kernel.org/admin-guide/pm/amd-pstate.html
Doesn't specify how the driver can be completely disabled.
I'm now using initcall_blacklist=amd_pstate_init amd_pstate.enable=0 but I'm
not sure if that's correct.
--
You may reply to this email to add a comment.
You are receiving this mail because:
You are on the CC list for the bug.
--
You may reply to this email to add a comment.
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug 219332] /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy
2024-09-29 13:13 [Bug 219332] New: /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy bugzilla-daemon
` (3 preceding siblings ...)
2024-09-29 19:18 ` bugzilla-daemon
@ 2024-09-29 19:29 ` bugzilla-daemon
2024-09-30 5:53 ` bugzilla-daemon
` (5 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: bugzilla-daemon @ 2024-09-29 19:29 UTC (permalink / raw)
To: linux-pm
https://bugzilla.kernel.org/show_bug.cgi?id=219332
--- Comment #5 from Mario Limonciello (AMD) (mario.limonciello@amd.com) ---
Can you please provide a kernel log with dynamic debugging turned on for
drivers/cpufreq/amd-pstate.c so I can understand what it is doing with your
hardware?
Just a guess with no messages but it's very possible that because 6.11 doesn't
have c3e093efbc6cac7bf9dc531dcb751b86daaa65b0 an error is being masked.
Perhaps you can try to add that commit and see if it changes?
--
You may reply to this email to add a comment.
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug 219332] /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy
2024-09-29 13:13 [Bug 219332] New: /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy bugzilla-daemon
` (4 preceding siblings ...)
2024-09-29 19:29 ` bugzilla-daemon
@ 2024-09-30 5:53 ` bugzilla-daemon
2024-09-30 13:28 ` bugzilla-daemon
` (4 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: bugzilla-daemon @ 2024-09-30 5:53 UTC (permalink / raw)
To: linux-pm
https://bugzilla.kernel.org/show_bug.cgi?id=219332
Dhananjay Ugwekar (AMD) (Dhananjay.Ugwekar@amd.com) changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |Dhananjay.Ugwekar@amd.com
--- Comment #6 from Dhananjay Ugwekar (AMD) (Dhananjay.Ugwekar@amd.com) ---
(In reply to Artem S. Tashkinov from comment #0)
> Created attachment 306935 [details]
> A dump of /sys/devices/system/cpu
>
> I've played with various tee: /sys/devices/system/cpu/cpufreq/policy0/*
> options and now on Linux 6.11 and Ryzen 7 5800X I'm getting this:
>
> perfbias.sh power
> Now: performance
> Switching to: power
> tee: /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference:
> Device or resource busy
> tee: /sys/devices/system/cpu/cpufreq/policy10/energy_performance_preference:
> Device or resource busy
> tee: /sys/devices/system/cpu/cpufreq/policy11/energy_performance_preference:
> Device or resource busy
> tee: /sys/devices/system/cpu/cpufreq/policy12/energy_performance_preference:
> Device or resource busy
> tee: /sys/devices/system/cpu/cpufreq/policy13/energy_performance_preference:
> Device or resource busy
> tee: /sys/devices/system/cpu/cpufreq/policy14/energy_performance_preference:
> Device or resource busy
> tee: /sys/devices/system/cpu/cpufreq/policy15/energy_performance_preference:
> Device or resource busy
> tee: /sys/devices/system/cpu/cpufreq/policy1/energy_performance_preference:
> Device or resource busy
> tee: /sys/devices/system/cpu/cpufreq/policy2/energy_performance_preference:
> Device or resource busy
> tee: /sys/devices/system/cpu/cpufreq/policy3/energy_performance_preference:
> Device or resource busy
> tee: /sys/devices/system/cpu/cpufreq/policy4/energy_performance_preference:
> Device or resource busy
> tee: /sys/devices/system/cpu/cpufreq/policy5/energy_performance_preference:
> Device or resource busy
> tee: /sys/devices/system/cpu/cpufreq/policy6/energy_performance_preference:
> Device or resource busy
> tee: /sys/devices/system/cpu/cpufreq/policy7/energy_performance_preference:
> Device or resource busy
> tee: /sys/devices/system/cpu/cpufreq/policy8/energy_performance_preference:
> Device or resource busy
> tee: /sys/devices/system/cpu/cpufreq/policy9/energy_performance_preference:
> Device or resource busy
> Result: performance
>
> This doesn't seem right.
I see from the attachment that you are using performance governor, so you are
limited to only performance EPP hint, trying to write other EPP hints
(power/balance_power/balance_performance) will show the above error.
You'll need to change to powersave governor to use these hints. Please let me
know if this fixes your issue.
--
You may reply to this email to add a comment.
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug 219332] /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy
2024-09-29 13:13 [Bug 219332] New: /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy bugzilla-daemon
` (5 preceding siblings ...)
2024-09-30 5:53 ` bugzilla-daemon
@ 2024-09-30 13:28 ` bugzilla-daemon
2024-09-30 15:50 ` bugzilla-daemon
` (3 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: bugzilla-daemon @ 2024-09-30 13:28 UTC (permalink / raw)
To: linux-pm
https://bugzilla.kernel.org/show_bug.cgi?id=219332
--- Comment #7 from Artem S. Tashkinov (aros@gmx.com) ---
(In reply to Dhananjay Ugwekar (AMD) from comment #6)
>
> I see from the attachment that you are using performance governor, so you
> are limited to only performance EPP hint, trying to write other EPP hints
> (power/balance_power/balance_performance) will show the above error.
>
> You'll need to change to powersave governor to use these hints. Please let
> me know if this fixes your issue.
That's indeed the case and changing the CPU frequency governor to "powersave"
has fixed the issue but I wonder if you could log an error message in dmesg if
the governor is incompatible with what the user has requested.
It still makes my head hurt trying to understand the interaction between
classic CPU governors and energy_performance_preference modes.
From the testing I've done it looks like classic CPU governors are 100%
useless/have zero effect in the presence of amd-pstate in which case I don't
understand why they are exposed/exist in the first place. Is it possible to
hide them? Make them read only? Just to avoid further useless bug reports.
--
You may reply to this email to add a comment.
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug 219332] /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy
2024-09-29 13:13 [Bug 219332] New: /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy bugzilla-daemon
` (6 preceding siblings ...)
2024-09-30 13:28 ` bugzilla-daemon
@ 2024-09-30 15:50 ` bugzilla-daemon
2024-09-30 16:11 ` bugzilla-daemon
` (2 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: bugzilla-daemon @ 2024-09-30 15:50 UTC (permalink / raw)
To: linux-pm
https://bugzilla.kernel.org/show_bug.cgi?id=219332
--- Comment #8 from Dhananjay Ugwekar (AMD) (Dhananjay.Ugwekar@amd.com) ---
(In reply to Artem S. Tashkinov from comment #7)
> (In reply to Dhananjay Ugwekar (AMD) from comment #6)
> >
> > I see from the attachment that you are using performance governor, so you
> > are limited to only performance EPP hint, trying to write other EPP hints
> > (power/balance_power/balance_performance) will show the above error.
> >
> > You'll need to change to powersave governor to use these hints. Please let
> > me know if this fixes your issue.
>
> That's indeed the case and changing the CPU frequency governor to
> "powersave" has fixed the issue but I wonder if you could log an error
> message in dmesg if the governor is incompatible with what the user has
> requested.
Right, this will be helpful, will put out a patch for this. Also there is an
"energy_performance_available_preferences" file which shows the allowed EPP
hints that can be written to the "energy_performance_preference" sysfs file,
you could incorporate that into your shell script.
>
> It still makes my head hurt trying to understand the interaction between
> classic CPU governors and energy_performance_preference modes.
>
> From the testing I've done it looks like classic CPU governors are 100%
> useless/have zero effect in the presence of amd-pstate
I guess you are using amd_pstate=active, in which only performance and
powersave governors are supported and the decision making is mostly in the
hands of platform firmware.
However, if you use amd_pstate=passive mode, the OS governors (schedutil,
conservative, etc) are responsible for making the frequency decisions.
in which case I don't
> understand why they are exposed/exist in the first place.
Didnt understand this part, in which scenario were you able to see the
governors, but they were ineffective?
Is it possible to
> hide them? Make them read only? Just to avoid further useless bug reports.
--
You may reply to this email to add a comment.
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug 219332] /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy
2024-09-29 13:13 [Bug 219332] New: /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy bugzilla-daemon
` (7 preceding siblings ...)
2024-09-30 15:50 ` bugzilla-daemon
@ 2024-09-30 16:11 ` bugzilla-daemon
2024-09-30 17:04 ` bugzilla-daemon
2024-09-30 17:15 ` bugzilla-daemon
10 siblings, 0 replies; 12+ messages in thread
From: bugzilla-daemon @ 2024-09-30 16:11 UTC (permalink / raw)
To: linux-pm
https://bugzilla.kernel.org/show_bug.cgi?id=219332
--- Comment #9 from Mario Limonciello (AMD) (mario.limonciello@amd.com) ---
> Didnt understand this part, in which scenario were you able to see the
> governors, but they were ineffective?
I'm confused by this too.
$ cat /sys/devices/system/cpu/cpufreq/policy0/scaling_driver
amd-pstate-epp
$ cat /sys/devices/system/cpu/cpufreq/policy0/scaling_available_governors
performance powersave
$ cat /sys/devices/system/cpu/cpufreq/policy0/scaling_governor
powersave
I don't see any others exposed in active mode.
--
You may reply to this email to add a comment.
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug 219332] /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy
2024-09-29 13:13 [Bug 219332] New: /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy bugzilla-daemon
` (8 preceding siblings ...)
2024-09-30 16:11 ` bugzilla-daemon
@ 2024-09-30 17:04 ` bugzilla-daemon
2024-09-30 17:15 ` bugzilla-daemon
10 siblings, 0 replies; 12+ messages in thread
From: bugzilla-daemon @ 2024-09-30 17:04 UTC (permalink / raw)
To: linux-pm
https://bugzilla.kernel.org/show_bug.cgi?id=219332
Artem S. Tashkinov (aros@gmx.com) changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution|--- |ANSWERED
--- Comment #10 from Artem S. Tashkinov (aros@gmx.com) ---
When `amd-pstate=active` whatever is written to
`/sys/devices/system/cpu/cpufreq/policy0/scaling_governor` has zero effect on
the CPU behavior/system thermals. That's what I was trying to say.
I wonder if amd-pstate could "simply" hide/disable (i.e. make read-only)
scaling_available_governors AND scaling_governor.
It looks like these two "variables" are remnants of acpi-cpufreq and should
_not_ be exposed when amd-pstate is active.
--
You may reply to this email to add a comment.
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug 219332] /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy
2024-09-29 13:13 [Bug 219332] New: /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy bugzilla-daemon
` (9 preceding siblings ...)
2024-09-30 17:04 ` bugzilla-daemon
@ 2024-09-30 17:15 ` bugzilla-daemon
10 siblings, 0 replies; 12+ messages in thread
From: bugzilla-daemon @ 2024-09-30 17:15 UTC (permalink / raw)
To: linux-pm
https://bugzilla.kernel.org/show_bug.cgi?id=219332
--- Comment #11 from Mario Limonciello (AMD) (mario.limonciello@amd.com) ---
> When `amd-pstate=active` whatever is written to
> `/sys/devices/system/cpu/cpufreq/policy0/scaling_governor` has zero effect on
> the CPU behavior/system thermals. That's what I was trying to say.
I wouldn't say zero effect - it definitely can matter. If you start out in
powersave at a more efficiency biased EPP value then switching to performance
is going to increase power consumption and heat etc.
> I wonder if amd-pstate could "simply" hide/disable (i.e. make read-only)
> scaling_available_governors AND scaling_governor.
Userspace can still change the cpufreq governor from performance to powersave
and vice versa. So it should not go away.
--
You may reply to this email to add a comment.
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2024-09-30 17:15 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-29 13:13 [Bug 219332] New: /sys/devices/system/cpu/cpufreq/policy0/energy_performance_preference: Device or resource busy bugzilla-daemon
2024-09-29 13:14 ` [Bug 219332] " bugzilla-daemon
2024-09-29 13:24 ` bugzilla-daemon
2024-09-29 13:50 ` bugzilla-daemon
2024-09-29 19:18 ` bugzilla-daemon
2024-09-29 19:29 ` bugzilla-daemon
2024-09-30 5:53 ` bugzilla-daemon
2024-09-30 13:28 ` bugzilla-daemon
2024-09-30 15:50 ` bugzilla-daemon
2024-09-30 16:11 ` bugzilla-daemon
2024-09-30 17:04 ` bugzilla-daemon
2024-09-30 17:15 ` bugzilla-daemon
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).