Lines Matching refs:calib_graph
393 static void qcom_vadc_scale_calib(const struct vadc_linear_graph *calib_graph, in qcom_vadc_scale_calib() argument
398 *scale_voltage = (adc_code - calib_graph->gnd); in qcom_vadc_scale_calib()
399 *scale_voltage *= calib_graph->dx; in qcom_vadc_scale_calib()
400 *scale_voltage = div64_s64(*scale_voltage, calib_graph->dy); in qcom_vadc_scale_calib()
402 *scale_voltage += calib_graph->dx; in qcom_vadc_scale_calib()
408 static int qcom_vadc_scale_volt(const struct vadc_linear_graph *calib_graph, in qcom_vadc_scale_volt() argument
415 qcom_vadc_scale_calib(calib_graph, adc_code, absolute, &voltage); in qcom_vadc_scale_volt()
424 static int qcom_vadc_scale_therm(const struct vadc_linear_graph *calib_graph, in qcom_vadc_scale_therm() argument
432 qcom_vadc_scale_calib(calib_graph, adc_code, absolute, &voltage); in qcom_vadc_scale_therm()
446 static int qcom_vadc_scale_die_temp(const struct vadc_linear_graph *calib_graph, in qcom_vadc_scale_die_temp() argument
454 qcom_vadc_scale_calib(calib_graph, adc_code, absolute, &voltage); in qcom_vadc_scale_die_temp()
469 static int qcom_vadc_scale_chg_temp(const struct vadc_linear_graph *calib_graph, in qcom_vadc_scale_chg_temp() argument
476 qcom_vadc_scale_calib(calib_graph, adc_code, absolute, &voltage); in qcom_vadc_scale_chg_temp()
638 const struct vadc_linear_graph *calib_graph, in qcom_vadc_scale() argument
645 return qcom_vadc_scale_volt(calib_graph, prescale, in qcom_vadc_scale()
650 return qcom_vadc_scale_therm(calib_graph, prescale, in qcom_vadc_scale()
654 return qcom_vadc_scale_die_temp(calib_graph, prescale, in qcom_vadc_scale()
658 return qcom_vadc_scale_chg_temp(calib_graph, prescale, in qcom_vadc_scale()