Lines Matching refs:ops
84 const struct thermal_zone_of_device_ops *ops; member
94 if (!data->ops->get_temp) in of_thermal_get_temp()
97 return data->ops->get_temp(data->sensor_data, temp); in of_thermal_get_temp()
180 if (!data->ops || !data->ops->set_emul_temp) in of_thermal_set_emul_temp()
183 return data->ops->set_emul_temp(data->sensor_data, temp); in of_thermal_set_emul_temp()
193 if (!data->ops->get_trend) in of_thermal_get_trend()
196 r = data->ops->get_trend(data->sensor_data, &dev_trend); in of_thermal_get_trend()
397 const struct thermal_zone_of_device_ops *ops) in thermal_zone_of_add_sensor() argument
408 if (!ops) in thermal_zone_of_add_sensor()
412 tz->ops = ops; in thermal_zone_of_add_sensor()
415 tzd->ops->get_temp = of_thermal_get_temp; in thermal_zone_of_add_sensor()
416 tzd->ops->get_trend = of_thermal_get_trend; in thermal_zone_of_add_sensor()
417 tzd->ops->set_emul_temp = of_thermal_set_emul_temp; in thermal_zone_of_add_sensor()
457 const struct thermal_zone_of_device_ops *ops) in thermal_zone_of_sensor_register() argument
499 data, ops); in thermal_zone_of_sensor_register()
501 tzd->ops->set_mode(tzd, THERMAL_DEVICE_ENABLED); in thermal_zone_of_sensor_register()
547 tzd->ops->get_temp = NULL; in thermal_zone_of_sensor_unregister()
548 tzd->ops->get_trend = NULL; in thermal_zone_of_sensor_unregister()
549 tzd->ops->set_emul_temp = NULL; in thermal_zone_of_sensor_unregister()
551 tz->ops = NULL; in thermal_zone_of_sensor_unregister()
857 struct thermal_zone_device_ops *ops; in of_parse_thermal_zones() local
881 ops = kmemdup(&of_thermal_ops, sizeof(*ops), GFP_KERNEL); in of_parse_thermal_zones()
882 if (!ops) in of_parse_thermal_zones()
887 kfree(ops); in of_parse_thermal_zones()
896 ops, tzp, in of_parse_thermal_zones()
903 kfree(ops); in of_parse_thermal_zones()
953 kfree(zone->ops); in of_thermal_destroy_zones()