summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2021-03-12 04:18:46 +0000
committerKieran Bingham <kieran.bingham@ideasonboard.com>2021-03-24 09:24:06 +0000
commitb50c12bf187dafef02e9f226c328792abffc7357 (patch)
treeaf926536d7cedc0790d3543ed402ff7aa7026c09
parentf041482add7c3a78b9342447cbda98f856c5a7aa (diff)
utils: ipc: proxy: Process pending messages
Events may be queued to the pipeline handler between the pipeline handler entering the ::stop() function, and before the call to stop the IPA has completed. Handle these events by dispatching all pending messages at the proxy after the IPA has fully stopped. Reviewed-by: Jacopo Mondi <jacopo@jmondi.org> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
-rw-r--r--utils/ipc/generators/libcamera_templates/proxy_functions.tmpl2
1 files changed, 2 insertions, 0 deletions
diff --git a/utils/ipc/generators/libcamera_templates/proxy_functions.tmpl b/utils/ipc/generators/libcamera_templates/proxy_functions.tmpl
index 13dc8fdc..8addc2fa 100644
--- a/utils/ipc/generators/libcamera_templates/proxy_functions.tmpl
+++ b/utils/ipc/generators/libcamera_templates/proxy_functions.tmpl
@@ -31,6 +31,8 @@
thread_.exit();
thread_.wait();
+ Thread::current()->dispatchMessages(Message::Type::InvokeMessage);
+
running_ = false;
{%- endmacro -%}