Lines Matching defs:vref
154 struct regulator *vref[4];
421 unsigned int res, gain, full_scale, vref;
438 vref = st->channel_config[chan->address].vref_mv * 1000000LL;
439 res = DIV_ROUND_CLOSEST(vref, full_scale);
558 if (IS_ERR(st->vref[refsel])) {
562 return PTR_ERR(st->vref[refsel]);
565 regulator_get_voltage(st->vref[refsel]);
752 for (i = 0; i < ARRAY_SIZE(st->vref); i++) {
756 st->vref[i] = devm_regulator_get_optional(&spi->dev,
758 if (PTR_ERR(st->vref[i]) == -ENODEV)
760 else if (IS_ERR(st->vref[i]))
761 return PTR_ERR(st->vref[i]);
763 ret = regulator_enable(st->vref[i]);
768 st->vref[i]);