Lines Matching full:tz

122  * @node: a list element to be added to the list of tz events
146 * @tz: thermal zone this object belongs to
152 struct thermal_zone_device *tz;
556 static struct tz_episode *thermal_debugfs_tz_event_alloc(struct thermal_zone_device *tz,
562 tze = kzalloc(struct_size(tze, trip_stats, tz->num_trips), GFP_KERNEL);
571 for (i = 0; i < tz->num_trips; i++) {
579 void thermal_debug_tz_trip_up(struct thermal_zone_device *tz,
582 struct thermal_debugfs *thermal_dbg = tz->debugfs;
583 int trip_id = thermal_zone_trip_id(tz, trip);
630 tze = thermal_debugfs_tz_event_alloc(tz, now);
672 void thermal_debug_tz_trip_down(struct thermal_zone_device *tz,
675 struct thermal_debugfs *thermal_dbg = tz->debugfs;
676 int trip_id = thermal_zone_trip_id(tz, trip);
727 void thermal_debug_update_trip_stats(struct thermal_zone_device *tz)
729 struct thermal_debugfs *thermal_dbg = tz->debugfs;
746 if (tz->temperature > tze->max_temp)
747 tze->max_temp = tz->temperature;
753 trip_stats->min = min(trip_stats->min, tz->temperature);
754 trip_stats->avg += (tz->temperature - trip_stats->avg) /
789 struct thermal_zone_device *tz = thermal_dbg->tz_dbg.tz;
812 for_each_trip_desc(tz, td) {
824 trip_id = thermal_zone_trip_id(tz, trip);
866 void thermal_debug_tz_add(struct thermal_zone_device *tz)
871 thermal_dbg = thermal_debugfs_add_id(d_tz, tz->id);
877 tz_dbg->tz = tz;
879 tz_dbg->trips_crossed = kcalloc(tz->num_trips, sizeof(int), GFP_KERNEL);
890 tz->debugfs = thermal_dbg;
893 static struct thermal_debugfs *thermal_debug_tz_clear(struct thermal_zone_device *tz)
897 guard(thermal_zone)(tz);
899 thermal_dbg = tz->debugfs;
901 tz->debugfs = NULL;
906 void thermal_debug_tz_remove(struct thermal_zone_device *tz)
913 thermal_dbg = thermal_debug_tz_clear(tz);
934 void thermal_debug_tz_resume(struct thermal_zone_device *tz)
936 struct thermal_debugfs *thermal_dbg = tz->debugfs;