summaryrefslogtreecommitdiff
path: root/common/motion_sense.c
diff options
context:
space:
mode:
authorDawid Niedzwiecki <dn@semihalf.com>2020-11-06 09:20:56 +0100
committerCommit Bot <commit-bot@chromium.org>2020-12-14 19:59:09 +0000
commitf96f176c303a73973d7cf5ddf1abf86f534a6e39 (patch)
treea793c58f008cfa94cc93ea34627fd1b6457e3a1b /common/motion_sense.c
parenta23ef3d074335f2b6953194671f966117fd1fe60 (diff)
downloadchrome-ec-f96f176c303a73973d7cf5ddf1abf86f534a6e39.tar.gz
task_set_event: remove the wait argument
There is an option in the task_set_event function which force the calling task to wait for an event. However, the option is never used thus remove it. This also will help in the Zephyr migration process. BUG=b:172360521 BRANCH=none TEST=make buildall Signed-off-by: Dawid Niedzwiecki <dn@semihalf.com> Change-Id: Ic152fd3d6862d487bcc0024c48d136556c0b81bc Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2521599 Reviewed-by: Jett Rink <jettrink@chromium.org> Reviewed-by: Tom Hughes <tomhughes@chromium.org> Reviewed-by: Jack Rosenthal <jrosenth@chromium.org> Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
Diffstat (limited to 'common/motion_sense.c')
-rw-r--r--common/motion_sense.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/common/motion_sense.c b/common/motion_sense.c
index d4e1cbdc10..7a306bfb4a 100644
--- a/common/motion_sense.c
+++ b/common/motion_sense.c
@@ -419,7 +419,7 @@ static void motion_sense_switch_sensor_rate(void)
if (sensor_setup_mask) {
atomic_or(&odr_event_required, sensor_setup_mask);
task_set_event(TASK_ID_MOTIONSENSE,
- TASK_EVENT_MOTION_ODR_CHANGE, 0);
+ TASK_EVENT_MOTION_ODR_CHANGE);
} else {
/* No sensor activated, reset host interval interval to 0. */
ap_event_interval = 0;
@@ -1130,7 +1130,7 @@ static enum ec_status host_cmd_motion_sense(struct host_cmd_handler_args *args)
/* Force a collection to purge old events. */
task_set_event(TASK_ID_MOTIONSENSE,
- TASK_EVENT_MOTION_ODR_CHANGE, 0);
+ TASK_EVENT_MOTION_ODR_CHANGE);
}
out->ec_rate.ret = motion_sense_ec_rate(sensor) / MSEC;
@@ -1158,7 +1158,7 @@ static enum ec_status host_cmd_motion_sense(struct host_cmd_handler_args *args)
atomic_or(&odr_event_required,
BIT(sensor - motion_sensors));
task_set_event(TASK_ID_MOTIONSENSE,
- TASK_EVENT_MOTION_ODR_CHANGE, 0);
+ TASK_EVENT_MOTION_ODR_CHANGE);
}
out->sensor_odr.ret = sensor->drv->get_data_rate(sensor);
@@ -1277,7 +1277,7 @@ static enum ec_status host_cmd_motion_sense(struct host_cmd_handler_args *args)
atomic_add(&sensor->flush_pending, 1);
task_set_event(TASK_ID_MOTIONSENSE,
- TASK_EVENT_MOTION_FLUSH_PENDING, 0);
+ TASK_EVENT_MOTION_FLUSH_PENDING);
/* pass-through */
case MOTIONSENSE_CMD_FIFO_INFO:
if (!IS_ENABLED(CONFIG_ACCEL_FIFO)) {
@@ -1671,7 +1671,7 @@ static int command_accel_data_rate(int argc, char **argv)
atomic_or(&odr_event_required, 1 << (sensor - motion_sensors));
task_set_event(TASK_ID_MOTIONSENSE,
- TASK_EVENT_MOTION_ODR_CHANGE, 0);
+ TASK_EVENT_MOTION_ODR_CHANGE);
} else {
ccprintf("Data rate for sensor %d: %d\n", id,
sensor->drv->get_data_rate(sensor));