Show a patch.

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

{
    "id": 12231,
    "url": "https://patchwork.libcamera.org/api/patches/12231/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/12231/",
    "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": "<20210507124444.1089347-1-kieran.bingham@ideasonboard.com>",
    "date": "2021-05-07T12:44:44",
    "name": "[libcamera-devel] libcamera: controls: Remove merge assertion",
    "commit_ref": "414babb60b5453bf2a2d206088c0b4a1b48da15e",
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "1bbbf1060184e0f12c34840ed062baae18208d3e",
    "submitter": {
        "id": 4,
        "url": "https://patchwork.libcamera.org/api/people/4/?format=api",
        "name": "Kieran Bingham",
        "email": "kieran.bingham@ideasonboard.com"
    },
    "delegate": null,
    "mbox": "https://patchwork.libcamera.org/patch/12231/mbox/",
    "series": [
        {
            "id": 2013,
            "url": "https://patchwork.libcamera.org/api/series/2013/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=2013",
            "date": "2021-05-07T12:44:44",
            "name": "[libcamera-devel] libcamera: controls: Remove merge assertion",
            "version": 1,
            "mbox": "https://patchwork.libcamera.org/series/2013/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/12231/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/12231/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 7A101BF831\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri,  7 May 2021 12:44:52 +0000 (UTC)",
            "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id EBC67602BF;\n\tFri,  7 May 2021 14:44:51 +0200 (CEST)",
            "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 0EA44602BB\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri,  7 May 2021 14:44:50 +0200 (CEST)",
            "from Q.local (cpc89244-aztw30-2-0-cust3082.18-1.cable.virginm.net\n\t[86.31.172.11])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 7B4E22CF;\n\tFri,  7 May 2021 14:44:49 +0200 (CEST)"
        ],
        "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=\"nuifAkRO\"; dkim-atps=neutral",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1620391489;\n\tbh=H69quKw70i6kvFDAMlvqhDSLqDiR5egO5slYBWWLtYc=;\n\th=From:To:Cc:Subject:Date:From;\n\tb=nuifAkROwJRxtwFBocxoHV8mev12gOg9W4IMz19GEQ1rF8a5/khlKbJ1orRCzlabn\n\tQr7/dOJo+t8gnWRYeWgbS8MTQT5TMHhxUvCqpEAvOJfw42156HF4FDiiFKXtaDjS5x\n\tu4d1fEm28MF2G0ofGjyTv1+JXlCOY6RJfRPMumPc=",
        "From": "Kieran Bingham <kieran.bingham@ideasonboard.com>",
        "To": "libcamera devel <libcamera-devel@lists.libcamera.org>",
        "Date": "Fri,  7 May 2021 13:44:44 +0100",
        "Message-Id": "<20210507124444.1089347-1-kieran.bingham@ideasonboard.com>",
        "X-Mailer": "git-send-email 2.25.1",
        "MIME-Version": "1.0",
        "Subject": "[libcamera-devel] [PATCH] libcamera: controls: Remove merge\n\tassertion",
        "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=\"us-ascii\"",
        "Content-Transfer-Encoding": "7bit",
        "Errors-To": "libcamera-devel-bounces@lists.libcamera.org",
        "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"
    },
    "content": "The ControlList merge operation is protected with an ASSERT to guarantee\nthat the two lists are compatible.\n\nUnfortunately this assertion fails when we run IPAs in an isolated case\nas while the lists are compatible, the isolated IPA has a unique\ninstance of the id map. This breaks the pointer comparison, and the\nassertion fails with a false positive.\n\nRemove the assertion, leaving only a todo in it's place as this breaks\nactive users of the library.\n\nBugzilla: https://bugs.libcamera.org/show_bug.cgi?id=31\nSigned-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n---\n src/libcamera/controls.cpp | 12 +++++++++++-\n 1 file changed, 11 insertions(+), 1 deletion(-)",
    "diff": "diff --git a/src/libcamera/controls.cpp b/src/libcamera/controls.cpp\nindex b763148d4391..5aef4e7145bd 100644\n--- a/src/libcamera/controls.cpp\n+++ b/src/libcamera/controls.cpp\n@@ -890,7 +890,17 @@ ControlList::ControlList(const ControlInfoMap &infoMap, ControlValidator *valida\n  */\n void ControlList::merge(const ControlList &source)\n {\n-\tASSERT(idmap_ == source.idmap_);\n+\t/**\n+\t * \\todo: ASSERT that the current and source ControlList are derived\n+\t * from a compatible ControlIdMap, to prevent undefined behaviour due to\n+\t * id collisions.\n+\t *\n+\t * This can not currently be a direct pointer comparison due to the\n+\t * duplication of the ControlIdMaps in the isolated IPA use cases.\n+\t * Furthermore, manually checking each entry of the id map is identical\n+\t * is expensive.\n+\t * See https://bugs.libcamera.org/show_bug.cgi?id=31 for further details\n+\t */\n \n \tfor (const auto &ctrl : source) {\n \t\tif (contains(ctrl.first)) {\n",
    "prefixes": [
        "libcamera-devel"
    ]
}