Home
last modified time | relevance | path

Searched refs:threshold_hi (Results 1 – 2 of 2) sorted by relevance

/linux-4.19.296/drivers/iio/adc/
Dhi8435.c57 unsigned threshold_hi[2]; /* GND-Open and Supply-Open thresholds */ member
221 if (val < 2 || val > 21 || (val + 2) > priv->threshold_hi[mode]) in hi8435_write_event_value()
230 if ((priv->threshold_hi[mode] - priv->threshold_lo[mode]) % 2) in hi8435_write_event_value()
231 priv->threshold_hi[mode]--; in hi8435_write_event_value()
237 if (val == priv->threshold_hi[mode]) in hi8435_write_event_value()
240 priv->threshold_hi[mode] = val; in hi8435_write_event_value()
243 if ((priv->threshold_hi[mode] - priv->threshold_lo[mode]) % 2) in hi8435_write_event_value()
258 reg = priv->threshold_hi[mode] - priv->threshold_lo[mode]; in hi8435_write_event_value()
261 reg |= (priv->threshold_hi[mode] + priv->threshold_lo[mode]); in hi8435_write_event_value()
512 priv->threshold_hi[0] = priv->threshold_hi[1] = 4; in hi8435_probe()
/linux-4.19.296/drivers/misc/
Dbh1770glc.c318 u16 threshold_hi, u16 threshold_lo) in bh1770_lux_update_thresholds() argument
332 if (threshold_hi != BH1770_LUX_RANGE && threshold_hi != 0) in bh1770_lux_update_thresholds()
333 threshold_hi = bh1770_lux_adjusted_to_raw(chip, threshold_hi); in bh1770_lux_update_thresholds()
338 if (chip->lux_thres_hi_onchip == threshold_hi && in bh1770_lux_update_thresholds()
342 chip->lux_thres_hi_onchip = threshold_hi; in bh1770_lux_update_thresholds()
345 data[0] = threshold_hi; in bh1770_lux_update_thresholds()
346 data[1] = threshold_hi >> 8; in bh1770_lux_update_thresholds()