Skip to content

Commit b9b6ee6

Browse files
committed
thermal: gov_bang_bang: Call __thermal_cdev_update() directly
Instead of clearing the "updated" flag for each cooling device affected by the trip point crossing in bang_bang_control() and walking all thermal instances to run thermal_cdev_update() for all of the affected cooling devices, call __thermal_cdev_update() directly for each of them. No intentional functional impact. Signed-off-by: Rafael J. Wysocki <[email protected]> Acked-by: Peter Kästle <[email protected]> Reviewed-by: Zhang Rui <[email protected]> Cc: 6.10+ <[email protected]> # 6.10+ Link: https://patch.msgid.link/[email protected]
1 parent 7c626ce commit b9b6ee6

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

drivers/thermal/gov_bang_bang.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -71,12 +71,9 @@ static void bang_bang_control(struct thermal_zone_device *tz,
7171
dev_dbg(&instance->cdev->device, "target=%ld\n", instance->target);
7272

7373
mutex_lock(&instance->cdev->lock);
74-
instance->cdev->updated = false; /* cdev needs update */
74+
__thermal_cdev_update(instance->cdev);
7575
mutex_unlock(&instance->cdev->lock);
7676
}
77-
78-
list_for_each_entry(instance, &tz->thermal_instances, tz_node)
79-
thermal_cdev_update(instance->cdev);
8077
}
8178

8279
static struct thermal_governor thermal_gov_bang_bang = {

0 commit comments

Comments
 (0)