From: Mario Limonciello <superm1@kernel.org>
To: "Shyam Sundar S K" <Shyam-sundar.S-k@amd.com>,
"Rafael J . Wysocki" <rafael@kernel.org>,
"Hans de Goede" <hdegoede@redhat.com>,
"Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>,
"Luke D . Jones" <luke@ljones.dev>,
"Mark Pearson" <mpearson-lenovo@squebb.ca>
Cc: platform-driver-x86@vger.kernel.org (open list:AMD PMF DRIVER),
linux-kernel@vger.kernel.org (open list),
linux-acpi@vger.kernel.org (open list:ACPI),
"Derek J . Clark" <derekjohn.clark@gmail.com>,
Antheas Kapenekakis <lkml@antheas.dev>,
me@kylegospodneti.ch, Denis Benato <benato.denis96@gmail.com>,
Mario Limonciello <mario.limonciello@amd.com>
Subject: [PATCH 2/3] platform/x86/amd: pmf: Add 'quiet' to hidden choices
Date: Fri, 28 Feb 2025 11:01:54 -0600 [thread overview]
Message-ID: <20250228170155.2623386-3-superm1@kernel.org> (raw)
In-Reply-To: <20250228170155.2623386-1-superm1@kernel.org>
From: Mario Limonciello <mario.limonciello@amd.com>
When amd-pmf and asus-wmi are both bound no low power option shows
up in sysfs. Add a hidden choice for amd-pmf to support 'quiet' mode
to let both bind.
Fixes: 688834743d67 ("ACPI: platform_profile: Allow multiple handlers")
Suggested-by: Antheas Kapenekakis <lkml@antheas.dev>
Signed-off-by: Mario Limonciello <mario.limonciello@amd.com>
---
Cc: "Luke D. Jones" <luke@ljones.dev>
drivers/platform/x86/amd/pmf/sps.c | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/drivers/platform/x86/amd/pmf/sps.c b/drivers/platform/x86/amd/pmf/sps.c
index e6cf0b22dac33..3a0079c17cb17 100644
--- a/drivers/platform/x86/amd/pmf/sps.c
+++ b/drivers/platform/x86/amd/pmf/sps.c
@@ -303,6 +303,7 @@ int amd_pmf_get_pprof_modes(struct amd_pmf_dev *pmf)
mode = POWER_MODE_BALANCED_POWER;
break;
case PLATFORM_PROFILE_LOW_POWER:
+ case PLATFORM_PROFILE_QUIET:
mode = POWER_MODE_POWER_SAVER;
break;
default:
@@ -387,6 +388,13 @@ static int amd_pmf_profile_set(struct device *dev,
return 0;
}
+static int amd_pmf_hidden_choices(void *drvdata, unsigned long *choices)
+{
+ set_bit(PLATFORM_PROFILE_QUIET, choices);
+
+ return 0;
+}
+
static int amd_pmf_profile_probe(void *drvdata, unsigned long *choices)
{
set_bit(PLATFORM_PROFILE_LOW_POWER, choices);
@@ -398,6 +406,7 @@ static int amd_pmf_profile_probe(void *drvdata, unsigned long *choices)
static const struct platform_profile_ops amd_pmf_profile_ops = {
.probe = amd_pmf_profile_probe,
+ .hidden_choices = amd_pmf_hidden_choices,
.profile_get = amd_pmf_profile_get,
.profile_set = amd_pmf_profile_set,
};
--
2.43.0
next prev parent reply other threads:[~2025-02-28 17:02 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-28 17:01 [PATCH 0/3] Add support for hidden choices to platform_profile Mario Limonciello
2025-02-28 17:01 ` [PATCH 1/3] ACPI: platform_profile: Add support for hidden choices Mario Limonciello
2025-02-28 17:15 ` Antheas Kapenekakis
2025-02-28 22:08 ` Kurt Borja
2025-03-01 3:19 ` Mario Limonciello
2025-03-01 11:06 ` Antheas Kapenekakis
2025-03-01 13:52 ` Mario Limonciello
2025-03-01 14:06 ` Antheas Kapenekakis
2025-03-01 16:03 ` Mario Limonciello
2025-03-01 16:15 ` Antheas Kapenekakis
2025-03-02 3:23 ` Mark Pearson
2025-02-28 17:01 ` Mario Limonciello [this message]
2025-02-28 17:01 ` [PATCH 3/3] platform/x86/amd: pmf: Add balanced-performance to " Mario Limonciello
2025-02-28 19:39 ` [PATCH 0/3] Add support for hidden choices to platform_profile Mark Pearson
2025-02-28 19:44 ` Mario Limonciello
2025-02-28 19:53 ` Antheas Kapenekakis
2025-02-28 19:56 ` Mario Limonciello
2025-02-28 20:03 ` Mark Pearson
2025-02-28 20:38 ` Derek John Clark
2025-03-01 11:09 ` Antheas Kapenekakis
2025-03-01 13:44 ` Mario Limonciello
2025-03-01 13:51 ` Antheas Kapenekakis
2025-03-04 16:22 ` Ilpo Järvinen
2025-03-04 19:59 ` Rafael J. Wysocki
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250228170155.2623386-3-superm1@kernel.org \
--to=superm1@kernel.org \
--cc=Shyam-sundar.S-k@amd.com \
--cc=benato.denis96@gmail.com \
--cc=derekjohn.clark@gmail.com \
--cc=hdegoede@redhat.com \
--cc=ilpo.jarvinen@linux.intel.com \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lkml@antheas.dev \
--cc=luke@ljones.dev \
--cc=mario.limonciello@amd.com \
--cc=me@kylegospodneti.ch \
--cc=mpearson-lenovo@squebb.ca \
--cc=platform-driver-x86@vger.kernel.org \
--cc=rafael@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox