]> asedeno.scripts.mit.edu Git - linux.git/commit
iio: imu: inv_mpu6050: fix no data on MPU6050
authorJean-Baptiste Maneyrol <JManeyrol@invensense.com>
Wed, 16 Oct 2019 14:43:28 +0000 (14:43 +0000)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Tue, 22 Oct 2019 11:42:54 +0000 (12:42 +0100)
commit6e82ae6b8d11b948b74e71396efd8e074c415f44
tree3f92013119290e579ad23d98ec2889f533f4919c
parent431f7667bd6889a274913162dfd19cce9d84848e
iio: imu: inv_mpu6050: fix no data on MPU6050

Some chips have a fifo overflow bit issue where the bit is always
set. The result is that every data is dropped.

Change fifo overflow management by checking fifo count against
a maximum value.

Add fifo size in chip hardware set of values.

Fixes: f5057e7b2dba ("iio: imu: inv_mpu6050: better fifo overflow handling")
Cc: stable@vger.kernel.org
Signed-off-by: Jean-Baptiste Maneyrol <jmaneyrol@invensense.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/imu/inv_mpu6050/inv_mpu_core.c
drivers/iio/imu/inv_mpu6050/inv_mpu_iio.h
drivers/iio/imu/inv_mpu6050/inv_mpu_ring.c