Show a patch.

GET /api/patches/18643/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 18643,
    "url": "https://patchwork.libcamera.org/api/patches/18643/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/18643/",
    "project": {
        "id": 1,
        "url": "https://patchwork.libcamera.org/api/projects/1/?format=api",
        "name": "libcamera",
        "link_name": "libcamera",
        "list_id": "libcamera_core",
        "list_email": "libcamera-devel@lists.libcamera.org",
        "web_url": "",
        "scm_url": "",
        "webscm_url": ""
    },
    "msgid": "<20230522083546.2465448-2-chenghaoyang@google.com>",
    "date": "2023-05-22T08:35:06",
    "name": "[libcamera-devel,v6,1/3] libcamera: Move DmaHeap to HeapAllocator as a base class",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": false,
    "hash": "f139aa73527d3cda3ac7aabc2cc6737e34509cda",
    "submitter": {
        "id": 117,
        "url": "https://patchwork.libcamera.org/api/people/117/?format=api",
        "name": "Cheng-Hao Yang",
        "email": "chenghaoyang@chromium.org"
    },
    "delegate": null,
    "mbox": "https://patchwork.libcamera.org/patch/18643/mbox/",
    "series": [
        {
            "id": 3883,
            "url": "https://patchwork.libcamera.org/api/series/3883/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=3883",
            "date": "2023-05-22T08:35:05",
            "name": "Add HeapAllocator",
            "version": 6,
            "mbox": "https://patchwork.libcamera.org/series/3883/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/18643/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/18643/checks/",
    "tags": {},
    "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 DF96CC31E9\n\tfor <parsemail@patchwork.libcamera.org>;\n\tMon, 22 May 2023 08:35:56 +0000 (UTC)",
            "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 71D3E62868;\n\tMon, 22 May 2023 10:35:56 +0200 (CEST)",
            "from mail-pl1-x62a.google.com (mail-pl1-x62a.google.com\n\t[IPv6:2607:f8b0:4864:20::62a])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 4EEE560536\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 22 May 2023 10:35:54 +0200 (CEST)",
            "by mail-pl1-x62a.google.com with SMTP id\n\td9443c01a7336-1ae6b4c5a53so28568525ad.2\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 22 May 2023 01:35:54 -0700 (PDT)",
            "from chenghaoyang-low.c.googlers.com.com\n\t(27.247.221.35.bc.googleusercontent.com. [35.221.247.27])\n\tby smtp.gmail.com with ESMTPSA id\n\th1-20020a170902f54100b001a980a23804sm4321253plf.4.2023.05.22.01.35.51\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tMon, 22 May 2023 01:35:52 -0700 (PDT)"
        ],
        "DKIM-Signature": [
            "v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1684744556;\n\tbh=zQQ5xbkhnKL+j8UHLvRpkKSft/ozGZNYw7hO55w+//E=;\n\th=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc:\n\tFrom;\n\tb=gj/u5WUhyH9L4lHJvU23xNQzGZlqpC9U3sz15XqmzV25NiV0ViaXunFU/MJ0W75Wt\n\tmLDb/jsqz/nOmNRwVfF1ZkX3gUj3KOHuAKiTxVqqFy+bSQEkDKtwT8tNmF3ANUAOWp\n\tnYYb0lCObbi1Bjx1P7DJ5XDcvxoyGH1XDW7DsgyTphDZQzpN0grsFzdNyrwA+20+Ii\n\tHyWuGeXugzO+HRgZ3D5C2lbJDyZPQEn5dLzTgNmKJEm6BwRwi8JjigqAzYTwza991j\n\t8YpqJyN+nJqhuFqahsqosZi9Vvr60g0471X10iOMEaKsMBXLRsDV5GMTLIh1EGgtBX\n\t9Bq42tjt2QEYw==",
            "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=chromium.org; s=google; t=1684744552; x=1687336552;\n\th=content-transfer-encoding:mime-version:references:in-reply-to\n\t:message-id:date:subject:cc:to:from:from:to:cc:subject:date\n\t:message-id:reply-to;\n\tbh=ccmT6A0WdJ2K9iDEGYORVcW+9LO7sGp3F8OdVHXV5jQ=;\n\tb=he1Wu9z2bLbbp3FWq7CTq+B6TFJuKqveJf79bbmS4UKQfRy/35zQuIHhp/wJfAzEC8\n\tTVRvUGY48RdZgpc7dLQYLIA8ALi38GNx/sAJjWR5daa+V03mVFuNdadw+wgHzXQJhxAU\n\tEXSnWFBWo//wRz0tHPyxGOVSMGG39TRwe5Lsw="
        ],
        "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=chromium.org\n\theader.i=@chromium.org header.b=\"he1Wu9z2\"; \n\tdkim-atps=neutral",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20221208; t=1684744552; x=1687336552;\n\th=content-transfer-encoding:mime-version:references:in-reply-to\n\t:message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc\n\t:subject:date:message-id:reply-to;\n\tbh=ccmT6A0WdJ2K9iDEGYORVcW+9LO7sGp3F8OdVHXV5jQ=;\n\tb=IXr4SY0V1MVHVn+wy3y5nCokYhJ74cUJQzArdY5g94qnl5uwuW22DexmNo/CV4EXeg\n\teerRvvLBzL8IuW5o5AYQW6jIoEWFFz0pSUruzEhszYfeGbc3kXTZ+Z8flups+r5zEypr\n\tSIyHqQgoeuj69e2acRcMXtO4Q8y2x24TaE5n4Tz/yMD0pEoBNyW+q+greFOh2mXlpTwp\n\tPPcSqzjuJ3KSN7yRK86PrGo1kWd9MqZ4gKQIzYRvmOs9Eu1dW01ZcHAZOjCEdLYlhgt9\n\tuGLApSaa2nZHPnyT/V1AOhn7MZEwVe4YUm697ZXcxe5BPpQ1xHSTfGFPKwBZ+zzJ3n8w\n\tFYeA==",
        "X-Gm-Message-State": "AC+VfDxc3asqnVmNodvFwqDyFuHbWtYQZY3JtkJNRmhCqI8ZJyT9RBUx\n\tB1VOEQHDjTEZad1n+UHYWXY8utpRxLVgYWd3BL0=",
        "X-Google-Smtp-Source": "ACHHUZ7ur+/qNz8x13bqOeOvdmdMNTLcXBBExmHjEPVTTBiNfaN2kDMvRct75g2i9qqzPP+NlB1OoA==",
        "X-Received": "by 2002:a17:902:ef82:b0:1ac:a887:d344 with SMTP id\n\tiz2-20020a170902ef8200b001aca887d344mr10641355plb.19.1684744552553; \n\tMon, 22 May 2023 01:35:52 -0700 (PDT)",
        "X-Google-Original-From": "Harvey Yang <chenghaoyang@google.com>",
        "To": "libcamera-devel@lists.libcamera.org",
        "Date": "Mon, 22 May 2023 08:35:06 +0000",
        "Message-ID": "<20230522083546.2465448-2-chenghaoyang@google.com>",
        "X-Mailer": "git-send-email 2.40.1.698.g37aff9b760-goog",
        "In-Reply-To": "<20230522083546.2465448-1-chenghaoyang@google.com>",
        "References": "<20230522083546.2465448-1-chenghaoyang@google.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[libcamera-devel] [PATCH v6 1/3] libcamera: Move DmaHeap to\n\tHeapAllocator as a base class",
        "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>",
        "From": "Harvey Yang via libcamera-devel <libcamera-devel@lists.libcamera.org>",
        "Reply-To": "Harvey Yang <chenghaoyang@chromium.org>",
        "Cc": "Cheng-Hao Yang <chenghaoyang@chromium.org>",
        "Errors-To": "libcamera-devel-bounces@lists.libcamera.org",
        "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"
    },
    "content": "From: Cheng-Hao Yang <chenghaoyang@chromium.org>\n\nAs other components (like the WIP virtual pipeline handler) also need a\nheap allocator, move DmaHeap from raspberry pi pipeline handler to a\ngeneral HeapAllocator as a base class.\n\nSigned-off-by: Harvey Yang <chenghaoyang@chromium.org>\n---\n .../libcamera/internal/heap_allocator.h       |  17 ++-\n include/libcamera/internal/meson.build        |   1 +\n src/libcamera/heap_allocator.cpp              | 130 ++++++++++++++++++\n src/libcamera/meson.build                     |   1 +\n src/libcamera/pipeline/rpi/vc4/dma_heaps.cpp  |  90 ------------\n src/libcamera/pipeline/rpi/vc4/meson.build    |   5 +-\n src/libcamera/pipeline/rpi/vc4/vc4.cpp        |  11 +-\n 7 files changed, 146 insertions(+), 109 deletions(-)\n rename src/libcamera/pipeline/rpi/vc4/dma_heaps.h => include/libcamera/internal/heap_allocator.h (57%)\n create mode 100644 src/libcamera/heap_allocator.cpp\n delete mode 100644 src/libcamera/pipeline/rpi/vc4/dma_heaps.cpp",
    "diff": "diff --git a/src/libcamera/pipeline/rpi/vc4/dma_heaps.h b/include/libcamera/internal/heap_allocator.h\nsimilarity index 57%\nrename from src/libcamera/pipeline/rpi/vc4/dma_heaps.h\nrename to include/libcamera/internal/heap_allocator.h\nindex 0a4a8d86..92d4488a 100644\n--- a/src/libcamera/pipeline/rpi/vc4/dma_heaps.h\n+++ b/include/libcamera/internal/heap_allocator.h\n@@ -1,8 +1,9 @@\n /* SPDX-License-Identifier: LGPL-2.1-or-later */\n /*\n  * Copyright (C) 2020, Raspberry Pi Ltd\n+ * Copyright (C) 2023, Google Inc.\n  *\n- * dma_heaps.h - Helper class for dma-heap allocations.\n+ * heap_allocator.h - Helper class for heap buffer allocations.\n  */\n \n #pragma once\n@@ -13,20 +14,18 @@\n \n namespace libcamera {\n \n-namespace RPi {\n+class Heap;\n \n-class DmaHeap\n+class HeapAllocator\n {\n public:\n-\tDmaHeap();\n-\t~DmaHeap();\n-\tbool isValid() const { return dmaHeapHandle_.isValid(); }\n+\tHeapAllocator();\n+\t~HeapAllocator();\n+\tbool isValid() const;\n \tUniqueFD alloc(const char *name, std::size_t size);\n \n private:\n-\tUniqueFD dmaHeapHandle_;\n+\tstd::unique_ptr<Heap> heap_;\n };\n \n-} /* namespace RPi */\n-\n } /* namespace libcamera */\ndiff --git a/include/libcamera/internal/meson.build b/include/libcamera/internal/meson.build\nindex d7508805..9d25c289 100644\n--- a/include/libcamera/internal/meson.build\n+++ b/include/libcamera/internal/meson.build\n@@ -26,6 +26,7 @@ libcamera_internal_headers = files([\n     'device_enumerator_udev.h',\n     'formats.h',\n     'framebuffer.h',\n+    'heap_allocator.h',\n     'ipa_manager.h',\n     'ipa_module.h',\n     'ipa_proxy.h',\ndiff --git a/src/libcamera/heap_allocator.cpp b/src/libcamera/heap_allocator.cpp\nnew file mode 100644\nindex 00000000..69f65062\n--- /dev/null\n+++ b/src/libcamera/heap_allocator.cpp\n@@ -0,0 +1,130 @@\n+/* SPDX-License-Identifier: LGPL-2.1-or-later */\n+/*\n+ * Copyright (C) 2020, Raspberry Pi Ltd\n+ * Copyright (C) 2023, Google Inc.\n+ *\n+ * heap_allocator.cpp - Helper class for heap buffer allocations.\n+ */\n+\n+#include \"libcamera/internal/heap_allocator.h\"\n+\n+#include <array>\n+#include <fcntl.h>\n+#include <sys/ioctl.h>\n+#include <unistd.h>\n+\n+#include <linux/dma-buf.h>\n+#include <linux/dma-heap.h>\n+\n+#include <libcamera/base/log.h>\n+\n+namespace libcamera {\n+\n+/*\n+ * /dev/dma-heap/linux,cma is the dma-heap allocator, which allows dmaheap-cma\n+ * to only have to worry about importing.\n+ *\n+ * Annoyingly, should the cma heap size be specified on the kernel command line\n+ * instead of DT, the heap gets named \"reserved\" instead.\n+ */\n+static constexpr std::array<const char *, 3> dmaHeapNames = {\n+\t\"/dev/dma_heap/linux,cma\",\n+\t\"/dev/dma_heap/reserved\",\n+\t\"/dev/dma_heap/system\"\n+};\n+\n+LOG_DEFINE_CATEGORY(HeapAllocator)\n+\n+class Heap\n+{\n+public:\n+\tvirtual ~Heap() = default;\n+\tbool isValid() const { return handle_.isValid(); }\n+\tvirtual UniqueFD alloc(const char *name, std::size_t size) = 0;\n+\n+protected:\n+\tUniqueFD handle_;\n+};\n+\n+class DmaHeap : public Heap\n+{\n+public:\n+\tDmaHeap();\n+\t~DmaHeap();\n+\tUniqueFD alloc(const char *name, std::size_t size) override;\n+};\n+\n+DmaHeap::DmaHeap()\n+{\n+\tfor (const char *name : dmaHeapNames) {\n+\t\tint ret = ::open(name, O_RDWR | O_CLOEXEC, 0);\n+\t\tif (ret < 0) {\n+\t\t\tret = errno;\n+\t\t\tLOG(HeapAllocator, Debug) << \"DmaHeap failed to open \" << name << \": \"\n+\t\t\t\t\t\t  << strerror(ret);\n+\t\t\tcontinue;\n+\t\t}\n+\n+\t\thandle_ = UniqueFD(ret);\n+\t\tbreak;\n+\t}\n+\n+\tif (!handle_.isValid())\n+\t\tLOG(HeapAllocator, Error) << \"DmaHeap could not open any dmaHeap device\";\n+}\n+\n+DmaHeap::~DmaHeap() = default;\n+\n+UniqueFD DmaHeap::alloc(const char *name, std::size_t size)\n+{\n+\tint ret;\n+\n+\tif (!name)\n+\t\treturn {};\n+\n+\tstruct dma_heap_allocation_data alloc = {};\n+\n+\talloc.len = size;\n+\talloc.fd_flags = O_CLOEXEC | O_RDWR;\n+\n+\tret = ::ioctl(handle_.get(), DMA_HEAP_IOCTL_ALLOC, &alloc);\n+\tif (ret < 0) {\n+\t\tLOG(HeapAllocator, Error) << \"DmaHeap allocation failure for \"\n+\t\t\t\t\t  << name;\n+\t\treturn {};\n+\t}\n+\n+\tUniqueFD allocFd(alloc.fd);\n+\tret = ::ioctl(allocFd.get(), DMA_BUF_SET_NAME, name);\n+\tif (ret < 0) {\n+\t\tLOG(HeapAllocator, Error) << \"DmaHeap naming failure for \"\n+\t\t\t\t\t  << name;\n+\t\treturn {};\n+\t}\n+\n+\treturn allocFd;\n+}\n+\n+HeapAllocator::HeapAllocator()\n+{\n+\theap_ = std::make_unique<DmaHeap>();\n+}\n+\n+HeapAllocator::~HeapAllocator() = default;\n+\n+bool HeapAllocator::isValid() const\n+{\n+\treturn heap_->isValid();\n+}\n+\n+UniqueFD HeapAllocator::alloc(const char *name, std::size_t size)\n+{\n+\tif (!isValid()) {\n+\t\tLOG(HeapAllocator, Fatal) << \"Allocation attempted without allocator\" << name;\n+\t\treturn {};\n+\t}\n+\n+\treturn heap_->alloc(name, size);\n+}\n+\n+} /* namespace libcamera */\ndiff --git a/src/libcamera/meson.build b/src/libcamera/meson.build\nindex d4385041..aa2d32a0 100644\n--- a/src/libcamera/meson.build\n+++ b/src/libcamera/meson.build\n@@ -22,6 +22,7 @@ libcamera_sources = files([\n     'framebuffer.cpp',\n     'framebuffer_allocator.cpp',\n     'geometry.cpp',\n+    'heap_allocator.cpp',\n     'ipa_controls.cpp',\n     'ipa_data_serializer.cpp',\n     'ipa_interface.cpp',\ndiff --git a/src/libcamera/pipeline/rpi/vc4/dma_heaps.cpp b/src/libcamera/pipeline/rpi/vc4/dma_heaps.cpp\ndeleted file mode 100644\nindex 317b1fc1..00000000\n--- a/src/libcamera/pipeline/rpi/vc4/dma_heaps.cpp\n+++ /dev/null\n@@ -1,90 +0,0 @@\n-/* SPDX-License-Identifier: LGPL-2.1-or-later */\n-/*\n- * Copyright (C) 2020, Raspberry Pi Ltd\n- *\n- * dma_heaps.h - Helper class for dma-heap allocations.\n- */\n-\n-#include \"dma_heaps.h\"\n-\n-#include <array>\n-#include <fcntl.h>\n-#include <linux/dma-buf.h>\n-#include <linux/dma-heap.h>\n-#include <sys/ioctl.h>\n-#include <unistd.h>\n-\n-#include <libcamera/base/log.h>\n-\n-/*\n- * /dev/dma-heap/linux,cma is the dma-heap allocator, which allows dmaheap-cma\n- * to only have to worry about importing.\n- *\n- * Annoyingly, should the cma heap size be specified on the kernel command line\n- * instead of DT, the heap gets named \"reserved\" instead.\n- */\n-static constexpr std::array<const char *, 2> heapNames = {\n-\t\"/dev/dma_heap/linux,cma\",\n-\t\"/dev/dma_heap/reserved\"\n-};\n-\n-namespace libcamera {\n-\n-LOG_DECLARE_CATEGORY(RPI)\n-\n-namespace RPi {\n-\n-DmaHeap::DmaHeap()\n-{\n-\tfor (const char *name : heapNames) {\n-\t\tint ret = ::open(name, O_RDWR | O_CLOEXEC, 0);\n-\t\tif (ret < 0) {\n-\t\t\tret = errno;\n-\t\t\tLOG(RPI, Debug) << \"Failed to open \" << name << \": \"\n-\t\t\t\t\t<< strerror(ret);\n-\t\t\tcontinue;\n-\t\t}\n-\n-\t\tdmaHeapHandle_ = UniqueFD(ret);\n-\t\tbreak;\n-\t}\n-\n-\tif (!dmaHeapHandle_.isValid())\n-\t\tLOG(RPI, Error) << \"Could not open any dmaHeap device\";\n-}\n-\n-DmaHeap::~DmaHeap() = default;\n-\n-UniqueFD DmaHeap::alloc(const char *name, std::size_t size)\n-{\n-\tint ret;\n-\n-\tif (!name)\n-\t\treturn {};\n-\n-\tstruct dma_heap_allocation_data alloc = {};\n-\n-\talloc.len = size;\n-\talloc.fd_flags = O_CLOEXEC | O_RDWR;\n-\n-\tret = ::ioctl(dmaHeapHandle_.get(), DMA_HEAP_IOCTL_ALLOC, &alloc);\n-\tif (ret < 0) {\n-\t\tLOG(RPI, Error) << \"dmaHeap allocation failure for \"\n-\t\t\t\t<< name;\n-\t\treturn {};\n-\t}\n-\n-\tUniqueFD allocFd(alloc.fd);\n-\tret = ::ioctl(allocFd.get(), DMA_BUF_SET_NAME, name);\n-\tif (ret < 0) {\n-\t\tLOG(RPI, Error) << \"dmaHeap naming failure for \"\n-\t\t\t\t<< name;\n-\t\treturn {};\n-\t}\n-\n-\treturn allocFd;\n-}\n-\n-} /* namespace RPi */\n-\n-} /* namespace libcamera */\ndiff --git a/src/libcamera/pipeline/rpi/vc4/meson.build b/src/libcamera/pipeline/rpi/vc4/meson.build\nindex cdb049c5..b2b79735 100644\n--- a/src/libcamera/pipeline/rpi/vc4/meson.build\n+++ b/src/libcamera/pipeline/rpi/vc4/meson.build\n@@ -1,8 +1,5 @@\n # SPDX-License-Identifier: CC0-1.0\n \n-libcamera_sources += files([\n-    'dma_heaps.cpp',\n-    'vc4.cpp',\n-])\n+libcamera_sources += files(['vc4.cpp'])\n \n subdir('data')\ndiff --git a/src/libcamera/pipeline/rpi/vc4/vc4.cpp b/src/libcamera/pipeline/rpi/vc4/vc4.cpp\nindex 018cf488..410ecfaf 100644\n--- a/src/libcamera/pipeline/rpi/vc4/vc4.cpp\n+++ b/src/libcamera/pipeline/rpi/vc4/vc4.cpp\n@@ -12,12 +12,11 @@\n #include <libcamera/formats.h>\n \n #include \"libcamera/internal/device_enumerator.h\"\n+#include \"libcamera/internal/heap_allocator.h\"\n \n #include \"../common/pipeline_base.h\"\n #include \"../common/rpi_stream.h\"\n \n-#include \"dma_heaps.h\"\n-\n using namespace std::chrono_literals;\n \n namespace libcamera {\n@@ -87,7 +86,7 @@ public:\n \tRPi::Device<Isp, 4> isp_;\n \n \t/* DMAHEAP allocation helper. */\n-\tRPi::DmaHeap dmaHeap_;\n+\tHeapAllocator heapAllocator_;\n \tSharedFD lsTable_;\n \n \tstruct Config {\n@@ -296,7 +295,7 @@ int PipelineHandlerVc4::platformRegister(std::unique_ptr<RPi::CameraData> &camer\n {\n \tVc4CameraData *data = static_cast<Vc4CameraData *>(cameraData.get());\n \n-\tif (!data->dmaHeap_.isValid())\n+\tif (!data->heapAllocator_.isValid())\n \t\treturn -ENOMEM;\n \n \tMediaEntity *unicamImage = unicam->getEntityByName(\"unicam-image\");\n@@ -670,9 +669,9 @@ int Vc4CameraData::platformConfigureIpa(ipa::RPi::ConfigParams &params)\n {\n \tparams.ispControls = isp_[Isp::Input].dev()->controls();\n \n-\t/* Allocate the lens shading table via dmaHeap and pass to the IPA. */\n+\t/* Allocate the lens shading table via heapAllocator and pass to the IPA. */\n \tif (!lsTable_.isValid()) {\n-\t\tlsTable_ = SharedFD(dmaHeap_.alloc(\"ls_grid\", ipa::RPi::MaxLsGridSize));\n+\t\tlsTable_ = SharedFD(heapAllocator_.alloc(\"ls_grid\", ipa::RPi::MaxLsGridSize));\n \t\tif (!lsTable_.isValid())\n \t\t\treturn -ENOMEM;\n \n",
    "prefixes": [
        "libcamera-devel",
        "v6",
        "1/3"
    ]
}