Lines Matching refs:trip
88 &td->trip; \
95 struct thermal_trip *trip = thermal_trip_of_attr(attr, type); in trip_point_type_show() local
97 return sprintf(buf, "%s\n", thermal_trip_type_name(trip->type)); in trip_point_type_show()
104 struct thermal_trip *trip = thermal_trip_of_attr(attr, temp); in trip_point_temp_store() local
114 if (temp == trip->temperature) in trip_point_temp_store()
119 temp <= trip->hysteresis + THERMAL_TEMP_INVALID) { in trip_point_temp_store()
125 ret = tz->ops.set_trip_temp(tz, trip, temp); in trip_point_temp_store()
130 thermal_zone_set_trip_temp(tz, trip, temp); in trip_point_temp_store()
144 struct thermal_trip *trip = thermal_trip_of_attr(attr, temp); in trip_point_temp_show() local
146 return sprintf(buf, "%d\n", READ_ONCE(trip->temperature)); in trip_point_temp_show()
153 struct thermal_trip *trip = thermal_trip_of_attr(attr, hyst); in trip_point_hyst_store() local
163 if (hyst == trip->hysteresis) in trip_point_hyst_store()
172 if (trip->temperature == THERMAL_TEMP_INVALID) { in trip_point_hyst_store()
173 WRITE_ONCE(trip->hysteresis, hyst); in trip_point_hyst_store()
177 if (trip->temperature - hyst <= THERMAL_TEMP_INVALID) { in trip_point_hyst_store()
182 thermal_zone_set_trip_hyst(tz, trip, hyst); in trip_point_hyst_store()
196 struct thermal_trip *trip = thermal_trip_of_attr(attr, hyst); in trip_point_hyst_show() local
198 return sprintf(buf, "%d\n", READ_ONCE(trip->hysteresis)); in trip_point_hyst_show()
427 if (td->trip.flags & THERMAL_TRIP_FLAG_RW_TEMP) { in create_trip_attrs()
440 if (td->trip.flags & THERMAL_TRIP_FLAG_RW_HYST) { in create_trip_attrs()
870 return sprintf(buf, "%d\n", thermal_zone_trip_id(tz, instance->trip)); in trip_point_show()