{"id":24344,"url":"https://patchwork.libcamera.org/api/patches/24344/?format=json","web_url":"https://patchwork.libcamera.org/patch/24344/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/projects/1/?format=json","name":"libcamera","link_name":"libcamera","list_id":"libcamera_core","list_email":"libcamera-devel@lists.libcamera.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20250912-flash_reco-v2-3-d5bb80a2e619@emfend.at>","date":"2025-09-12T07:13:22","name":"[v2,3/5] Documentation: Add flash driver requirements","commit_ref":null,"pull_url":null,"state":"new","archived":false,"hash":"35e8d133e22c3c65cbd7c4dfd680bc460e47268a","submitter":{"id":134,"url":"https://patchwork.libcamera.org/api/people/134/?format=json","name":"Matthias Fend","email":"matthias.fend@emfend.at"},"delegate":null,"mbox":"https://patchwork.libcamera.org/patch/24344/mbox/","series":[{"id":5437,"url":"https://patchwork.libcamera.org/api/series/5437/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=5437","date":"2025-09-12T07:13:19","name":"Support for v4l2 flash devices","version":2,"mbox":"https://patchwork.libcamera.org/series/5437/mbox/"}],"comments":"https://patchwork.libcamera.org/api/patches/24344/comments/","check":"pending","checks":"https://patchwork.libcamera.org/api/patches/24344/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 C4057C328C\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri, 12 Sep 2025 07:13:38 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id EC01169371;\n\tFri, 12 Sep 2025 09:13:33 +0200 (CEST)","from lx20.hoststar.hosting (lx20.hoststar.hosting [168.119.41.54])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 705806936E\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 12 Sep 2025 09:13:29 +0200 (CEST)","from 194-208-208-245.tele.net ([194.208.208.245]:58477\n\thelo=[127.0.1.1]) by lx20.hoststar.hosting with esmtpsa (TLS1.3) tls\n\tTLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.93)\n\t(envelope-from <matthias.fend@emfend.at>)\n\tid 1uwxyK-008cBW-J9; Fri, 12 Sep 2025 09:13:28 +0200"],"Authentication-Results":"lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=emfend.at header.i=@emfend.at\n\theader.b=\"ctk1UdkJ\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=emfend.at;\n\ts=mail;\n\th=Cc:To:In-Reply-To:References:Message-Id:Content-Transfer-Encoding:\n\tContent-Type:MIME-Version:Subject:Date:From:Sender:Reply-To:Content-ID:\n\tContent-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc\n\t:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe:\n\tList-Post:List-Owner:List-Archive;\n\tbh=hrmycKM5vz19EHoPbU8uUhqnMarL+q4v19l4pkGwgEs=;\n\tb=ctk1UdkJW4rEaA8pI1seDi6/2A\n\t8EP3nd8PUr8InuWKC70Rk9zxSsH6I3ekK4JYKFoJNS+5R/B/OpUJKYZJ95Cv2CglN1roHtzZSxDYn\n\t9Ew/FInP72vs5jj0W6SiKuPcjBPjRAdHCFxk1+OO/XgJ9VjrFlKXFgGLyD04Q/5qJLWc=;","From":"Matthias Fend <matthias.fend@emfend.at>","Date":"Fri, 12 Sep 2025 09:13:22 +0200","Subject":"[PATCH v2 3/5] Documentation: Add flash driver requirements","MIME-Version":"1.0","Content-Type":"text/plain; charset=\"utf-8\"","Content-Transfer-Encoding":"7bit","Message-Id":"<20250912-flash_reco-v2-3-d5bb80a2e619@emfend.at>","References":"<20250912-flash_reco-v2-0-d5bb80a2e619@emfend.at>","In-Reply-To":"<20250912-flash_reco-v2-0-d5bb80a2e619@emfend.at>","To":"libcamera-devel@lists.libcamera.org","Cc":"Matthias Fend <matthias.fend@emfend.at>","X-Mailer":"b4 0.14.2","X-Spam-Score":"-0.7","X-Spam-Bar":"/","X-Spam-Report":"Spam detection software,\n\trunning on the system \"lx20.hoststar.hosting\", \n\thas NOT identified this incoming email as spam.  The original\n\tmessage has been attached to this so you can view it or label\n\tsimilar future email.  If you have any questions, see\n\tthe administrator of that system for details.\n\tContent preview: Add a class to model camera flash devices. Currently,\n\tonly\n\tv4l2 flash devices are supported. The v4l2 flash devices are\n\timplemented\n\tsimilar to the camera lenses. Signed-off-by: Matthias Fend\n\t<matthias.fend@emfend.at>\n\t--- include/libcamera/internal/camera_flash.h | 72 ++++++++\n\tinclude/libcamera/internal/camera_sensor.h\n\t| 2 + src/libcamera/camera_flash.cpp | 249 [...] \n\tContent analysis details:   (-0.7 points, 5.0 required)\n\tpts rule name              description\n\t---- ----------------------\n\t--------------------------------------------------\n\t0.0 URIBL_BLOCKED ADMINISTRATOR NOTICE: The query to URIBL was\n\tblocked.  See\n\thttp://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block\n\tfor more information. [URIs: meson.build]\n\t0.0 URIBL_DBL_BLOCKED_OPENDNS ADMINISTRATOR NOTICE: The query to\n\tdbl.spamhaus.org was blocked due to usage\n\tof an open resolver. See https://www.spamhaus.org/returnc/pub/\n\t[URIs: meson.build]\n\t0.0 URIBL_ZEN_BLOCKED_OPENDNS ADMINISTRATOR NOTICE: The query to\n\tzen.spamhaus.org was blocked due to usage\n\tof an open resolver. See https://www.spamhaus.org/returnc/pub/\n\t[URIs: meson.build]\n\t-1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP\n\t0.0 Local_hs1_NotHoststar  Sender is not from hoststar.ch|de|com\n\t0.0 TVD_RCVD_IP            Message was received from an IP address\n\t0.0 KAM_DMARC_STATUS Test Rule for DKIM or SPF Failure with Strict\n\tAlignment\n\t0.2 KAM_LOTSOFHASH         Emails with lots of hash-like gibberish","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>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"},"content":"Document the requirements for the v4l2 flash device drivers required by\nlibcamera.\n\nSigned-off-by: Matthias Fend <matthias.fend@emfend.at>\n---\n Documentation/documentation-contents.rst    |  1 +\n Documentation/flash_driver_requirements.rst | 40 +++++++++++++++++++++++++++++\n Documentation/index.rst                     |  1 +\n Documentation/meson.build                   |  1 +\n 4 files changed, 43 insertions(+)","diff":"diff --git a/Documentation/documentation-contents.rst b/Documentation/documentation-contents.rst\nindex 5c1118493745692f2521bced9dab48098585c39e..be7415cde42f55ae5f9da20bc9211227b8f8658c 100644\n--- a/Documentation/documentation-contents.rst\n+++ b/Documentation/documentation-contents.rst\n@@ -22,6 +22,7 @@\n    * :doc:`/internal-api-html/index`\n    * |\n    * **Documentation for System Integrators**\n+   * :doc:`/flash_driver_requirements`\n    * :doc:`/lens_driver_requirements`\n    * :doc:`/sensor_driver_requirements`\n \ndiff --git a/Documentation/flash_driver_requirements.rst b/Documentation/flash_driver_requirements.rst\nnew file mode 100644\nindex 0000000000000000000000000000000000000000..b4a1b4866e651c506203af7089b5634808de5ab7\n--- /dev/null\n+++ b/Documentation/flash_driver_requirements.rst\n@@ -0,0 +1,40 @@\n+.. SPDX-License-Identifier: CC-BY-SA-4.0\n+\n+.. include:: documentation-contents.rst\n+\n+.. _flash-driver-requirements:\n+\n+Flash Driver Requirements\n+=========================\n+\n+libcamera handles V4L2 flash devices in the CameraFlash class and defines\n+a consistent interface through its API towards other library components.\n+\n+The CameraFlash class uses the V4L2 subdev kernel API to interface with the\n+camera flash through a sub-device exposed to userspace by the V4L2 flash driver.\n+\n+In order for libcamera to be fully operational and provide all the required\n+information to interface with the camera flash to applications and pipeline\n+handlers, the driver must support a set of mandatory features.\n+\n+Mandatory Requirements\n+----------------------\n+\n+The flash driver is assumed to be fully compliant with the V4L2 specification.\n+\n+The flash driver shall support the following V4L2 controls:\n+\n+* `V4L2_CID_FLASH_LED_MODE`_\n+* `V4L2_CID_FLASH_STROBE_SOURCE`_\n+* `V4L2_CID_FLASH_STROBE`_\n+* `V4L2_CID_FLASH_TIMEOUT`_\n+* `V4L2_CID_FLASH_INTENSITY`_\n+* `V4L2_CID_FLASH_TORCH_INTENSITY`_\n+\n+.. _V4L2_CID_FLASH_LED_MODE: https://www.kernel.org/doc/html/latest/userspace-api/media/v4l/ext-ctrls-flash.html\n+.. _V4L2_CID_FLASH_STROBE_SOURCE: https://www.kernel.org/doc/html/latest/userspace-api/media/v4l/ext-ctrls-flash.html\n+.. _V4L2_CID_FLASH_STROBE: https://www.kernel.org/doc/html/latest/userspace-api/media/v4l/ext-ctrls-flash.html\n+.. _V4L2_CID_FLASH_TIMEOUT: https://www.kernel.org/doc/html/latest/userspace-api/media/v4l/ext-ctrls-flash.html\n+.. _V4L2_CID_FLASH_INTENSITY: https://www.kernel.org/doc/html/latest/userspace-api/media/v4l/ext-ctrls-flash.html\n+.. _V4L2_CID_FLASH_TORCH_INTENSITY: https://www.kernel.org/doc/html/latest/userspace-api/media/v4l/ext-ctrls-flash.html\n+\ndiff --git a/Documentation/index.rst b/Documentation/index.rst\nindex 251112fbdf5f075b3e5c064d7230b9ad2c23b587..7ed56c17787fc643ef74cc35ef5b5db7d29eb18d 100644\n--- a/Documentation/index.rst\n+++ b/Documentation/index.rst\n@@ -14,6 +14,7 @@\n    Camera Sensor Model <camera-sensor-model>\n    Environment variables <environment_variables>\n    Feature Requirements <feature_requirements>\n+   Flash driver requirements <flash_driver_requirements>\n    IPA Writer's guide <guides/ipa>\n    Lens driver requirements <lens_driver_requirements>\n    libcamera Architecture <libcamera_architecture>\ndiff --git a/Documentation/meson.build b/Documentation/meson.build\nindex a8d4afc01dd154546d107b49bc322a993e4d78bd..965b33c60b031610251efbe59abb1682cb714d4a 100644\n--- a/Documentation/meson.build\n+++ b/Documentation/meson.build\n@@ -159,6 +159,7 @@ if sphinx.found()\n         'documentation-contents.rst',\n         'environment_variables.rst',\n         'feature_requirements.rst',\n+        'flash_driver_requirements.rst',\n         'guides/application-developer.rst',\n         'guides/ipa.rst',\n         'guides/pipeline-handler.rst',\n","prefixes":["v2","3/5"]}