[{"id":22239,"web_url":"https://patchwork.libcamera.org/comment/22239/","msgid":"<1a32eebb-ea5b-90f3-2a23-057bc7e0ed3c@ideasonboard.com>","date":"2022-03-09T15:13:57","subject":"Re: [libcamera-devel] [PATCH v5 5/9] libcamera: camera_lens: Add\n\tfunction to fetch subdev controls","submitter":{"id":97,"url":"https://patchwork.libcamera.org/api/people/97/","name":"Nicolas Dufresne via libcamera-devel","email":"libcamera-devel@lists.libcamera.org"},"content":"Hi !\n\nThanks for the patch !\n\nOn 04/03/2022 00:49, Daniel Scally wrote:\n> Add a function to the CameraLens class to fetch the V4L2 controls\n> for its V4L2 subdev\n> \n> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n> Signed-off-by: Daniel Scally <djrscally@gmail.com>\n\nReviewed-by: Jean-Michel Hautbois <jeanmichel.hautbois@ideasonboard.com>\n\n> ---\n> Changes in v5:\n> \n> \t- None\n> \n> Changes since v4:\n> \n> \t- None\n> \n> Changes in v3:\n> \n> \t- s/sensor/lens\n> \n> \n>   include/libcamera/internal/camera_lens.h |  4 ++++\n>   src/libcamera/camera_lens.cpp            | 11 +++++++++++\n>   2 files changed, 15 insertions(+)\n> \n> diff --git a/include/libcamera/internal/camera_lens.h b/include/libcamera/internal/camera_lens.h\n> index 6f2ea1bc..64794294 100644\n> --- a/include/libcamera/internal/camera_lens.h\n> +++ b/include/libcamera/internal/camera_lens.h\n> @@ -12,6 +12,8 @@\n>   #include <libcamera/base/class.h>\n>   #include <libcamera/base/log.h>\n>   \n> +#include <libcamera/controls.h>\n> +\n>   namespace libcamera {\n>   \n>   class MediaEntity;\n> @@ -28,6 +30,8 @@ public:\n>   \n>   \tconst std::string &model() const { return model_; }\n>   \n> +\tconst ControlInfoMap &controls() const;\n> +\n>   protected:\n>   \tstd::string logPrefix() const override;\n>   \n> diff --git a/src/libcamera/camera_lens.cpp b/src/libcamera/camera_lens.cpp\n> index 189cb025..142390ed 100644\n> --- a/src/libcamera/camera_lens.cpp\n> +++ b/src/libcamera/camera_lens.cpp\n> @@ -139,4 +139,15 @@ std::string CameraLens::logPrefix() const\n>   \treturn \"'\" + entity_->name() + \"'\";\n>   }\n>   \n> +/**\n> + * \\fn CameraLens::controls()\n> + * \\brief Retrieve the V4L2 controls of the lens' subdev\n> + *\n> + * \\return A map of the V4L2 controls supported by the lens' driver\n> + */\n> +const ControlInfoMap &CameraLens::controls() const\n> +{\n> +\treturn subdev_->controls();\n> +}\n> +\n>   } /* namespace libcamera */","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 44F24BE08A\n\tfor <parsemail@patchwork.libcamera.org>;\n\tWed,  9 Mar 2022 15:14:02 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id F13D56118B;\n\tWed,  9 Mar 2022 16:14:01 +0100 (CET)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 574B760475\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed,  9 Mar 2022 16:14:00 +0100 (CET)","from [IPV6:2a01:e0a:169:7140:3734:287e:1a7f:9772] (unknown\n\t[IPv6:2a01:e0a:169:7140:3734:287e:1a7f:9772])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 10C338C4;\n\tWed,  9 Mar 2022 16:14:00 +0100 (CET)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1646838842;\n\tbh=slcjtqzPAvh7uLpeSaWVbKz8tV1PLdor9XNN3kSK2gc=;\n\th=Date:To:References:In-Reply-To:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:\n\tFrom;\n\tb=amJADNFA1rP/5Air/glUC5ygOP33K61h3jSF8HwzdnYKWOpBr0ZykKFW003gsCaRM\n\tUbLCTC4mSJaVPdUf3LA3zveGEcAvBG6e/+rfHepcHcthLARK08dnw5y5+URhmIHsLG\n\tDKAoGVSFsvTdAQ0vShP4ZZdgtaKVcpVeAx3FGm0H6uEdmVDD/Bc4iw3gNiUztpFWm2\n\tdl90CHot54tTqLCCXtLi5DHPoVYDwHn76IA2tNztHy47d22Hp59tKIK2OG1q42A2G7\n\t2N+eUpm4cxIWsgOUJIiTasgkha9HafONE8Eif20KtGRVEaqs+vtdWifMiErjiev0M3\n\t7nVmL6p1tS6Jg==","v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1646838840;\n\tbh=slcjtqzPAvh7uLpeSaWVbKz8tV1PLdor9XNN3kSK2gc=;\n\th=Date:Subject:To:References:From:In-Reply-To:From;\n\tb=Ubgu9HW35jBUc4gMQA39o4U/uIqb5RyywcDy1SGJAUx4wylpvgy+c8Miz33JbtS/w\n\tjeru+mQQoTRyFA6v0wCLUwqE4Oi9c9ZbF1hbTuyUOYoUjkZ4LHsvTvbo0yXYnKfBYw\n\tgYsWpVUM0xQtO7MKKCT1U2gImxooX7mYw4B15wm4="],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"Ubgu9HW3\"; dkim-atps=neutral","Message-ID":"<1a32eebb-ea5b-90f3-2a23-057bc7e0ed3c@ideasonboard.com>","Date":"Wed, 9 Mar 2022 16:13:57 +0100","MIME-Version":"1.0","User-Agent":"Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101\n\tThunderbird/91.5.0","Content-Language":"en-US","To":"Daniel Scally <djrscally@gmail.com>, libcamera-devel@lists.libcamera.org","References":"<20220303234956.1463551-1-djrscally@gmail.com>\n\t<20220303234956.1463551-6-djrscally@gmail.com>","In-Reply-To":"<20220303234956.1463551-6-djrscally@gmail.com>","Content-Type":"text/plain; charset=UTF-8; format=flowed","Content-Transfer-Encoding":"7bit","Subject":"Re: [libcamera-devel] [PATCH v5 5/9] libcamera: camera_lens: Add\n\tfunction to fetch subdev controls","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":"Jean-Michel Hautbois via libcamera-devel\n\t<libcamera-devel@lists.libcamera.org>","Reply-To":"Jean-Michel Hautbois <jeanmichel.hautbois@ideasonboard.com>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}}]