From: Daniel Lezcano Date: Wed, 1 Mar 2023 20:14:46 +0000 (+0100) Subject: thermal/drivers/acerhdf: Remove pointless governor test X-Git-Tag: microblaze-v6.6~647^2~2^2^2~12^2 X-Git-Url: http://git.monstr.eu/?a=commitdiff_plain;h=20918ccacd06eea4a4ff457bd86cae62859461a2;p=linux-2.6-microblaze.git thermal/drivers/acerhdf: Remove pointless governor test The thermal zone parameter specifies the bang-bang governor. The Kconfig selects the bang-bang governor. So it is pointless to test if the governor was set for the thermal zone assuming it may not have been compiled-in. Remove the test and prevent another access into the thermal internals. Signed-off-by: Daniel Lezcano Acked-by: Peter Kaestle Signed-off-by: Rafael J. Wysocki --- diff --git a/drivers/platform/x86/acerhdf.c b/drivers/platform/x86/acerhdf.c index 50cdf70ade7f..5c9293e7eccb 100644 --- a/drivers/platform/x86/acerhdf.c +++ b/drivers/platform/x86/acerhdf.c @@ -691,13 +691,6 @@ static int __init acerhdf_register_thermal(void) if (ret) return ret; - if (strcmp(thz_dev->governor->name, - acerhdf_zone_params.governor_name)) { - pr_err("Didn't get thermal governor %s, perhaps not compiled into thermal subsystem.\n", - acerhdf_zone_params.governor_name); - return -EINVAL; - } - return 0; }