Patch Detail
Show a patch.
GET /api/1.1/patches/17678/?format=api
{ "id": 17678, "url": "https://patchwork.libcamera.org/api/1.1/patches/17678/?format=api", "web_url": "https://patchwork.libcamera.org/patch/17678/", "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": "<20221024055543.116040-3-nicholas@rothemail.net>", "date": "2022-10-24T05:55:34", "name": "[libcamera-devel,02/11] Adds missing thread-safety annotations, lack of which break the build.", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": false, "hash": "be333057b7218ae3f599e181a7a22692226e737e", "submitter": { "id": 97, "url": "https://patchwork.libcamera.org/api/1.1/people/97/?format=api", "name": "Nicolas Dufresne via libcamera-devel", "email": "libcamera-devel@lists.libcamera.org" }, "delegate": null, "mbox": "https://patchwork.libcamera.org/patch/17678/mbox/", "series": [ { "id": 3575, "url": "https://patchwork.libcamera.org/api/1.1/series/3575/?format=api", "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=3575", "date": "2022-10-24T05:55:33", "name": "[libcamera-devel,01/11] Fixes Bug 156, which breaks libcamera on Android < 12.", "version": 1, "mbox": "https://patchwork.libcamera.org/series/3575/mbox/" } ], "comments": "https://patchwork.libcamera.org/api/patches/17678/comments/", "check": "pending", "checks": "https://patchwork.libcamera.org/api/patches/17678/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 442BBBD16B\n\tfor <parsemail@patchwork.libcamera.org>;\n\tMon, 24 Oct 2022 05:55:56 +0000 (UTC)", "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 09A7562EF2;\n\tMon, 24 Oct 2022 07:55:56 +0200 (CEST)", "from mail-ot1-x331.google.com (mail-ot1-x331.google.com\n\t[IPv6:2607:f8b0:4864:20::331])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 8883461F4C\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 24 Oct 2022 07:55:54 +0200 (CEST)", "by mail-ot1-x331.google.com with SMTP id\n\tr13-20020a056830418d00b0065601df69c0so5363192otu.7\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tSun, 23 Oct 2022 22:55:54 -0700 (PDT)", "from nroth-pc.attlocal.net\n\t([2600:1700:20:20c0:7bc3:aed3:676f:10a0])\n\tby smtp.gmail.com with ESMTPSA id\n\tx15-20020a9d628f000000b0066193df8edasm3980278otk.34.2022.10.23.22.55.52\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tSun, 23 Oct 2022 22:55:52 -0700 (PDT)" ], "DKIM-Signature": [ "v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1666590956;\n\tbh=rteEdorfeYf2WMIU0zZHBkRaXqRJ5MwkQvm/TECYYCs=;\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=2Mgd0vd+MvrZP1nyzaTVdl0dFkxvx/4XZnl8bVNZbH37r/v6wV8mABxei08chhlgV\n\tOM4arKksr6mti/yd/o+BVUYgUv5kPznMUnJz83RsirrXtFVzpURGh9jU6hvc+kiCy7\n\tryUBKY9n580W839NGyvekjmSqoSrX50qfZCXG1LCab9yZu+APSL9kvYSjYNm7q7jnR\n\tjtD3G1xYpAT8vl2HOdWRCdXlXAEmC6eCIfsdUwrm7VJ+tjJWmfyKoNowGyPgqaIPt2\n\t+Aog7WDy1oJpkr4+mUnUW54o5GOiRkbMs9QhEIUMzdzBBeQdskCgRD1u7WffJhQZxp\n\tx4PV7+yvKBloQ==", "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=rothemail-net.20210112.gappssmtp.com; s=20210112;\n\th=content-transfer-encoding:mime-version:reply-to:references\n\t:in-reply-to:message-id:date:subject:cc:to:from:from:to:cc:subject\n\t:date:message-id:reply-to;\n\tbh=S/Zpa27nkzDhV6rhVl67Z8VoZFYssjvzoo5aGuTsmsE=;\n\tb=KZX0qYAOV4nsyCzVY6akCOrm/uWIOoES+2zjVz7YezoYp/JXidFgiVvfOu5+/jxNNC\n\tqS1mo89WQQeENw09x2RzIJOGknW4D1cwf7ONnkYBllOjlbzbNDR+O0iLi9CngahVQTbb\n\t7DJFRPzmEPnxFroF5bhRVTwD8Cu7xAsBhbI0DEmxF3UxDYmCQFoTw2MqD3czOX7ELKGA\n\tm5f6CHTH9HVFwjb0bCMtfHtXHuhqcu3qL7PJtIdsbNPG/EcugFbdZUn4YLcWTiMAFfZk\n\td39RYGV9yoB8qYSoaYzcRpE4/5pwZid2WZTXzEWhFS9s1N9z+mvsssSeXebeRaphWYog\n\tOfGg==" ], "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (2048-bit key; \n\tunprotected)\n\theader.d=rothemail-net.20210112.gappssmtp.com\n\theader.i=@rothemail-net.20210112.gappssmtp.com header.b=\"KZX0qYAO\"; \n\tdkim-atps=neutral", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20210112;\n\th=content-transfer-encoding:mime-version:reply-to:references\n\t:in-reply-to:message-id:date:subject:cc:to:from:x-gm-message-state\n\t:from:to:cc:subject:date:message-id:reply-to;\n\tbh=S/Zpa27nkzDhV6rhVl67Z8VoZFYssjvzoo5aGuTsmsE=;\n\tb=pKFQbQSaxmJZ7zA1/gaj4TY8izBK4wLAFZbjN+0sYtfr1vXW1IUYae4+0r9x5Oxu4R\n\teAyWclsGyu821jUEdQ9mZZ8GGFuCNW+mRCp4n9QaiLgOKo+u2glCcGMYnqI5mmFF5qme\n\tlKbIYKklvkP/lCo+/68E0OUwZJN/45ABwagLNuGVu2PB98P9rkhS4o69HJ/d6Ez7aUb7\n\ts7efsIxbqdh7OSYsubcqGnnYDkpiuADoRSYPIdZxxC/4vanJhpF+lg1pBaM3DMq2nE89\n\tgeZ4zEPbGPBJ8azgAZw+dmJ1l0vsXqx9ED2vIbh27yHAbyrgTpjSvwgFgd7u3GX2cKm3\n\t7lWg==", "X-Gm-Message-State": "ACrzQf0n2eMipya00LcII8wxSPcCXF826f+sLawmdD4Mlsa20zPoVeGr\n\t964McoCgedEL7uYzxEP5gzwXsJcEXUNT+I8R", "X-Google-Smtp-Source": "AMsMyM538Dc5FqnVrRhivifgZp5ZtDhXNUz7EzgknWGV26PHI5Lv39sdk0HKR7W7gGQ0DzQg+wlexw==", "X-Received": "by 2002:a05:6830:16c7:b0:661:b465:6e1e with SMTP id\n\tl7-20020a05683016c700b00661b4656e1emr15675370otr.124.1666590952599; \n\tSun, 23 Oct 2022 22:55:52 -0700 (PDT)", "To": "libcamera-devel@lists.libcamera.org", "Date": "Mon, 24 Oct 2022 00:55:34 -0500", "Message-Id": "<20221024055543.116040-3-nicholas@rothemail.net>", "X-Mailer": "git-send-email 2.34.1", "In-Reply-To": "<20221024055543.116040-1-nicholas@rothemail.net>", "References": "<20221024055543.116040-1-nicholas@rothemail.net>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "Subject": "[libcamera-devel] [PATCH 02/11] Adds missing thread-safety\n\tannotations, lack of which break the build.", "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": "Nicholas Roth via libcamera-devel <libcamera-devel@lists.libcamera.org>", "Reply-To": "libcamera-devel@lists.libcamera.org", "Cc": "nicholas@rothemail.net", "Errors-To": "libcamera-devel-bounces@lists.libcamera.org", "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>" }, "content": "From: Nicholas Roth <nicholas@rothemail.net>\n\n../src/ipa/raspberrypi/controller/metadata.h:108:31: error: mutex 'mutex_' is still held at the end of function [-Werror,-Wthread-safety-analysis]\n void lock() { mutex_.lock(); }\n ^\n../src/ipa/raspberrypi/controller/metadata.h:108:23: note: mutex acquired here\n void lock() { mutex_.lock(); }\n ^\n../src/ipa/raspberrypi/controller/metadata.h:109:25: error: releasing mutex 'mutex_' that was not held [-Werror,-Wthread-safety-analysis]\n void unlock() { mutex_.unlock(); }\n ^\n---\n src/ipa/raspberrypi/controller/metadata.h | 8 +++++---\n 1 file changed, 5 insertions(+), 3 deletions(-)", "diff": "diff --git a/src/ipa/raspberrypi/controller/metadata.h b/src/ipa/raspberrypi/controller/metadata.h\nindex 0f7ebfaf..870b6e26 100644\n--- a/src/ipa/raspberrypi/controller/metadata.h\n+++ b/src/ipa/raspberrypi/controller/metadata.h\n@@ -13,9 +13,11 @@\n #include <mutex>\n #include <string>\n \n+#include <libcamera/base/thread_annotations.h>\n+\n namespace RPiController {\n \n-class Metadata\n+class LIBCAMERA_TSA_CAPABILITY(\"mutex\") Metadata\n {\n public:\n \tMetadata() = default;\n@@ -103,8 +105,8 @@ public:\n \t * locks with the standard lock classes.\n \t * e.g. std::lock_guard<RPiController::Metadata> lock(metadata)\n \t */\n-\tvoid lock() { mutex_.lock(); }\n-\tvoid unlock() { mutex_.unlock(); }\n+\tvoid lock() LIBCAMERA_TSA_ACQUIRE() { mutex_.lock(); }\n+\tvoid unlock() LIBCAMERA_TSA_RELEASE() { mutex_.unlock(); }\n \n private:\n \tmutable std::mutex mutex_;\n", "prefixes": [ "libcamera-devel", "02/11" ] }