From patchwork Sun Jun 28 23:19:29 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Laurent Pinchart X-Patchwork-Id: 8488 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 5DDE7C2E66 for ; Sun, 28 Jun 2020 23:19:48 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id ED3C260AF7; Mon, 29 Jun 2020 01:19:47 +0200 (CEST) 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="aw4rzMni"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id C11C0609C9 for ; Mon, 29 Jun 2020 01:19:42 +0200 (CEST) Received: from pendragon.bb.dnainternet.fi (81-175-216-236.bb.dnainternet.fi [81.175.216.236]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 53BD29DA; Mon, 29 Jun 2020 01:19:42 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1593386382; bh=tmEt+A7Se7qLan6i4z3XNJKVwbzk+X8q7l7tJ79gNgM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=aw4rzMniX5K+WDbTZSJlqaGRxZ7RvN18b8JLy3I6KnO2LAnWarSms7QNiqmKNvcqV kgDSfiEDLkiJnLF8C1Y4HAbgtusRy9Z0RRb7nNnmg8spEEzXb2Uz45QwoPXL/amSU8 bxEiJoTFtYkkqSUj3U+cTLtFL41qJMCTzvc4fMaA= From: Laurent Pinchart To: libcamera-devel@lists.libcamera.org Date: Mon, 29 Jun 2020 02:19:29 +0300 Message-Id: <20200628231934.29025-5-laurent.pinchart@ideasonboard.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200628231934.29025-1-laurent.pinchart@ideasonboard.com> References: <20200628231934.29025-1-laurent.pinchart@ideasonboard.com> MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH v1 4/9] libcamera: pipeline: raspberrypi: Constify parameter to StaggeredCtrl::set() 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" The controls parameter of StaggeredCtrl::set(), passed by reference, is not modified by the function. Make it const. Signed-off-by: Laurent Pinchart Reviewed-by: Niklas Söderlund Reviewed-by: Naushir Patuck Reviewed-by: Jacopo Mondi --- src/libcamera/pipeline/raspberrypi/staggered_ctrl.cpp | 2 +- src/libcamera/pipeline/raspberrypi/staggered_ctrl.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libcamera/pipeline/raspberrypi/staggered_ctrl.cpp b/src/libcamera/pipeline/raspberrypi/staggered_ctrl.cpp index 416cb9467147..0572acc93d63 100644 --- a/src/libcamera/pipeline/raspberrypi/staggered_ctrl.cpp +++ b/src/libcamera/pipeline/raspberrypi/staggered_ctrl.cpp @@ -91,7 +91,7 @@ bool StaggeredCtrl::set(std::initializer_list return true; } -bool StaggeredCtrl::set(ControlList &controls) +bool StaggeredCtrl::set(const ControlList &controls) { std::lock_guard lock(lock_); diff --git a/src/libcamera/pipeline/raspberrypi/staggered_ctrl.h b/src/libcamera/pipeline/raspberrypi/staggered_ctrl.h index 98994a6177e1..382fa31a6853 100644 --- a/src/libcamera/pipeline/raspberrypi/staggered_ctrl.h +++ b/src/libcamera/pipeline/raspberrypi/staggered_ctrl.h @@ -41,7 +41,7 @@ public: bool set(uint32_t ctrl, int32_t value); bool set(std::initializer_list> ctrlList); - bool set(ControlList &controls); + bool set(const ControlList &controls); int write();