Skip to content

Commit 429e1e8

Browse files
NXP-CarlosSongjic23
authored andcommitted
iio: imu: fxos8700: fix map label of channel type to MAGN sensor
FXOS8700 is an IMU sensor with ACCEL sensor and MAGN sensor. Sensor type is indexed by corresponding channel type in a switch. IIO_ANGL_VEL channel type mapped to MAGN sensor has caused confusion. Fix the mapping label of "IIO_MAGN" channel type instead of "IIO_ANGL_VEL" channel type to MAGN sensor. Fixes: 84e5ddd ("iio: imu: Add support for the FXOS8700 IMU") Signed-off-by: Carlos Song <[email protected]> Link: https://lore.kernel.org/r/[email protected] Cc: <[email protected]> Signed-off-by: Jonathan Cameron <[email protected]>
1 parent f804bd0 commit 429e1e8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/iio/imu/fxos8700_core.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -320,7 +320,7 @@ static enum fxos8700_sensor fxos8700_to_sensor(enum iio_chan_type iio_type)
320320
switch (iio_type) {
321321
case IIO_ACCEL:
322322
return FXOS8700_ACCEL;
323-
case IIO_ANGL_VEL:
323+
case IIO_MAGN:
324324
return FXOS8700_MAGN;
325325
default:
326326
return -EINVAL;

0 commit comments

Comments
 (0)