projects
/
firefly-linux-kernel-4.4.55.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6e4ff77
)
driver,mpu6500: improve readfifo
author
Zorro Liu
<lyx@rock-chips.com>
Tue, 23 Aug 2016 07:00:00 +0000
(15:00 +0800)
committer
Huang, Tao
<huangtao@rock-chips.com>
Wed, 24 Aug 2016 05:07:34 +0000
(13:07 +0800)
while (fifo_count == 0) && (kfifo_len(&st->timestamps) > 0) then flush fifo
Change-Id: I9b4ab975d708ee1bb02435bca933ce8f3b55e037
Signed-off-by: Zorro Liu <lyx@rock-chips.com>
drivers/staging/iio/imu/inv_mpu/inv_mpu_ring.c
patch
|
blob
|
history
diff --git
a/drivers/staging/iio/imu/inv_mpu/inv_mpu_ring.c
b/drivers/staging/iio/imu/inv_mpu/inv_mpu_ring.c
index d8558d75c70d4a442e8ae23eaa1a795c46cc8d46..bfff9c5d48c90af0bdb0f3d60b26ab5b53d228e4 100644
(file)
--- a/
drivers/staging/iio/imu/inv_mpu/inv_mpu_ring.c
+++ b/
drivers/staging/iio/imu/inv_mpu/inv_mpu_ring.c
@@
-1002,7
+1002,7
@@
irqreturn_t inv_read_fifo(int irq, void *dev_id)
if (result)
goto end_session;
fifo_count = be16_to_cpup((__be16 *)(&data[0]));
- if (
fifo_count == 0
)
+ if (
(fifo_count == 0) && (kfifo_len(&st->timestamps) > 0)
)
goto flush_fifo;
if (fifo_count < bytes_per_datum)
goto end_session;