Home
last modified time | relevance | path

Searched refs:pthresh (Results 1 – 3 of 3) sorted by relevance

/openbmc/linux/drivers/iio/proximity/
H A Dsx9360.c424 unsigned int regval, pthresh; in sx9360_read_hysteresis() local
427 ret = sx9360_read_thresh(data, &pthresh); in sx9360_read_hysteresis()
439 *val = pthresh >> (5 - regval); in sx9360_read_hysteresis()
531 int ret, pthresh; in sx9360_write_hysteresis() local
533 ret = sx9360_read_thresh(data, &pthresh); in sx9360_write_hysteresis()
539 else if (val >= pthresh >> 2) in sx9360_write_hysteresis()
541 else if (val >= pthresh >> 3) in sx9360_write_hysteresis()
543 else if (val >= pthresh >> 4) in sx9360_write_hysteresis()
H A Dsx9324.c536 unsigned int regval, pthresh; in sx9324_read_hysteresis() local
539 ret = sx9324_read_thresh(data, chan, &pthresh); in sx9324_read_hysteresis()
551 *val = pthresh >> (5 - regval); in sx9324_read_hysteresis()
647 int ret, pthresh; in sx9324_write_hysteresis() local
649 ret = sx9324_read_thresh(data, chan, &pthresh); in sx9324_write_hysteresis()
655 else if (val >= pthresh >> 2) in sx9324_write_hysteresis()
657 else if (val >= pthresh >> 3) in sx9324_write_hysteresis()
659 else if (val >= pthresh >> 4) in sx9324_write_hysteresis()
H A Dsx9310.c435 unsigned int regval, pthresh; in sx9310_read_hysteresis() local
438 ret = sx9310_read_thresh(data, chan, &pthresh); in sx9310_read_hysteresis()
451 *val = pthresh >> (5 - regval); in sx9310_read_hysteresis()
556 int ret, pthresh; in sx9310_write_hysteresis() local
558 ret = sx9310_read_thresh(data, chan, &pthresh); in sx9310_write_hysteresis()
564 else if (val == pthresh >> 2) in sx9310_write_hysteresis()
566 else if (val == pthresh >> 3) in sx9310_write_hysteresis()
568 else if (val == pthresh >> 4) in sx9310_write_hysteresis()