Lines Matching refs:uc_pdata

30 	struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev);  in check_channel()  local
38 if ((uc_pdata->channel_mask >= mask) && (uc_pdata->channel_mask & mask)) in check_channel()
49 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in adc_supply_enable() local
53 if (uc_pdata->vdd_supply) { in adc_supply_enable()
55 ret = regulator_set_enable(uc_pdata->vdd_supply, true); in adc_supply_enable()
58 if (!ret && uc_pdata->vss_supply) { in adc_supply_enable()
60 ret = regulator_set_enable(uc_pdata->vss_supply, true); in adc_supply_enable()
71 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in adc_data_mask() local
73 if (!uc_pdata) in adc_data_mask()
76 *data_mask = uc_pdata->data_mask; in adc_data_mask()
130 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in adc_channel_data() local
132 unsigned int timeout_us = uc_pdata->data_timeout_us; in adc_channel_data()
157 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in adc_channels_data() local
158 unsigned int timeout_us = uc_pdata->multidata_timeout_us; in adc_channels_data()
258 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in adc_vdd_platdata_update() local
268 &uc_pdata->vdd_supply); in adc_vdd_platdata_update()
272 ret = regulator_get_value(uc_pdata->vdd_supply); in adc_vdd_platdata_update()
276 uc_pdata->vdd_microvolts = ret; in adc_vdd_platdata_update()
283 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in adc_vss_platdata_update() local
287 &uc_pdata->vss_supply); in adc_vss_platdata_update()
291 ret = regulator_get_value(uc_pdata->vss_supply); in adc_vss_platdata_update()
295 uc_pdata->vss_microvolts = ret; in adc_vss_platdata_update()
302 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in adc_vdd_value() local
303 int ret, value_sign = uc_pdata->vdd_polarity_negative ? -1 : 1; in adc_vdd_value()
305 if (!uc_pdata->vdd_supply) in adc_vdd_value()
313 if (uc_pdata->vdd_microvolts == -ENODATA) in adc_vdd_value()
316 *uV = uc_pdata->vdd_microvolts * value_sign; in adc_vdd_value()
323 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in adc_vss_value() local
324 int ret, value_sign = uc_pdata->vss_polarity_negative ? -1 : 1; in adc_vss_value()
326 if (!uc_pdata->vss_supply) in adc_vss_value()
334 if (uc_pdata->vss_microvolts == -ENODATA) in adc_vss_value()
337 *uV = uc_pdata->vss_microvolts * value_sign; in adc_vss_value()
344 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in adc_vdd_platdata_set() local
349 uc_pdata->vdd_polarity_negative = dev_read_bool(dev, prop); in adc_vdd_platdata_set()
357 uc_pdata->vdd_microvolts = dev_read_u32_default(dev, prop, -ENODATA); in adc_vdd_platdata_set()
364 struct adc_uclass_platdata *uc_pdata = dev_get_uclass_platdata(dev); in adc_vss_platdata_set() local
369 uc_pdata->vss_polarity_negative = dev_read_bool(dev, prop); in adc_vss_platdata_set()
377 uc_pdata->vss_microvolts = dev_read_u32_default(dev, prop, -ENODATA); in adc_vss_platdata_set()