Show a patch.

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

{
    "id": 11491,
    "url": "https://patchwork.libcamera.org/api/1.1/patches/11491/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/11491/",
    "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": "<20210304081728.1058394-6-naush@raspberrypi.com>",
    "date": "2021-03-04T08:17:26",
    "name": "[libcamera-devel,v4,5/7] libcamera: delayed_controls: Fix off-by-one error in get()",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "43f54ada86bb75fed69c13b33c2f7b03fb5b1445",
    "submitter": {
        "id": 34,
        "url": "https://patchwork.libcamera.org/api/1.1/people/34/?format=api",
        "name": "Naushir Patuck",
        "email": "naush@raspberrypi.com"
    },
    "delegate": null,
    "mbox": "https://patchwork.libcamera.org/patch/11491/mbox/",
    "series": [
        {
            "id": 1757,
            "url": "https://patchwork.libcamera.org/api/1.1/series/1757/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=1757",
            "date": "2021-03-04T08:17:21",
            "name": "DelayedControls updates and fixes",
            "version": 4,
            "mbox": "https://patchwork.libcamera.org/series/1757/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/11491/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/11491/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 AE309BD1F1\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu,  4 Mar 2021 08:17:45 +0000 (UTC)",
            "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 69C9E60522;\n\tThu,  4 Mar 2021 09:17:45 +0100 (CET)",
            "from mail-wm1-x332.google.com (mail-wm1-x332.google.com\n\t[IPv6:2a00:1450:4864:20::332])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 4372468A98\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu,  4 Mar 2021 09:17:41 +0100 (CET)",
            "by mail-wm1-x332.google.com with SMTP id o2so8200304wme.5\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 04 Mar 2021 00:17:41 -0800 (PST)",
            "from naush-laptop.patuck.local ([88.97.76.4])\n\tby smtp.gmail.com with ESMTPSA id\n\tb186sm6997926wmc.44.2021.03.04.00.17.39\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tThu, 04 Mar 2021 00:17:40 -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=\"ReJBY6TU\"; 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=Dphl3ZTsb6BZ6uAfpHD339RxAaUTr2aTC087IdEwZ2k=;\n\tb=ReJBY6TU+83bOKNy+De0vStD/SSEQ31E0EnarAMkyW3hhjnCIr28shDH49vQno1cER\n\t8JgCbtVC1Gwr+C3uPgjvU99uPK51ZNxLe22xbM7mgU9U1bkHX5MqAL541nIf5IatlEox\n\tef4NEsjX/69ZAXKchMOC5FBLk8ocQweAstDQ0JFLy89F91RmFj1sRm2bEDLugRPi6bBA\n\tQL6zoS9r6NXsqmGe+/69pd88dOKWRaPnVQ0ehyf4s1s2JZKInkfe/iOK55HtZoSwv9UH\n\t/K7zJhLda0wGcJbk2rxt3B2DoslB6BtHoSFSgLkHD6p/inJZewZlzBswBIpMVH8oVRqn\n\tCb/w==",
        "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=Dphl3ZTsb6BZ6uAfpHD339RxAaUTr2aTC087IdEwZ2k=;\n\tb=PiFWgkBwV0MneyqnirsMUWnSgB2mzrBP3/61e2/q8X80eKjclkfb+SQOobryNnDJAl\n\t7UTFSjyKqcdYlIlxduMzup5zY86LSoJvSxKDYoEVzm+NEdQ7VPtiHtPC99E9ijo6193Z\n\tn8SwUzRhT4thtRkpBT/VxjupYWMHVnEr+Na79uAbBQubFYqSiHNjIQQFa9/wIUI8yiV5\n\tj0lpuVeNPXbvym62Zsg+aGCx5+kCMlTWqvxIWYYi61Wupp7YcPsnu1aTXZsNs/2Dv8oM\n\tXMNbW95u5ByVUdqHGiAEWVLSQSoEMFwfhmHvwSw1SMhIRvRchCtcruy1ihZ+OTXAidye\n\tkuyQ==",
        "X-Gm-Message-State": "AOAM532pIcsgEPSqInSpxrl7sclkpYZhq6iY4Y+x7Syup6QHEed1GloZ\n\te4+TCnFPjYAqWmRfR/FG5sbxQGaV4xGHqF15",
        "X-Google-Smtp-Source": "ABdhPJwjd9c6bEBspbWYbvFTHhISJsK+BkQbY1TvlHSKfoqa+LjG9JHB95pDOwkva+Li9De3aIcRiQ==",
        "X-Received": "by 2002:a1c:730a:: with SMTP id d10mr2609391wmb.53.1614845860814;\n\tThu, 04 Mar 2021 00:17:40 -0800 (PST)",
        "From": "Naushir Patuck <naush@raspberrypi.com>",
        "To": "libcamera-devel@lists.libcamera.org",
        "Date": "Thu,  4 Mar 2021 08:17:26 +0000",
        "Message-Id": "<20210304081728.1058394-6-naush@raspberrypi.com>",
        "X-Mailer": "git-send-email 2.25.1",
        "In-Reply-To": "<20210304081728.1058394-1-naush@raspberrypi.com>",
        "References": "<20210304081728.1058394-1-naush@raspberrypi.com>",
        "MIME-Version": "1.0",
        "Subject": "[libcamera-devel] [PATCH v4 5/7] 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\")\nTested-by: David Plowman <david.plowman@raspberrypi.com>\nReviewed-by: Paul Elder <paul.elder@ideasonboard.com>\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 5a05741c0285..138761c9852e 100644\n--- a/src/libcamera/delayed_controls.cpp\n+++ b/src/libcamera/delayed_controls.cpp\n@@ -184,7 +184,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",
        "v4",
        "5/7"
    ]
}