3rd patchs (in alphabetical order): - bbr3 - ntsync5 - openwrt - pf-kernel - xanmod - zen no configuration changes for now
45 lines
1.3 KiB
Diff
45 lines
1.3 KiB
Diff
From db147a0a6341822a15fd9c4cd51f8dc4a9a1747b Mon Sep 17 00:00:00 2001
|
|
From: Dhananjay Ugwekar <Dhananjay.Ugwekar@amd.com>
|
|
Date: Thu, 17 Oct 2024 10:05:27 +0000
|
|
Subject: cpufreq/amd-pstate: Call amd_pstate_register() in amd_pstate_init()
|
|
|
|
Replace a similar chunk of code in amd_pstate_init() with
|
|
amd_pstate_register() call.
|
|
|
|
Suggested-by: Mario Limonciello <mario.limonciello@amd.com>
|
|
Signed-off-by: Dhananjay Ugwekar <Dhananjay.Ugwekar@amd.com>
|
|
---
|
|
drivers/cpufreq/amd-pstate.c | 12 ++----------
|
|
1 file changed, 2 insertions(+), 10 deletions(-)
|
|
|
|
--- a/drivers/cpufreq/amd-pstate.c
|
|
+++ b/drivers/cpufreq/amd-pstate.c
|
|
@@ -1909,17 +1909,10 @@ static int __init amd_pstate_init(void)
|
|
return ret;
|
|
}
|
|
|
|
- /* enable amd pstate feature */
|
|
- ret = amd_pstate_enable(true);
|
|
- if (ret) {
|
|
- pr_err("failed to enable driver mode(%d)\n", cppc_state);
|
|
- return ret;
|
|
- }
|
|
-
|
|
- ret = cpufreq_register_driver(current_pstate_driver);
|
|
+ ret = amd_pstate_register_driver(cppc_state);
|
|
if (ret) {
|
|
pr_err("failed to register with return %d\n", ret);
|
|
- goto disable_driver;
|
|
+ return ret;
|
|
}
|
|
|
|
dev_root = bus_get_dev_root(&cpu_subsys);
|
|
@@ -1936,7 +1929,6 @@ static int __init amd_pstate_init(void)
|
|
|
|
global_attr_free:
|
|
cpufreq_unregister_driver(current_pstate_driver);
|
|
-disable_driver:
|
|
amd_pstate_enable(false);
|
|
return ret;
|
|
}
|