For PROP_REPORT_INTERVAL, the default unit of measure is set to
milliseconds instead of zero.
This patch is a workaround, which changes the default value if it is
zero. The proper solution should be to initiate with correct default
value. There might be other parameters that need a change in default
value as well. How that is best done needs to be investigated further.
Tracked-By: APDEV-1124
Issue: APDEV-1000
Change-Id: I6df27a7612499f93d65b4cccecf9677005315eb7
Signed-off-by: Per Persson <per.persson@intel.com>
hid_sensor_get_reporting_interval(hsdev, usage_id, st);
+ /* Default unit of measure is milliseconds */
+ if (st->poll.units == 0)
+ st->poll.units = HID_USAGE_SENSOR_UNITS_MILLISECOND;
+
sensor_hub_input_get_attribute_info(hsdev,
HID_FEATURE_REPORT, usage_id,
HID_USAGE_SENSOR_PROP_REPORT_STATE,