Skip to content

Commit 3f6b537

Browse files
committed
ACPI: thermal: Get rid of a dummy local variable
The second argument of acpi_bus_update_power() can be NULL, so drop the power_state dummy local variable in acpi_thermal_resume() used just for avoiding passing NULL as the second argument to that function. No intentional functional impact. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Link: https://patch.msgid.link/13851842.uLZWGnKmhe@rafael.j.wysocki
1 parent b320789 commit 3f6b537

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

drivers/acpi/thermal.c

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -924,7 +924,7 @@ static int acpi_thermal_suspend(struct device *dev)
924924
static int acpi_thermal_resume(struct device *dev)
925925
{
926926
struct acpi_thermal *tz;
927-
int i, j, power_state;
927+
int i, j;
928928

929929
if (!dev)
930930
return -EINVAL;
@@ -939,10 +939,8 @@ static int acpi_thermal_resume(struct device *dev)
939939
if (!acpi_thermal_trip_valid(acpi_trip))
940940
break;
941941

942-
for (j = 0; j < acpi_trip->devices.count; j++) {
943-
acpi_bus_update_power(acpi_trip->devices.handles[j],
944-
&power_state);
945-
}
942+
for (j = 0; j < acpi_trip->devices.count; j++)
943+
acpi_bus_update_power(acpi_trip->devices.handles[j], NULL);
946944
}
947945

948946
acpi_queue_thermal_check(tz);

0 commit comments

Comments
 (0)