OSDN Git Service

[REVERTME] Revert "Pass iio provided timestamps without further processing."
authorConstantin Musca <constantin.musca@intel.com>
Tue, 17 Feb 2015 13:20:13 +0000 (15:20 +0200)
committerMusca, Constantin <constantin.musca@intel.com>
Tue, 17 Feb 2015 12:34:08 +0000 (12:34 +0000)
Interrupts (events) are missed by the bmc150-accel & bmg160 drivers because it takes
too long to read from i2c. This might be caused by having three sensors on the same bus.
Process the timestamps in the HAL in order to make the CTSVerifier tests pass.
This commit reverts 58eef71e4b886632a7d51a6602fe8ef43b779d08 and it should be
reverted once the kernel problem is fixed.

Change-Id: Ieddd1e30253b9a79089740ca6a36e49b51c07d19
Tracked-On: https://jira01.devtools.intel.com/browse/GMINL-6031
Tracked-On: https://jira01.devtools.intel.com/browse/GMINL-6032
Tracked-On: https://jira01.devtools.intel.com/browse/GMINL-6033
Tracked-By: https://jira01.devtools.intel.com/browse/GMINL-4337
Signed-off-by: Constantin Musca <constantin.musca@intel.com>
control.c

index c527a55..34a8f06 100644 (file)
--- a/control.c
+++ b/control.c
@@ -1168,7 +1168,7 @@ static void stamp_reports (int dev_num, int64_t ts)
 
        for (s=0; s<MAX_SENSORS; s++)
                if (sensor[s].dev_num == dev_num && is_enabled(s) && sensor[s].mode != MODE_POLL)
-                       sensor[s].report_ts = ts;
+                       set_report_ts(s, ts);
 }
 
 
@@ -1263,6 +1263,7 @@ static int integrate_device_report_from_dev(int dev_num, int fd)
        boot_to_rt_delta = get_timestamp_boot() - get_timestamp_realtime();
 
        stamp_reports(dev_num, ts + boot_to_rt_delta);
+
        return 0;
 }