Lines Matching full:instance
19 struct thermal_instance *instance; in thermal_zone_trip_update() local
29 list_for_each_entry(instance, &tz->thermal_instances, tz_node) { in thermal_zone_trip_update()
30 if (instance->trip != trip) in thermal_zone_trip_update()
34 if (instance->target == THERMAL_NO_TARGET) in thermal_zone_trip_update()
35 instance->target = 0; in thermal_zone_trip_update()
38 if (instance->target != 0 && instance->target != 1) { in thermal_zone_trip_update()
39 pr_warn("Thermal instance %s controlled by bang-bang has unexpected state: %ld\n", in thermal_zone_trip_update()
40 instance->name, instance->target); in thermal_zone_trip_update()
41 instance->target = 1; in thermal_zone_trip_update()
48 if (instance->target == 0 && tz->temperature >= trip->temperature) in thermal_zone_trip_update()
49 instance->target = 1; in thermal_zone_trip_update()
50 else if (instance->target == 1 && in thermal_zone_trip_update()
52 instance->target = 0; in thermal_zone_trip_update()
54 dev_dbg(&instance->cdev->device, "target=%d\n", in thermal_zone_trip_update()
55 (int)instance->target); in thermal_zone_trip_update()
57 mutex_lock(&instance->cdev->lock); in thermal_zone_trip_update()
58 instance->cdev->updated = false; /* cdev needs update */ in thermal_zone_trip_update()
59 mutex_unlock(&instance->cdev->lock); in thermal_zone_trip_update()
94 struct thermal_instance *instance; in bang_bang_control() local
103 list_for_each_entry(instance, &tz->thermal_instances, tz_node) in bang_bang_control()
104 thermal_cdev_update(instance->cdev); in bang_bang_control()