diff options
author | Song Hongyan <hongyan.song@intel.com> | 2017-05-07 18:24:26 +0800 |
---|---|---|
committer | Jonathan Cameron <jic23@kernel.org> | 2017-05-07 12:22:36 +0100 |
commit | a78587d338d084037b0ea6687508f207d8dec2fb (patch) | |
tree | 43f2428537d50c344174aba0d3ec9feb87561a77 /drivers/iio/common | |
parent | 00907c7a3282053dd4782e02c3101809608e7ea7 (diff) |
iio: hid-sensor-rotation: Add "scale" and "offset" properties parse support
Add orientation sensor "scale" and "offset" parse support.
These two properties are needed for exponent data conversion.
Signed-off-by: Song Hongyan <hongyan.song@intel.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@intel.com>
Reviewed-by: Xu Even <even.xu@intel.com>
Acked-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Diffstat (limited to 'drivers/iio/common')
-rw-r--r-- | drivers/iio/common/hid-sensors/hid-sensor-attributes.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/iio/common/hid-sensors/hid-sensor-attributes.c b/drivers/iio/common/hid-sensors/hid-sensor-attributes.c index aeb09a85d7a8..0e05f6d1e761 100644 --- a/drivers/iio/common/hid-sensors/hid-sensor-attributes.c +++ b/drivers/iio/common/hid-sensors/hid-sensor-attributes.c @@ -69,6 +69,12 @@ static struct { {HID_USAGE_SENSOR_TIME_TIMESTAMP, HID_USAGE_SENSOR_UNITS_MILLISECOND, 1000000, 0}, + {HID_USAGE_SENSOR_DEVICE_ORIENTATION, 0, 1, 0}, + + {HID_USAGE_SENSOR_RELATIVE_ORIENTATION, 0, 1, 0}, + + {HID_USAGE_SENSOR_GEOMAGNETIC_ORIENTATION, 0, 1, 0}, + {HID_USAGE_SENSOR_TEMPERATURE, 0, 1000, 0}, {HID_USAGE_SENSOR_TEMPERATURE, HID_USAGE_SENSOR_UNITS_DEGREES, 1000, 0}, |