From patchwork Mon Apr 13 21:26:52 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Niklas_S=C3=B6derlund?= X-Patchwork-Id: 3446 Return-Path: Received: from vsp-unauthed02.binero.net (vsp-unauthed02.binero.net [195.74.38.227]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id E3F0B6279B for ; Mon, 13 Apr 2020 23:27:07 +0200 (CEST) X-Halon-ID: 8088c57f-7dcd-11ea-aeed-005056917f90 Authorized-sender: niklas@soderlund.pp.se Received: from bismarck.berto.se (p4fca2392.dip0.t-ipconnect.de [79.202.35.146]) by bin-vsp-out-02.atm.binero.net (Halon) with ESMTPA id 8088c57f-7dcd-11ea-aeed-005056917f90; Mon, 13 Apr 2020 23:26:59 +0200 (CEST) From: =?utf-8?q?Niklas_S=C3=B6derlund?= To: libcamera-devel@lists.libcamera.org Date: Mon, 13 Apr 2020 23:26:52 +0200 Message-Id: <20200413212700.1373247-1-niklas.soderlund@ragnatech.se> X-Mailer: git-send-email 2.26.0 MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH v4 0/8] libcamera: ipa_manager: Proxy open-source IPAs to a thread X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Apr 2020 21:27:08 -0000 Hello, This series tries to solve some issues discovered by testing Laurent's patch (8/8 in this series). The main change is to extend the IPAInterface with a start() and stop() method that can deal with things as starting threads or allocating resources needed by the IPA in tandem with the camera start and stop. The series is a mix of patches to the rkisp1 pipeline handler solving issues uncovered by running the IPA in a separate thread, adding the IPA start() and stop() methods and integrating them with Laurent's work to run open-source IPAs in a thread. Laurent Pinchart (1): libcamera: ipa_manager: Proxy open-source IPAs to a thread Niklas Söderlund (7): ipa: Add start() and stop() operations libcamera: pipeline: rkisp1: Queue parameters even if they are not ready libcamera: pipeline: rkisp1: Initialize IPA libcamera: pipeline: rkisp1: Add clear() to RkISP1Frames libcamera: pipeline: rkisp1: Do not try to process cancelled frames libcamera: pipeline: rkisp1: Call IPA start() and stop() libcamera: pipeline: vimc: Call IPA start() and stop() include/ipa/ipa_interface.h | 4 + include/ipa/ipa_vimc.h | 2 + src/ipa/libipa/ipa_interface_wrapper.cpp | 16 ++ src/ipa/libipa/ipa_interface_wrapper.h | 2 + src/ipa/rkisp1/rkisp1.cpp | 2 + src/ipa/vimc/vimc.cpp | 20 +++ src/libcamera/include/ipa_context_wrapper.h | 2 + src/libcamera/ipa_context_wrapper.cpp | 22 +++ src/libcamera/ipa_interface.cpp | 35 +++++ src/libcamera/ipa_manager.cpp | 48 +++--- src/libcamera/pipeline/rkisp1/rkisp1.cpp | 63 +++++++- src/libcamera/pipeline/vimc/vimc.cpp | 8 + src/libcamera/proxy/ipa_proxy_linux.cpp | 2 + src/libcamera/proxy/ipa_proxy_thread.cpp | 162 ++++++++++++++++++++ src/libcamera/proxy/meson.build | 1 + test/ipa/ipa_interface_test.cpp | 22 +++ test/ipa/ipa_wrappers_test.cpp | 33 +++- 17 files changed, 410 insertions(+), 34 deletions(-) create mode 100644 src/libcamera/proxy/ipa_proxy_thread.cpp