From patchwork Wed Dec 1 07:07:28 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hirokazu Honda X-Patchwork-Id: 14938 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id 23331C324F for ; Wed, 1 Dec 2021 07:07:59 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id BAAEA6072C; Wed, 1 Dec 2021 08:07:58 +0100 (CET) Authentication-Results: lancelot.ideasonboard.com; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="k4TjDi2a"; dkim-atps=neutral Received: from mail-pg1-x531.google.com (mail-pg1-x531.google.com [IPv6:2607:f8b0:4864:20::531]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 718DA60723 for ; Wed, 1 Dec 2021 08:07:57 +0100 (CET) Received: by mail-pg1-x531.google.com with SMTP id 137so15552801pgg.3 for ; Tue, 30 Nov 2021 23:07:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=uJYG3Nusw/zJT2sBNaxIou0h0BcaN6bUP3w8FXeB2XE=; b=k4TjDi2awPogPpjObRy0CFdaH1tBwYmb8XkxyPrBC8AtVVPG+9OeZ8e/i1UfE26G3J XSgv6QxgXLANF1Xwv9qzOmsZpj1Kz4dMv6gAD/ZgqdZEKUjmkw2kx+Rfnhsb4rjsh1Kp 8xL16RUqNeS9cHcuNqjFyqhmZqBUXj7oH0Br4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=uJYG3Nusw/zJT2sBNaxIou0h0BcaN6bUP3w8FXeB2XE=; b=WTxOOP/8W12HBjBUzsp3VuG+cxFIbQXrZzLAAvndrBBomykpX1Rl0os1EL4gFRgkIp n7fQt7sdxheM5jmnmWGzcFW13vshCuJPQ4KO9/wVhH0gDnMWN+Fc9di3TvhJ5IIrK6Wm piddy5JlH3Z3xayK8nua2Uwjh/ClSCnXubU0u0TfJLBUX5dKGi/GloErUTkjxnPGknU/ HIRA2uYVZuO2Er0ppgp5z4ptXlxgDv5XpBEJdDyqNtssd2xSK3PLuQ/0eI2iSVgjUl06 52kGXCATQhSauJzUPyxHkI0ZUj1YLEAtUw8kZhBf3Dh3DA51Rcy+Qi2N8ro1dGz/Rh9q LM5Q== X-Gm-Message-State: AOAM532zxviJqIToqx3B1xIPJdSqqoMXdfQKXWntUYGi6zyg2Ko6Fh/2 rvfd8mqa2IfnsdG2dWck0mNP5fgj65Mg+A== X-Google-Smtp-Source: ABdhPJznpu563TVUSykSU23itZEgDzhM0DizlEdsGg40NurPZMzsKyCLkazq7YOg7qF3pzoxjXnujA== X-Received: by 2002:a63:34c5:: with SMTP id b188mr3410918pga.64.1638342475764; Tue, 30 Nov 2021 23:07:55 -0800 (PST) Received: from hiroh2.tok.corp.google.com ([2401:fa00:8f:203:3892:a049:59ba:c772]) by smtp.gmail.com with ESMTPSA id m10sm16598962pgv.75.2021.11.30.23.07.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 30 Nov 2021 23:07:55 -0800 (PST) From: Hirokazu Honda To: libcamera-devel@lists.libcamera.org Date: Wed, 1 Dec 2021 16:07:28 +0900 Message-Id: <20211201070728.3114247-13-hiroh@chromium.org> X-Mailer: git-send-email 2.34.0.rc2.393.gf8c9666880-goog In-Reply-To: <20211201070728.3114247-1-hiroh@chromium.org> References: <20211201070728.3114247-1-hiroh@chromium.org> MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH v4 12/12] android: camera_request: Add thread safety annotation X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" This applies clang thread safety annotation to Camera3RequestDescriptor. Signed-off-by: Hirokazu Honda Reviewed-by: Laurent Pinchart --- src/android/camera_request.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/android/camera_request.h b/src/android/camera_request.h index 887dbe86..d9b04f16 100644 --- a/src/android/camera_request.h +++ b/src/android/camera_request.h @@ -57,7 +57,8 @@ public: }; /* Keeps track of streams requiring post-processing. */ - std::map pendingStreamsToProcess_; + std::map pendingStreamsToProcess_ + LIBCAMERA_TSA_GUARDED_BY(streamsProcessMutex_); libcamera::Mutex streamsProcessMutex_; Camera3RequestDescriptor(libcamera::Camera *camera,