Lines Matching full:trip

283  * - Critical trip point will cause a system shutdown.
306 const struct thermal_trip *trip) in handle_non_critical_trips() argument
308 tz->governor ? tz->governor->throttle(tz, trip) : in handle_non_critical_trips()
309 def_governor->throttle(tz, trip); in handle_non_critical_trips()
350 const struct thermal_trip *trip) in handle_critical_trips() argument
353 if (trip->temperature <= 0 || tz->temperature < trip->temperature) in handle_critical_trips()
356 trace_thermal_zone_trip(tz, thermal_zone_trip_id(tz, trip), trip->type); in handle_critical_trips()
358 if (trip->type == THERMAL_TRIP_CRITICAL) in handle_critical_trips()
365 struct thermal_trip *trip) in handle_thermal_trip() argument
367 if (trip->temperature == THERMAL_TEMP_INVALID) in handle_thermal_trip()
372 trip->threshold = trip->temperature; in handle_thermal_trip()
373 if (tz->temperature >= trip->threshold) in handle_thermal_trip()
374 trip->threshold -= trip->hysteresis; in handle_thermal_trip()
375 } else if (tz->last_temperature < trip->threshold) { in handle_thermal_trip()
377 * The trip threshold is equal to the trip temperature, unless in handle_thermal_trip()
379 * the trip is crossed if the current zone temperature is at in handle_thermal_trip()
381 * the threshold and the trip temperature will be equal. in handle_thermal_trip()
383 if (tz->temperature >= trip->temperature) { in handle_thermal_trip()
384 thermal_notify_tz_trip_up(tz, trip); in handle_thermal_trip()
385 thermal_debug_tz_trip_up(tz, trip); in handle_thermal_trip()
386 trip->threshold = trip->temperature - trip->hysteresis; in handle_thermal_trip()
388 trip->threshold = trip->temperature; in handle_thermal_trip()
392 * The previous zone temperature was above or equal to the trip in handle_thermal_trip()
394 * the trip (its temperature minus its hysteresis), unless the in handle_thermal_trip()
395 * trip temperature or hysteresis had changed. In either case, in handle_thermal_trip()
396 * the trip is crossed if the current zone temperature is below in handle_thermal_trip()
397 * the low temperature of the trip, but otherwise ensure that in handle_thermal_trip()
398 * the trip threshold will be equal to the low temperature of in handle_thermal_trip()
399 * the trip. in handle_thermal_trip()
401 if (tz->temperature < trip->temperature - trip->hysteresis) { in handle_thermal_trip()
402 thermal_notify_tz_trip_down(tz, trip); in handle_thermal_trip()
403 thermal_debug_tz_trip_down(tz, trip); in handle_thermal_trip()
404 trip->threshold = trip->temperature; in handle_thermal_trip()
406 trip->threshold = trip->temperature - trip->hysteresis; in handle_thermal_trip()
410 if (trip->type == THERMAL_TRIP_CRITICAL || trip->type == THERMAL_TRIP_HOT) in handle_thermal_trip()
411 handle_critical_trips(tz, trip); in handle_thermal_trip()
413 handle_non_critical_trips(tz, trip); in handle_thermal_trip()
462 struct thermal_trip *trip; in __thermal_zone_device_update() local
476 for_each_trip(tz, trip) in __thermal_zone_device_update()
477 handle_thermal_trip(tz, trip); in __thermal_zone_device_update()
628 * @trip: trip point the cooling devices is associated with in this zone.
630 * @upper: the Maximum cooling state for this trip point.
633 * @lower: the Minimum cooling state can be used for this trip point.
640 * This interface function bind a thermal cooling device to the certain trip
647 const struct thermal_trip *trip, in thermal_bind_cdev_to_trip() argument
689 dev->trip = trip; in thermal_bind_cdev_to_trip()
731 if (pos->tz == tz && pos->trip == trip && pos->cdev == cdev) { in thermal_bind_cdev_to_trip()
778 * @trip: trip point the cooling devices is associated with in this zone.
782 * trip point of a thermal zone device.
788 const struct thermal_trip *trip, in thermal_unbind_cdev_from_trip() argument
796 if (pos->tz == tz && pos->trip == trip && pos->cdev == cdev) { in thermal_unbind_cdev_from_trip()
1253 * @num_trips: the number of trip points the thermal zone support
1254 * @mask: a bit string indicating the writeablility of trip points
1261 * whether trip points have been crossed (0 for interrupt
1297 * Max trip count can't exceed 31 as the "mask >> num_trips" condition. in thermal_zone_device_register_with_trips()
1302 * E.g. mask = 0x80000000 for trip id 31 to be RW. Then in thermal_zone_device_register_with_trips()