Commit 3b271798 authored by Lars-Peter Clausen's avatar Lars-Peter Clausen Committed by Jonathan Cameron

iio:gp2ap020a00f: Use iio_push_to_buffers_with_timestamp()

Makes the code a bit shorter and less ugly.
Signed-off-by: default avatarLars-Peter Clausen <lars@metafoo.de>
Cc: Jacek Anaszewski <j.anaszewski@samsung.com>
Signed-off-by: default avatarJonathan Cameron <jic23@kernel.org>
parent 0624bf84
......@@ -988,13 +988,8 @@ static irqreturn_t gp2ap020a00f_trigger_handler(int irq, void *data)
}
}
if (indio_dev->scan_timestamp) {
s64 *timestamp = (s64 *)((u8 *)priv->buffer +
ALIGN(d_size, sizeof(s64)));
*timestamp = pf->timestamp;
}
iio_push_to_buffers(indio_dev, priv->buffer);
iio_push_to_buffers_with_timestamp(indio_dev, priv->buffer,
pf->timestamp);
done:
iio_trigger_notify_done(indio_dev->trig);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment