Skip to content
Commit 3a3bbc69 authored by Rafael J. Wysocki's avatar Rafael J. Wysocki Committed by Greg Kroah-Hartman
Browse files

thermal: trip: Drop redundant trips check from for_each_thermal_trip()



[ Upstream commit a15ffa78 ]

It is invalid to call for_each_thermal_trip() on an unregistered thermal
zone anyway, and as per thermal_zone_device_register_with_trips(), the
trips[] table must be present if num_trips is greater than zero for the
given thermal zone.

Hence, the trips check in for_each_thermal_trip() is redundant and so it
can be dropped.

Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
Acked-by: default avatarDaniel Lezcano <daniel.lezcano@linaro.org>
Stable-dep-of: e95fa740 ("thermal: gov_power_allocator: avoid inability to reset a cdev")
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent cca76386
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment