Re: [PATCH 0/3] ACPI: platform_profile: fix legacy sysfs with multiple handlers

From: Rafael J. Wysocki
Date: Wed Feb 26 2025 - 15:07:00 EST


Top-posting not welcome.

On Wed, Feb 26, 2025 at 8:52 PM Antheas Kapenekakis <lkml@xxxxxxxxxxx> wrote:
> >
> > What about adding "quiet" as a "hidden choice" to amd-pmf such that it
> > would allow the test_bit(*bit, handler->choices) check in
> > _store_class_profile() to pass, but it would not cause this "choice"
> > to become visible in the new I/F (or when amd-pmf becomes the only
> > platform-profile driver) and it would be aliased to "low-power"
> > internally?
>
> This is what this patch series essentially does. It makes amd-pmf
> accept all choices but only show its own in its own handler and when
> it is the only option

No, it does more than this. For instance, it is not necessary to do
anything about PLATFORM_PROFILE_BALANCED_PERFORMANCE in it.

The structure of it is questionable either. It really should be two
patches, one modifying the ACPI platform-profile driver and the other
changing amd-pmf on top of this.

Moreover, I'm not entirely convinced that the "secondary" driver
concept is needed to address the problem at hand.