Re: [PATCH 18/24] iio:gp2ap020a00f: Use iio_push_to_buffers_with_timestamp()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 09/19/13 13:59, Lars-Peter Clausen wrote:
> Makes the code a bit shorter and less ugly.
> 
> Signed-off-by: Lars-Peter Clausen <lars@xxxxxxxxxx>
> Cc: Jacek Anaszewski <j.anaszewski@xxxxxxxxxxx>
Applied to the togreg branch of iio.git

> ---
>  drivers/iio/light/gp2ap020a00f.c | 9 ++-------
>  1 file changed, 2 insertions(+), 7 deletions(-)
> 
> diff --git a/drivers/iio/light/gp2ap020a00f.c b/drivers/iio/light/gp2ap020a00f.c
> index 62809b5..b1e4615 100644
> --- a/drivers/iio/light/gp2ap020a00f.c
> +++ b/drivers/iio/light/gp2ap020a00f.c
> @@ -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);
>  
> 
--
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




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Input]     [Linux Kernel]     [Linux SCSI]     [X.org]

  Powered by Linux