- if there is no client which uses batch latency, batch count should be set
the default value, not 0 but max batch count. if sensord sets the
UINT_MAX as a default value, HAL will set the proper value comparing
between this sensor's max batch count and UINT_MAX.
Change-Id: I3aff8d24c00ca6b232d33c803b1783cb60325abb
Signed-off-by: kibak.yoon <kibak.yoon@samsung.com>
*/
#include <stdint.h>
+#include <limits.h>
#include <sensor_hal_types.h>
#include <sensor_event_queue.h>
#include <sensor_base.h>
cur_max = m_sensor_info_list.get_max_batch();
if (!cur_max) {
- _I("No latency for sensor[%#llx] by client[%d] deleting latency, so set to default 0 ms",
+ _I("No latency for sensor[%#llx] by client[%d] deleting latency, so set to default count",
get_id(), client_id);
- set_batch_latency(0);
+ set_batch_latency(UINT_MAX);
} else if (cur_max != prev_max) {
_I("Max latency for sensor[%#llx] is changed from %dms to %dms by client[%d] deleting latency",
get_id(), prev_max, cur_max, client_id);