From 05f5517f4f2321296e177ca25b16ea157153c07c Mon Sep 17 00:00:00 2001 From: dongjiuzhu1 Date: Wed, 10 Jul 2024 17:52:19 +0800 Subject: [PATCH] drivers/sensors: clear pollpri events after get events Signed-off-by: dongjiuzhu1 --- drivers/sensors/sensor.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/sensors/sensor.c b/drivers/sensors/sensor.c index 7951f840e2..7ec0530cca 100644 --- a/drivers/sensors/sensor.c +++ b/drivers/sensors/sensor.c @@ -950,6 +950,7 @@ static int sensor_ioctl(FAR struct file *filep, int cmd, unsigned long arg) nxrmutex_lock(&upper->lock); *(FAR unsigned int *)(uintptr_t)arg = user->event; user->event = 0; + user->changed = false; nxrmutex_unlock(&upper->lock); } break;