From patchwork Sun Dec 26 23:12:53 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laurent Pinchart X-Patchwork-Id: 15219 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 F140CBF415 for ; Sun, 26 Dec 2021 23:13:07 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 6BE2660914; Mon, 27 Dec 2021 00:13:07 +0100 (CET) Authentication-Results: lancelot.ideasonboard.com; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="oT92iGS4"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 67D94608E6 for ; Mon, 27 Dec 2021 00:13:05 +0100 (CET) Received: from pendragon.lan (62-78-145-57.bb.dnainternet.fi [62.78.145.57]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id ECFDEA15 for ; Mon, 27 Dec 2021 00:13:04 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1640560385; bh=Oq6iZh0upGb9HP+jSMicxVhhN62K/swsffXj9mT6S1I=; h=From:To:Subject:Date:From; b=oT92iGS4UbPMSmYQuBDSdD+0E78xcZeShgpUghnUDKmdxd317kYNzoQmOBhvl/rRl /sUvqT5z54OzIZn0w6HxDN7ObbbJSyoo85DMeEuVzjZGbufvRFoaim7dy2aD8YdxXZ 5L0VWij2iVsLKMpxLhziD99/+/6y4mZorDHBa7bI= From: Laurent Pinchart To: libcamera-devel@lists.libcamera.org Date: Mon, 27 Dec 2021 01:12:53 +0200 Message-Id: <20211226231255.18653-1-laurent.pinchart@ideasonboard.com> X-Mailer: git-send-email 2.32.0 MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH v2 0/2] libcamera: Small cleanups for pipeline handler locking 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" Hello, Those two small patches clean up the MediaDevice and PipelineHandler locking. The goal is to prepare for concurrent usage of multiple cameras exposed by the same pipeline handler (on platforms that support this), and to fix a thread-safety issue. Please see individual patches for details. Laurent Pinchart (2): libcamera: media_device: Move recursive lock handling to pipeline handler libcamera: pipeline_handler: Make lock() and unlock() thread-safe include/libcamera/internal/media_device.h | 1 - include/libcamera/internal/pipeline_handler.h | 4 ++++ src/libcamera/media_device.cpp | 14 +------------- src/libcamera/pipeline_handler.cpp | 18 +++++++++++++++++- 4 files changed, 22 insertions(+), 15 deletions(-) base-commit: 57c2171238d2be832fcfc709bc126e47bb198240