Commit 6c23811e authored by Ge Gao's avatar Ge Gao Committed by Jonathan Cameron

using kfifo_in_spinlocked instead of separate code.

Signed-off-by: default avatarGe Gao <ggao@invensense.com>
Signed-off-by: default avatarJonathan Cameron <jic23@kernel.org>
parent 039a9dce
......@@ -105,9 +105,8 @@ irqreturn_t inv_mpu6050_irq_handler(int irq, void *p)
s64 timestamp;
timestamp = iio_get_time_ns();
spin_lock(&st->time_stamp_lock);
kfifo_in(&st->timestamps, &timestamp, 1);
spin_unlock(&st->time_stamp_lock);
kfifo_in_spinlocked(&st->timestamps, &timestamp, 1,
&st->time_stamp_lock);
return IRQ_WAKE_THREAD;
}
......
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