Home
last modified time | relevance | path

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

/linux/drivers/iio/adc/
H A Dhi8435.c48 unsigned threshold_hi[2]; /* GND-Open and Supply-Open thresholds */ member
212 if (val < 2 || val > 21 || (val + 2) > priv->threshold_hi[mode]) in hi8435_write_event_value()
221 if ((priv->threshold_hi[mode] - priv->threshold_lo[mode]) % 2) in hi8435_write_event_value()
222 priv->threshold_hi[mode]--; in hi8435_write_event_value()
228 if (val == priv->threshold_hi[mode]) in hi8435_write_event_value()
231 priv->threshold_hi[mode] = val; in hi8435_write_event_value()
234 if ((priv->threshold_hi[mode] - priv->threshold_lo[mode]) % 2) in hi8435_write_event_value()
249 reg = priv->threshold_hi[mode] - priv->threshold_lo[mode]; in hi8435_write_event_value()
252 reg |= (priv->threshold_hi[mode] + priv->threshold_lo[mode]); in hi8435_write_event_value()
505 priv->threshold_hi[0] = priv->threshold_hi[1] = 4; in hi8435_probe()
/linux/drivers/net/ethernet/mellanox/mlxsw/
H A Dcore_env.c861 int err, threshold_hi; in mlxsw_env_temp_event_set() local
875 &threshold_hi); in mlxsw_env_temp_event_set()
880 threshold_hi = MLXSW_REG_MTMP_THRESH_HI; in mlxsw_env_temp_event_set()
887 threshold_hi = threshold_hi / 1000 * 8; in mlxsw_env_temp_event_set()
889 mlxsw_reg_mtmp_temperature_threshold_hi_set(mtmp_pl, threshold_hi); in mlxsw_env_temp_event_set()
890 mlxsw_reg_mtmp_temperature_threshold_lo_set(mtmp_pl, threshold_hi - in mlxsw_env_temp_event_set()