Show a patch.

GET /api/1.1/patches/19812/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 19812,
    "url": "https://patchwork.libcamera.org/api/1.1/patches/19812/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/19812/",
    "project": {
        "id": 1,
        "url": "https://patchwork.libcamera.org/api/1.1/projects/1/?format=api",
        "name": "libcamera",
        "link_name": "libcamera",
        "list_id": "libcamera_core",
        "list_email": "libcamera-devel@lists.libcamera.org",
        "web_url": "",
        "scm_url": "",
        "webscm_url": ""
    },
    "msgid": "<20240326112419.503286-12-mzamazal@redhat.com>",
    "date": "2024-03-26T11:24:14",
    "name": "[RFC,11/11] config: Add global configuration documentation",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": false,
    "hash": "acf416281a4078959720548867e73d2cfefcefc0",
    "submitter": {
        "id": 177,
        "url": "https://patchwork.libcamera.org/api/1.1/people/177/?format=api",
        "name": "Milan Zamazal",
        "email": "mzamazal@redhat.com"
    },
    "delegate": null,
    "mbox": "https://patchwork.libcamera.org/patch/19812/mbox/",
    "series": [
        {
            "id": 4241,
            "url": "https://patchwork.libcamera.org/api/1.1/series/4241/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=4241",
            "date": "2024-03-26T11:24:03",
            "name": "Add global configuration file",
            "version": 1,
            "mbox": "https://patchwork.libcamera.org/series/4241/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/19812/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/19812/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 1F5F7C32C9\n\tfor <parsemail@patchwork.libcamera.org>;\n\tTue, 26 Mar 2024 11:26:35 +0000 (UTC)",
            "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id A8EC363361;\n\tTue, 26 Mar 2024 12:26:34 +0100 (CET)",
            "from us-smtp-delivery-124.mimecast.com\n\t(us-smtp-delivery-124.mimecast.com [170.10.133.124])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 4758A6334D\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 26 Mar 2024 12:26:25 +0100 (CET)",
            "from mimecast-mx02.redhat.com (mx-ext.redhat.com [66.187.233.73])\n\tby relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3,\n\tcipher=TLS_AES_256_GCM_SHA384) id us-mta-534-38tTpm7bPEOxGUbUp4-ebw-1;\n\tTue, 26 Mar 2024 07:26:22 -0400",
            "from smtp.corp.redhat.com\n\t(int-mx01.intmail.prod.int.rdu2.redhat.com [10.11.54.1])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\tkey-exchange X25519 server-signature RSA-PSS (2048 bits)\n\tserver-digest SHA256) (No client certificate requested)\n\tby mimecast-mx02.redhat.com (Postfix) with ESMTPS id 85957382C462\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 26 Mar 2024 11:26:22 +0000 (UTC)",
            "from nuthatch.brq.redhat.com (unknown [10.43.17.39])\n\tby smtp.corp.redhat.com (Postfix) with ESMTP id 10B5B3C54;\n\tTue, 26 Mar 2024 11:26:21 +0000 (UTC)"
        ],
        "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=redhat.com header.i=@redhat.com\n\theader.b=\"MGAXQpJI\"; dkim-atps=neutral",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com;\n\ts=mimecast20190719; t=1711452384;\n\th=from:from:reply-to:subject:subject:date:date:message-id:message-id:\n\tto:to:cc:cc:mime-version:mime-version:content-type:content-type:\n\tcontent-transfer-encoding:content-transfer-encoding:\n\tin-reply-to:in-reply-to:references:references;\n\tbh=ZZoxr7e+9DLjwMQCQu7w3y8F5CLpNlUzgOTZZGgNfug=;\n\tb=MGAXQpJIO2PolJwjdL58shCxIQBwkVYpabZSEBwENfBzth81xGmEaF6eQ1ZCqsU4xpg5rw\n\trwLWxaMpnD2fsMmuWCQgaAbkldPEOE56GcZVxftE6ZtsW2klMO+bh/4lHvfiqbWclwy5SO\n\trQv3amAHmV7+d9SVXLDLcSPJqOggcr0=",
        "X-MC-Unique": "38tTpm7bPEOxGUbUp4-ebw-1",
        "From": "Milan Zamazal <mzamazal@redhat.com>",
        "To": "libcamera-devel@lists.libcamera.org",
        "Cc": "Milan Zamazal <mzamazal@redhat.com>",
        "Subject": "[RFC PATCH 11/11] config: Add global configuration documentation",
        "Date": "Tue, 26 Mar 2024 12:24:14 +0100",
        "Message-ID": "<20240326112419.503286-12-mzamazal@redhat.com>",
        "In-Reply-To": "<20240326112419.503286-1-mzamazal@redhat.com>",
        "References": "<20240326112419.503286-1-mzamazal@redhat.com>",
        "MIME-Version": "1.0",
        "X-Scanned-By": "MIMEDefang 3.4.1 on 10.11.54.1",
        "X-Mimecast-Spam-Score": "0",
        "X-Mimecast-Originator": "redhat.com",
        "Content-Transfer-Encoding": "8bit",
        "Content-Type": "text/plain; charset=\"US-ASCII\"; x-default=true",
        "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": "WIP\n\nSigned-off-by: Milan Zamazal <mzamazal@redhat.com>\n---\n Documentation/index.rst                       |  2 +-\n Documentation/meson.build                     |  2 +-\n ...ariables.rst => runtime_configuration.rst} | 56 +++++++++++++++++--\n 3 files changed, 54 insertions(+), 6 deletions(-)\n rename Documentation/{environment_variables.rst => runtime_configuration.rst} (76%)",
    "diff": "diff --git a/Documentation/index.rst b/Documentation/index.rst\nindex 5442ae75..aa277b85 100644\n--- a/Documentation/index.rst\n+++ b/Documentation/index.rst\n@@ -19,7 +19,7 @@\n    Pipeline Handler Writer's Guide <guides/pipeline-handler>\n    IPA Writer's guide <guides/ipa>\n    Tracing guide <guides/tracing>\n-   Environment variables <environment_variables>\n+   Runtime configuration <runtime_configuration>\n    Sensor driver requirements <sensor_driver_requirements>\n    Lens driver requirements <lens_driver_requirements>\n    Python Bindings <python-bindings>\ndiff --git a/Documentation/meson.build b/Documentation/meson.build\nindex 3872e0a8..f8ca63eb 100644\n--- a/Documentation/meson.build\n+++ b/Documentation/meson.build\n@@ -70,7 +70,6 @@ if sphinx.found()\n         'conf.py',\n         'contributing.rst',\n         'docs.rst',\n-        'environment_variables.rst',\n         'guides/application-developer.rst',\n         'guides/introduction.rst',\n         'guides/ipa.rst',\n@@ -79,6 +78,7 @@ if sphinx.found()\n         'index.rst',\n         'lens_driver_requirements.rst',\n         'python-bindings.rst',\n+        'runtime_configuration.rst',\n         'sensor_driver_requirements.rst',\n         'software-isp-benchmarking.rst',\n        '../README.rst',\ndiff --git a/Documentation/environment_variables.rst b/Documentation/runtime_configuration.rst\nsimilarity index 76%\nrename from Documentation/environment_variables.rst\nrename to Documentation/runtime_configuration.rst\nindex a9b230bc..75bf3530 100644\n--- a/Documentation/environment_variables.rst\n+++ b/Documentation/runtime_configuration.rst\n@@ -1,10 +1,58 @@\n .. SPDX-License-Identifier: CC-BY-SA-4.0\n \n-Environment variables\n+Runtime configuration\n =====================\n \n-The libcamera behaviour can be tuned through environment variables. This\n-document lists all the available variables and describes their usage.\n+The libcamera behaviour can be tuned through a configuration file or environment\n+variables. This document lists all the configuration options and describes their\n+usage.\n+\n+General rules\n+-------------\n+\n+The configuration file is looked up in the following locations, in this order:\n+\n+- $XDG_CONFIG_HOME/libcamera/configuration.yaml\n+- LIBCAMERA_SYSCONF_DIR/configuration.yaml\n+- /etc/libcamera/configuration.yaml\n+\n+The first configuration file found wins, contingent configuration files in other locations are ignored.\n+\n+Settings in environment variables take precedence over settings in configuration\n+files. This allows overriding behaviour temporarily without the need to modify\n+configuration files.\n+\n+Configuration options\n+---------------------\n+\n+...\n+\n+Configuration file example\n+--------------------------\n+\n+::\n+\n+   ---\n+   version: 1\n+   configuration:\n+     log:\n+       file: syslog\n+       levels: 'IPAManager:DEBUG'\n+       color: false\n+     pipelines:\n+       simple:\n+         supportedDevices:\n+         - driver: mxc-isi\n+           softwareIsp: true\n+       rpi:\n+         config_file: /usr/local/share/libcamera/pipeline/rpi/vc4/minimal_mem.yaml\n+       rkisp1:\n+         tuning_file:\n+           /home/user/.libcamera/rkisp1.yaml\n+     ipa:\n+       config_paths: /home/user/.libcamera/share/ipa:/opt/libcamera/vendor/share/ipa\n+       module_paths: /home/user/.libcamera/lib:/opt/libcamera/vendor/lib\n+       force_isolation: true\n \n List of variables\n -----------------\n@@ -136,7 +184,7 @@ code.\n IPA configuration\n ~~~~~~~~~~~~~~~~~\n \n-IPA modules use configuration files to store parameters. The format and\n+IPA modules use their own configuration files to store parameters. The format and\n contents of the configuration files is specific to the IPA module. They usually\n contain tuning parameters for the algorithms, in JSON format.\n \n",
    "prefixes": [
        "RFC",
        "11/11"
    ]
}