Lines Matching full:thermistor

130 /* cold junction for thermocouples and rsense for rtd's and thermistor's */
584 struct ltc2983_thermistor *thermistor = to_thermistor(sensor); in ltc2983_thermistor_assign_chan() local
587 chan_val = LTC2983_CHAN_ASSIGN(thermistor->r_sense_chan); in ltc2983_thermistor_assign_chan()
588 chan_val |= LTC2983_THERMISTOR_CFG(thermistor->sensor_config); in ltc2983_thermistor_assign_chan()
590 LTC2983_THERMISTOR_EXC_CURRENT(thermistor->excitation_current); in ltc2983_thermistor_assign_chan()
592 if (thermistor->custom) { in ltc2983_thermistor_assign_chan()
596 thermistor->custom, in ltc2983_thermistor_assign_chan()
891 struct ltc2983_thermistor *thermistor; in ltc2983_thermistor_new() local
896 thermistor = devm_kzalloc(dev, sizeof(*thermistor), GFP_KERNEL); in ltc2983_thermistor_new()
897 if (!thermistor) in ltc2983_thermistor_new()
906 ret = fwnode_property_read_u32(ref, "reg", &thermistor->r_sense_chan); in ltc2983_thermistor_new()
912 thermistor->sensor_config = LTC2983_THERMISTOR_SGL(1); in ltc2983_thermistor_new()
916 thermistor->sensor_config = in ltc2983_thermistor_new()
919 thermistor->sensor_config = in ltc2983_thermistor_new()
923 if (!(thermistor->sensor_config & LTC2983_THERMISTOR_DIFF_MASK) && in ltc2983_thermistor_new()
926 "Invalid chann:%d for differential thermistor\n", in ltc2983_thermistor_new()
938 propname = "adi,custom-thermistor"; in ltc2983_thermistor_new()
941 thermistor->custom = __ltc2983_custom_sensor_new(st, child, in ltc2983_thermistor_new()
945 if (IS_ERR(thermistor->custom)) in ltc2983_thermistor_new()
946 return ERR_CAST(thermistor->custom); in ltc2983_thermistor_new()
949 thermistor->sensor.fault_handler = ltc2983_common_fault_handler; in ltc2983_thermistor_new()
950 thermistor->sensor.assign_chan = ltc2983_thermistor_assign_chan; in ltc2983_thermistor_new()
958 thermistor->excitation_current = 0x03; in ltc2983_thermistor_new()
961 thermistor->excitation_current = 0x0c; in ltc2983_thermistor_new()
970 thermistor->excitation_current = 0x0c; in ltc2983_thermistor_new()
973 thermistor->excitation_current = 0x01; in ltc2983_thermistor_new()
976 thermistor->excitation_current = 0x02; in ltc2983_thermistor_new()
979 thermistor->excitation_current = 0x03; in ltc2983_thermistor_new()
982 thermistor->excitation_current = 0x04; in ltc2983_thermistor_new()
985 thermistor->excitation_current = 0x05; in ltc2983_thermistor_new()
988 thermistor->excitation_current = 0x06; in ltc2983_thermistor_new()
991 thermistor->excitation_current = 0x07; in ltc2983_thermistor_new()
994 thermistor->excitation_current = 0x08; in ltc2983_thermistor_new()
997 thermistor->excitation_current = 0x09; in ltc2983_thermistor_new()
1000 thermistor->excitation_current = 0x0a; in ltc2983_thermistor_new()
1003 thermistor->excitation_current = 0x0b; in ltc2983_thermistor_new()
1012 return &thermistor->sensor; in ltc2983_thermistor_new()
1040 "Invalid chann:%d for differential thermistor\n", in ltc2983_diode_new()