Show a patch.

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

{
    "id": 11258,
    "url": "https://patchwork.libcamera.org/api/patches/11258/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/11258/",
    "project": {
        "id": 1,
        "url": "https://patchwork.libcamera.org/api/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": "<20210212113312.239076-6-naush@raspberrypi.com>",
    "date": "2021-02-12T11:33:12",
    "name": "[libcamera-devel,5/5] libcamera: delayed_controls: Fix off-by-one error in get()",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": false,
    "hash": "43f54ada86bb75fed69c13b33c2f7b03fb5b1445",
    "submitter": {
        "id": 34,
        "url": "https://patchwork.libcamera.org/api/people/34/?format=api",
        "name": "Naushir Patuck",
        "email": "naush@raspberrypi.com"
    },
    "delegate": null,
    "mbox": "https://patchwork.libcamera.org/patch/11258/mbox/",
    "series": [
        {
            "id": 1683,
            "url": "https://patchwork.libcamera.org/api/series/1683/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=1683",
            "date": "2021-02-12T11:33:07",
            "name": "DelayedControls updates and fixes",
            "version": 1,
            "mbox": "https://patchwork.libcamera.org/series/1683/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/11258/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/11258/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 50C14BD160\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri, 12 Feb 2021 11:37:40 +0000 (UTC)",
            "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 1DB8363784;\n\tFri, 12 Feb 2021 12:37:40 +0100 (CET)",
            "from mail-wm1-x330.google.com (mail-wm1-x330.google.com\n\t[IPv6:2a00:1450:4864:20::330])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id CD0666376F\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 12 Feb 2021 12:37:36 +0100 (CET)",
            "by mail-wm1-x330.google.com with SMTP id n10so663744wmq.0\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 12 Feb 2021 03:37:36 -0800 (PST)",
            "from naush-laptop.patuck.local ([88.97.76.4])\n\tby smtp.gmail.com with ESMTPSA id\n\tv5sm10005020wro.71.2021.02.12.03.37.35\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tFri, 12 Feb 2021 03:37:35 -0800 (PST)"
        ],
        "Authentication-Results": "lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n\tunprotected) header.d=raspberrypi.com header.i=@raspberrypi.com\n\theader.b=\"BQl8dwfD\"; dkim-atps=neutral",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=raspberrypi.com; s=google;\n\th=from:to:cc:subject:date:message-id:in-reply-to:references\n\t:mime-version:content-transfer-encoding;\n\tbh=Ly/7+R5SplSQlPy0AIFb6Vzt1EE1ot3TspwZ1TuICqY=;\n\tb=BQl8dwfDmq2qyTo5td5uEqE94qn4p/CcXVKw0TvXZL+wDMllvwGYrTcnsNUOfCy8kc\n\tweacSp1Z8yQMts3t4p6aDtQUbS4DwNOvhD87EldGE/1c33sM4SzLpS6Sy5fjMULGgazJ\n\tSKOSfC2smocsnPkfycAmfbdqrlBg2jir841YR0tYHhEYAZOr6ZhogsQSb9KH4PDn5Ljd\n\tBRilGZGWm8bIRMB31J9QQzDJLKcgdzYVOCJTJYgINIC8tQPrlvyGgMj+FaWuWdoJYGl1\n\t3NF/AoQwYdNKZHp1JxOUnbCkWkh9TWjf3jWDpE6Ckso7Pqd6V1prih9uFGeO7faWQouP\n\tB2Rw==",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to\n\t:references:mime-version:content-transfer-encoding;\n\tbh=Ly/7+R5SplSQlPy0AIFb6Vzt1EE1ot3TspwZ1TuICqY=;\n\tb=tuvTRDYasMHaB6SpV4xMBp/CiNNqTcycRIcsQZnJLl1W//FVi+4snmyMvyvby/TxnK\n\txJtwhESNk/ZvAOqZ+TJU8U6ICGO4WMCiofg9staZX3dmrbqkHomd95lhmESrKoCkdLKq\n\tPD4J1ib/Ektjwe/b+yGM60twf7ztrQs1LhSIOEeuGpsFcaQMRbCXVXVc9bkB44XfCY9J\n\tn9Ewx8VY6FaqwODmBiFEkV9DhL5Ewfh9m2a8Uw/T2GMGVo7/lS6qZXdaq0L8ZnWxU/nu\n\tjzzpsjpOuPLeklHDsbyyu63UmTtf5gPzQtIO8KGb5vYEjI0FT0nvQmirR3G1M5QizN74\n\toxxw==",
        "X-Gm-Message-State": "AOAM532gFGZPwVQSRZ03wRE51T0y3wQUElydRZF9LjwW/ztPsvKsL/+X\n\tkKnRoOTMEMJTFRgKo0Idrxj+wejaT3z1yQSw",
        "X-Google-Smtp-Source": "ABdhPJy1ouv9hv+WL+pmdfFV6/EPul2ehMB19K1PkDKJHaedAtBgdOMP1shfHvHDpp+i8HH3SzvZRg==",
        "X-Received": "by 2002:a7b:cf19:: with SMTP id l25mr2173517wmg.85.1613129856272;\n\tFri, 12 Feb 2021 03:37:36 -0800 (PST)",
        "From": "Naushir Patuck <naush@raspberrypi.com>",
        "To": "libcamera-devel@lists.libcamera.org",
        "Date": "Fri, 12 Feb 2021 11:33:12 +0000",
        "Message-Id": "<20210212113312.239076-6-naush@raspberrypi.com>",
        "X-Mailer": "git-send-email 2.25.1",
        "In-Reply-To": "<20210212113312.239076-1-naush@raspberrypi.com>",
        "References": "<20210212113312.239076-1-naush@raspberrypi.com>",
        "MIME-Version": "1.0",
        "Subject": "[libcamera-devel] [PATCH 5/5] libcamera: delayed_controls: Fix\n\toff-by-one error in get()",
        "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>",
        "Content-Type": "text/plain; charset=\"us-ascii\"",
        "Content-Transfer-Encoding": "7bit",
        "Errors-To": "libcamera-devel-bounces@lists.libcamera.org",
        "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"
    },
    "content": "There was an off-by-one error in DelayedControls::get() when picking\ncontrols from the queue to return back to the pipeline handler.\nThis is only noticeable as small oscillations in brightness when closely\nviewing frame while AGC is running. The old StaggeredCtrl did not show\nthis error as the startup queuing mechanism has changed in\nDelayedControls.\n\nFix this by indexing to the correct position in the queue.\n\nSigned-off-by: Naushir Patuck <naush@raspberrypi.com>\nReported-by: David Plowman <david.plowman@raspberrypi.com>\nFixes: 3d4b7b005911 (\"libcamera: delayed_controls: Add helper for controls that apply with a delay\")\n---\n src/libcamera/delayed_controls.cpp | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)",
    "diff": "diff --git a/src/libcamera/delayed_controls.cpp b/src/libcamera/delayed_controls.cpp\nindex f140b4b562e7..9d0d17372546 100644\n--- a/src/libcamera/delayed_controls.cpp\n+++ b/src/libcamera/delayed_controls.cpp\n@@ -183,7 +183,7 @@ bool DelayedControls::push(const ControlList &controls)\n  */\n ControlList DelayedControls::get(uint32_t sequence)\n {\n-\tuint32_t adjustedSeq = sequence - firstSequence_ + 1;\n+\tuint32_t adjustedSeq = sequence - firstSequence_;\n \tunsigned int index = std::max<int>(0, adjustedSeq - maxDelay_);\n \n \tControlList out(device_->controls());\n",
    "prefixes": [
        "libcamera-devel",
        "5/5"
    ]
}