{"id":11279,"url":"https://patchwork.libcamera.org/api/covers/11279/?format=json","web_url":"https://patchwork.libcamera.org/cover/11279/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/projects/1/?format=json","name":"libcamera","link_name":"libcamera","list_id":"libcamera_core","list_email":"libcamera-devel@lists.libcamera.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20210213042225.112477-1-paul.elder@ideasonboard.com>","date":"2021-02-13T04:22:13","name":"[libcamera-devel,v8,00/12] IPA isolation: Part 2: Conversion and plumbing","submitter":{"id":17,"url":"https://patchwork.libcamera.org/api/people/17/?format=json","name":"Paul Elder","email":"paul.elder@ideasonboard.com"},"mbox":"https://patchwork.libcamera.org/cover/11279/mbox/","series":[{"id":1688,"url":"https://patchwork.libcamera.org/api/series/1688/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=1688","date":"2021-02-13T04:22:13","name":"IPA isolation: Part 2: Conversion and plumbing","version":8,"mbox":"https://patchwork.libcamera.org/series/1688/mbox/"}],"comments":"https://patchwork.libcamera.org/api/covers/11279/comments/","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 39FE1BD160\n\tfor <parsemail@patchwork.libcamera.org>;\n\tSat, 13 Feb 2021 04:22:37 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 070A1637A8;\n\tSat, 13 Feb 2021 05:22:37 +0100 (CET)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 898066379C\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tSat, 13 Feb 2021 05:22:35 +0100 (CET)","from pyrite.rasen.tech (unknown\n\t[IPv6:2400:4051:61:600:2c71:1b79:d06d:5032])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id A5D9D564;\n\tSat, 13 Feb 2021 05:22:33 +0100 (CET)"],"Authentication-Results":"lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"UV0XHXri\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1613190154;\n\tbh=J8oCGN9qMAe4L2VERXzIZrcRLlgjP/hzZGBKJYD/txg=;\n\th=From:To:Cc:Subject:Date:From;\n\tb=UV0XHXrirgFJg+qQU9LFoyT3mqMyxfIGSZN4U7PDpQevPgm+JWmDarkeH+70uSahW\n\tSZBv++x6vUshogT60hcgx+wUhVrE7gQQxbFli0LDvbEKQnxiH0Nmds6e0WYyCTMDRv\n\tgDTPITHJRQjVZxJi6H9xn7Ej2NYzB0X2SuGrJ5CI=","From":"Paul Elder <paul.elder@ideasonboard.com>","To":"libcamera-devel@lists.libcamera.org","Date":"Sat, 13 Feb 2021 13:22:13 +0900","Message-Id":"<20210213042225.112477-1-paul.elder@ideasonboard.com>","X-Mailer":"git-send-email 2.27.0","MIME-Version":"1.0","Subject":"[libcamera-devel] [PATCH v8 00/12] IPA isolation: Part 2:\n\tConversion and plumbing","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Content-Type":"text/plain; charset=\"utf-8\"","Content-Transfer-Encoding":"base64","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"},"content":"v8 is split in three parts, core components, conversion + plumbing, and\ntests + documentation.\n\nThis is part 2, and implements the plumbing for IPA isolation.\n\nPatches 4/12 to 11/12 must be squashed together to avoid bisection\nbreakage.\n\nPatch 8/12 may be of interest, as it shows how one would write the\ninterface and data definition. In v2 I have customized the raspberrypi\nmojom file to take advantage of the freedom in definition the IPA\ninterface and data structures (as opposed to v1, where it was\npractically a direct translation of IPAOperationData). In v3 I have\nadded namespace support to the data definition, and this is reflected in\nits usage. In v6 I added support for custom start(), and used it. Also\nin v6, support for consts was added, so I moved all the enum and const\ndefinitions to the mojom file.\n\nAs of v6, namespacing in the mojom files is required, in the form of\n/^ipa\\.[0-9A-Za-z]+/ and this is reflected in the three mojom files in\nthis series.\n\nPatch 9/11 is also noteworthy, as it shows how one would use the\ninterface that has been defined. Since the headers and proxies are\nautogenerated, there isn't a patch where the generated code can be seen,\nhowever.\n\nPatches 10/12 to 12/12 also define mojom files and use them, but are\nfor vimc, rkisp1, and ipu3, respectively. These will also give an idea\non how the mojom definition looks and how it will be used.\n\n\nChanges in v8:\n- copy controls in raspberrypi start() instead of std::move()\n- rebase on \"libcamera: pipeline: rkisp1: configure IPA from configure\n  method instead of start method\"\n- replace push_back with emplace_back in ipu3\n\nChanges in v7:\n- clean up raspberrypi IPA interface while rebasing\n- add ipu3 support for the new IPC (from Niklas)\n\nChanges in v6:\n- move definitions of libcamera structs to core.mojom (in Part 1)\n- move enums and consts from the ipa header to the mojom file\n  - remove vimc.h, use the ipa::vimc namespace, and use the new start()\n  - same for rkisp1.h\n- remove postfix _ in generated struct fields\n- use the required ipa namespace\n- fill the LS table handle in the raspberry pi pipeline handler, instead\n  of passing it from the IPA\n- remove per-pipeline ContrlInfoMap from the ipa header\n  - remove the ControlInfoMap initializer from raspberrypi header\n\n\nNiklas Söderlund (1):\n  libcamera: pipeline, ipa: ipu3: Support the new IPC mechanism\n\nPaul Elder (11):\n  meson: ipa, proxy: Generate headers and proxy with mojo\n  tests: Remove IPA wrappers test\n  ipa: raspberrypi: meson: Add dependency on generated headers\n  libcamera: IPAInterface: Replace C API with the new C++-only API\n  libcamera: IPAProxy: Remove stop() override\n  libcamera: IPAProxy, IPAManager: Switch to one-proxy-per-pipeline\n    scheme\n  libcamera: PipelineHandler: Remove IPA from base class\n  ipa: raspberrypi: Add mojom data definition file\n  libcamera: pipeline, ipa: raspberrypi: Use new data definition\n  libcamera: pipeline, ipa: vimc: Support the new IPC mechanism\n  libcamera: pipeline, ipa: rkisp1: Support the new IPC mechanism\n\n Documentation/Doxyfile.in                     |   1 -\n .../libcamera/internal/ipa_context_wrapper.h  |  53 --\n include/libcamera/internal/ipa_manager.h      |  31 +-\n include/libcamera/internal/ipa_module.h       |   4 +-\n include/libcamera/internal/ipa_proxy.h        |  31 -\n include/libcamera/internal/meson.build        |   1 -\n include/libcamera/internal/pipeline_handler.h |   1 -\n include/libcamera/ipa/ipa_interface.h         | 147 +---\n include/libcamera/ipa/ipu3.h                  |  23 -\n include/libcamera/ipa/ipu3.mojom              |  43 ++\n include/libcamera/ipa/meson.build             | 125 ++++\n include/libcamera/ipa/raspberrypi.h           |  31 -\n include/libcamera/ipa/raspberrypi.mojom       | 131 ++++\n include/libcamera/ipa/rkisp1.h                |  22 -\n include/libcamera/ipa/rkisp1.mojom            |  44 ++\n include/libcamera/ipa/vimc.h                  |  28 -\n include/libcamera/ipa/vimc.mojom              |  24 +\n src/ipa/ipu3/ipu3.cpp                         |  74 +-\n src/ipa/ipu3/meson.build                      |   6 +-\n src/ipa/libipa/ipa_interface_wrapper.cpp      | 287 --------\n src/ipa/libipa/ipa_interface_wrapper.h        |  61 --\n src/ipa/libipa/meson.build                    |   2 -\n src/ipa/raspberrypi/meson.build               |   2 +-\n src/ipa/raspberrypi/raspberrypi.cpp           | 180 ++---\n src/ipa/rkisp1/meson.build                    |   2 +-\n src/ipa/rkisp1/rkisp1.cpp                     |  63 +-\n src/ipa/vimc/meson.build                      |   2 +-\n src/ipa/vimc/vimc.cpp                         |  39 +-\n src/libcamera/ipa_context_wrapper.cpp         | 298 --------\n src/libcamera/ipa_interface.cpp               | 650 +-----------------\n src/libcamera/ipa_manager.cpp                 |  47 +-\n src/libcamera/ipa_module.cpp                  |  18 +-\n src/libcamera/ipa_proxy.cpp                   | 101 ---\n src/libcamera/meson.build                     |   2 +-\n src/libcamera/pipeline/ipu3/ipu3.cpp          |  95 +--\n .../pipeline/raspberrypi/raspberrypi.cpp      | 257 ++++---\n .../pipeline/raspberrypi/rpi_stream.cpp       |   6 +-\n .../pipeline/raspberrypi/rpi_stream.h         |   5 +-\n src/libcamera/pipeline/rkisp1/rkisp1.cpp      |  79 ++-\n src/libcamera/pipeline/vimc/vimc.cpp          |  10 +-\n src/libcamera/pipeline_handler.cpp            |   8 -\n src/libcamera/proxy/ipa_proxy_linux.cpp       | 104 ---\n src/libcamera/proxy/ipa_proxy_thread.cpp      | 175 -----\n src/libcamera/proxy/meson.build               |  21 +-\n .../proxy/worker/ipa_proxy_linux_worker.cpp   |  90 ---\n src/libcamera/proxy/worker/meson.build        |  23 +-\n test/ipa/ipa_interface_test.cpp               |  44 +-\n test/ipa/ipa_wrappers_test.cpp                | 455 ------------\n test/ipa/meson.build                          |   3 +-\n utils/ipc/generators/meson.build              |   3 +\n utils/ipc/meson.build                         |  13 +\n 51 files changed, 883 insertions(+), 3082 deletions(-)\n delete mode 100644 include/libcamera/internal/ipa_context_wrapper.h\n delete mode 100644 include/libcamera/ipa/ipu3.h\n create mode 100644 include/libcamera/ipa/ipu3.mojom\n create mode 100644 include/libcamera/ipa/raspberrypi.mojom\n delete mode 100644 include/libcamera/ipa/rkisp1.h\n create mode 100644 include/libcamera/ipa/rkisp1.mojom\n delete mode 100644 include/libcamera/ipa/vimc.h\n create mode 100644 include/libcamera/ipa/vimc.mojom\n delete mode 100644 src/ipa/libipa/ipa_interface_wrapper.cpp\n delete mode 100644 src/ipa/libipa/ipa_interface_wrapper.h\n delete mode 100644 src/libcamera/ipa_context_wrapper.cpp\n delete mode 100644 src/libcamera/proxy/ipa_proxy_linux.cpp\n delete mode 100644 src/libcamera/proxy/ipa_proxy_thread.cpp\n delete mode 100644 src/libcamera/proxy/worker/ipa_proxy_linux_worker.cpp\n delete mode 100644 test/ipa/ipa_wrappers_test.cpp\n create mode 100644 utils/ipc/generators/meson.build"}