Show a patch.

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

{
    "id": 13724,
    "url": "https://patchwork.libcamera.org/api/1.1/patches/13724/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/13724/",
    "project": {
        "id": 1,
        "url": "https://patchwork.libcamera.org/api/1.1/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": "<20210907145949.270824-1-umang.jain@ideasonboard.com>",
    "date": "2021-09-07T14:59:49",
    "name": "[libcamera-devel,v2] android: mm: cros_camera_buffer: Log failure error on cleanup",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "cfd811374a54476578c7236a999b76d81f58a017",
    "submitter": {
        "id": 86,
        "url": "https://patchwork.libcamera.org/api/1.1/people/86/?format=api",
        "name": "Umang Jain",
        "email": "umang.jain@ideasonboard.com"
    },
    "delegate": {
        "id": 12,
        "url": "https://patchwork.libcamera.org/api/1.1/users/12/?format=api",
        "username": "uajain",
        "first_name": "Umang",
        "last_name": "Jain",
        "email": "umang.jain@ideasonboard.com"
    },
    "mbox": "https://patchwork.libcamera.org/patch/13724/mbox/",
    "series": [
        {
            "id": 2490,
            "url": "https://patchwork.libcamera.org/api/1.1/series/2490/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=2490",
            "date": "2021-09-07T14:59:49",
            "name": "[libcamera-devel,v2] android: mm: cros_camera_buffer: Log failure error on cleanup",
            "version": 2,
            "mbox": "https://patchwork.libcamera.org/series/2490/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/13724/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/13724/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 82BCFBDC71\n\tfor <parsemail@patchwork.libcamera.org>;\n\tTue,  7 Sep 2021 14:59:59 +0000 (UTC)",
            "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id E5AFA6916E;\n\tTue,  7 Sep 2021 16:59:58 +0200 (CEST)",
            "from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id E952B60251\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue,  7 Sep 2021 16:59:57 +0200 (CEST)",
            "from perceval.ideasonboard.com (unknown [103.251.226.180])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id AA85824F;\n\tTue,  7 Sep 2021 16:59:56 +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=\"A9grPaBl\"; dkim-atps=neutral",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1631026797;\n\tbh=/vBnmOfn0o8xQoGo2dbK8Q2UfhU8kYH07uhi2MmnroM=;\n\th=From:To:Cc:Subject:Date:From;\n\tb=A9grPaBlQaoXGwYqEuhgxHr8rtf9uQsdTVuc4wGztaJcKjsh10ji1LKSBQJe2NQST\n\tvxORqxWdXNkDnzsJeUdrAR2iusWfX5hNoN3lKlPfYKEWcX1FJq/8jK0o0KPew+7gtj\n\thBb4tCb0z2LFJ9rzCqTESSm0/yJW7v3k0D6m12cU=",
        "From": "Umang Jain <umang.jain@ideasonboard.com>",
        "To": "libcamera-devel@lists.libcamera.org",
        "Date": "Tue,  7 Sep 2021 20:29:49 +0530",
        "Message-Id": "<20210907145949.270824-1-umang.jain@ideasonboard.com>",
        "X-Mailer": "git-send-email 2.31.1",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[libcamera-devel] [v2 PATCH] android: mm: cros_camera_buffer: Log\n\tfailure error on cleanup",
        "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>",
        "Errors-To": "libcamera-devel-bounces@lists.libcamera.org",
        "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"
    },
    "content": "Failure can still happen by CameraBufferManager during Unlock() and/or\nDeregister() of camera3Buffer handles. We should be logging those\nerrors as well.\n\nSigned-off-by: Umang Jain <umang.jain@ideasonboard.com>\n---\nChanges in v2:\n- Remove a debug log that creeped in by mistake\n\nI have been able to spot one of the failure which is happening on my\nin-developement async post-processing. It is due a failure in\nDeregister(). It is intermittent and non-fatal as far as I can see.\n\nHaving a failure log in HAL, apart from https://paste.debian.net/1210728/\nhelps to know the exact place from where the error is originating from\nlibcamera HAL.\n---\n src/android/mm/cros_camera_buffer.cpp | 18 ++++++++++++++----\n 1 file changed, 14 insertions(+), 4 deletions(-)",
    "diff": "diff --git a/src/android/mm/cros_camera_buffer.cpp b/src/android/mm/cros_camera_buffer.cpp\nindex ec45e04c..86770135 100644\n--- a/src/android/mm/cros_camera_buffer.cpp\n+++ b/src/android/mm/cros_camera_buffer.cpp\n@@ -73,10 +73,20 @@ CameraBuffer::Private::Private([[maybe_unused]] CameraBuffer *cameraBuffer,\n \n CameraBuffer::Private::~Private()\n {\n-\tif (mapped_)\n-\t\tbufferManager_->Unlock(handle_);\n-\tif (registered_)\n-\t\tbufferManager_->Deregister(handle_);\n+\tint ret;\n+\tif (mapped_) {\n+\t\tret = bufferManager_->Unlock(handle_);\n+\t\tif (ret != 0)\n+\t\t\tLOG(HAL, Error) << \"Failed to unlock buffer: \"\n+\t\t\t\t\t<< strerror(-ret);\n+\t}\n+\n+\tif (registered_) {\n+\t\tret = bufferManager_->Deregister(handle_);\n+\t\tif (ret != 0)\n+\t\t\tLOG(HAL, Error) << \"Failed to deregister buffer: \"\n+\t\t\t\t\t<< strerror(-ret);\n+\t}\n }\n \n unsigned int CameraBuffer::Private::numPlanes() const\n",
    "prefixes": [
        "libcamera-devel",
        "v2"
    ]
}