Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

platform/x86/amd/pmf: Added a module parameter to disable the Smart PC function

Addresses a low power limits issue on HP ZBook Ultra G1a.

If vendor firmware capped APU power limits with 3rd-party AC adapters,
the user can disable the Smart PC function via the module parameter

Link: https://gitlab.freedesktop.org/drm/amd/-/issues/4868 [1]
Signed-off-by: Alexey Zagorodnikov <xglooom@gmail.com>
Reviewed-by: Mario Limonciello (AMD) <superm1@kernel.org>
Link: https://patch.msgid.link/20260121143519.12318-1-xglooom@gmail.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>

authored by

Alexey Zagorodnikov and committed by
Ilpo Järvinen
8164a14b 7c9aa38a

+13 -5
+13 -5
drivers/platform/x86/amd/pmf/core.c
··· 57 57 module_param(force_load, bool, 0444); 58 58 MODULE_PARM_DESC(force_load, "Force load this driver on supported older platforms (experimental)"); 59 59 60 + static bool smart_pc_support = true; 61 + module_param(smart_pc_support, bool, 0444); 62 + MODULE_PARM_DESC(smart_pc_support, "Smart PC Support (default = true)"); 63 + 60 64 static struct device *pmf_device; 61 65 62 66 static int amd_pmf_pwr_src_notify_call(struct notifier_block *nb, unsigned long event, void *data) ··· 497 493 dev_dbg(dev->dev, "SPS enabled and Platform Profiles registered\n"); 498 494 } 499 495 500 - amd_pmf_init_smart_pc(dev); 501 - if (dev->smart_pc_enabled) { 502 - dev_dbg(dev->dev, "Smart PC Solution Enabled\n"); 503 - /* If Smart PC is enabled, no need to check for other features */ 504 - return; 496 + if (smart_pc_support) { 497 + amd_pmf_init_smart_pc(dev); 498 + if (dev->smart_pc_enabled) { 499 + dev_dbg(dev->dev, "Smart PC Solution Enabled\n"); 500 + /* If Smart PC is enabled, no need to check for other features */ 501 + return; 502 + } 503 + } else { 504 + dev->smart_pc_enabled = false; 505 505 } 506 506 507 507 if (is_apmf_func_supported(dev, APMF_FUNC_AUTO_MODE)) {