From patchwork Sun Aug 18 01:13:17 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laurent Pinchart X-Patchwork-Id: 1839 Return-Path: Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 018EF60BE5 for ; Sun, 18 Aug 2019 03:13:41 +0200 (CEST) Received: from pendragon.bb.dnainternet.fi (dfj612yhrgyx302h3jwwy-3.rev.dnainternet.fi [IPv6:2001:14ba:21f5:5b00:ce28:277f:58d7:3ca4]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 908EF2AF for ; Sun, 18 Aug 2019 03:13:40 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1566090820; bh=vvmW1RbYdLnl447BMgqSdazGzQ/LgAaB1ZKSpCju4ss=; h=From:To:Subject:Date:In-Reply-To:References:From; b=cdvuNUGuuVkLNzxle/CJpBQlenM+kxG4Ee7Gy+/dFa19/xz4Y3KdyD4ZumF2VQXyi nOPkCFbTze25FoZcIkt9bjGO0jkHutX3AH/6SsHmJKXzL+xq3Ovj7AEj8q4Tu1fID/ uSb7tAtJWjPE/h8nCQGMEfPhcYCnZzX8GU/3kHho= From: Laurent Pinchart To: libcamera-devel@lists.libcamera.org Date: Sun, 18 Aug 2019 04:13:17 +0300 Message-Id: <20190818011329.14499-3-laurent.pinchart@ideasonboard.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190818011329.14499-1-laurent.pinchart@ideasonboard.com> References: <20190818011329.14499-1-laurent.pinchart@ideasonboard.com> MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH 02/14] libcamera: proxy: Get event dispatcher from current thread X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 18 Aug 2019 01:13:41 -0000 Get the event dispatcher from the current thread instead of the camera manager. This prepares for the removal of CameraManager::instance(). Signed-off-by: Laurent Pinchart Reviewed-by: Jacopo Mondi --- src/libcamera/proxy/worker/ipa_proxy_linux_worker.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libcamera/proxy/worker/ipa_proxy_linux_worker.cpp b/src/libcamera/proxy/worker/ipa_proxy_linux_worker.cpp index c43b088ac39c..ffba3ae4de80 100644 --- a/src/libcamera/proxy/worker/ipa_proxy_linux_worker.cpp +++ b/src/libcamera/proxy/worker/ipa_proxy_linux_worker.cpp @@ -9,7 +9,6 @@ #include #include -#include #include #include #include @@ -17,6 +16,7 @@ #include "ipa_module.h" #include "ipc_unixsocket.h" #include "log.h" +#include "thread.h" #include "utils.h" using namespace libcamera; @@ -81,7 +81,7 @@ int main(int argc, char **argv) LOG(IPAProxyLinuxWorker, Debug) << "Proxy worker successfully started"; /* \todo upgrade listening loop */ - EventDispatcher *dispatcher = CameraManager::instance()->eventDispatcher(); + EventDispatcher *dispatcher = Thread::current()->eventDispatcher(); while (1) dispatcher->processEvents();