iio:imu:mpu6050: enhance mounting matrix support
authorGregor Boirie <gregor.boirie@parrot.com>
Wed, 20 Apr 2016 17:23:45 +0000 (19:23 +0200)
committerJonathan Cameron <jic23@kernel.org>
Sat, 23 Apr 2016 21:16:01 +0000 (22:16 +0100)
commiteb3798463f71afc77abd25b2f62708be06f7173b
treed35a30863782850b30e888b9cbc5822386beee1f
parent97eacb9166f4810368e180073dcbceeff0de34df
iio:imu:mpu6050: enhance mounting matrix support

Add a new rotation matrix sysfs attribute compliant with IIO core
mounting matrix API.
Matrix is retrieved from "in_anglvel_mount_matrix" and
"in_accel_mount_matrix" sysfs attributes. It is declared into mpu6050 DTS
entry as a "mount-matrix" property.

Old interface is kept for backward userspace compatibility and may be
retrieved from legacy platform_data mechanism only.

Signed-off-by: Gregor Boirie <gregor.boirie@parrot.com>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Documentation/ABI/testing/sysfs-bus-iio
Documentation/devicetree/bindings/iio/imu/inv_mpu6050.txt
drivers/iio/imu/inv_mpu6050/inv_mpu_core.c
drivers/iio/imu/inv_mpu6050/inv_mpu_iio.h
include/linux/platform_data/invensense_mpu6050.h