On 26/03/16 03:42, Matt Ranostay wrote: > This get lost in the inbox? :) > Same fix as for APDS9660 issue in the FIFO > > On Thu, Mar 17, 2016 at 8:48 PM, Matt Ranostay <mranostay@xxxxxxxxx> wrote: >> Correct issue that the last entry in FIFO was being read twice due >> to an incorrect decrement of entry count variable before condition >> check. >> >> Signed-off-by: Matt Ranostay <mranostay@xxxxxxxxx> Odd - disappeared without trace. Well spotted. Applied to the fixes-togreg-post-rc1 branch of iio.git Thanks, Jonathan >> --- >> drivers/iio/health/max30100.c | 3 ++- >> 1 file changed, 2 insertions(+), 1 deletion(-) >> >> diff --git a/drivers/iio/health/max30100.c b/drivers/iio/health/max30100.c >> index 09db893..90ab8a2d 100644 >> --- a/drivers/iio/health/max30100.c >> +++ b/drivers/iio/health/max30100.c >> @@ -238,12 +238,13 @@ static irqreturn_t max30100_interrupt_handler(int irq, void *private) >> >> mutex_lock(&data->lock); >> >> - while (cnt-- || (cnt = max30100_fifo_count(data) > 0)) { >> + while (cnt || (cnt = max30100_fifo_count(data) > 0)) { >> ret = max30100_read_measurement(data); >> if (ret) >> break; >> >> iio_push_to_buffers(data->indio_dev, data->buffer); >> + cnt--; >> } >> >> mutex_unlock(&data->lock); >> -- >> 2.7.0 >> > -- > To unsubscribe from this list: send the line "unsubscribe linux-iio" in > the body of a message to majordomo@xxxxxxxxxxxxxxx > More majordomo info at http://vger.kernel.org/majordomo-info.html > -- To unsubscribe from this list: send the line "unsubscribe linux-iio" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html