Show a patch.

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

{
    "id": 4188,
    "url": "https://patchwork.libcamera.org/api/1.1/patches/4188/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/4188/",
    "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": "<20200623190836.53446-15-paul.elder@ideasonboard.com>",
    "date": "2020-06-23T19:08:28",
    "name": "[libcamera-devel,v3,14/22] v4l2: v4l2_camera_proxy: noop if streamon when stream is already on",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": false,
    "hash": "fd3a69004079fae04e18c56aa6d801988508e416",
    "submitter": {
        "id": 17,
        "url": "https://patchwork.libcamera.org/api/1.1/people/17/?format=api",
        "name": "Paul Elder",
        "email": "paul.elder@ideasonboard.com"
    },
    "delegate": null,
    "mbox": "https://patchwork.libcamera.org/patch/4188/mbox/",
    "series": [
        {
            "id": 1034,
            "url": "https://patchwork.libcamera.org/api/1.1/series/1034/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=1034",
            "date": "2020-06-23T19:08:14",
            "name": "Support v4l2-compliance",
            "version": 3,
            "mbox": "https://patchwork.libcamera.org/series/1034/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/4188/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/4188/checks/",
    "tags": {},
    "headers": {
        "Return-Path": "<paul.elder@ideasonboard.com>",
        "Received": [
            "from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 9877C609A5\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 23 Jun 2020 21:09:36 +0200 (CEST)",
            "from jade.rasen.tech (unknown\n\t[IPv6:2400:4051:61:600:8147:f2a2:a8c6:9087])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 7C0A02A9;\n\tTue, 23 Jun 2020 21:09:34 +0200 (CEST)"
        ],
        "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"p7uhQ8iL\"; dkim-atps=neutral",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1592939376;\n\tbh=GXpAoz46hAsjPUdtZVPdEf6WbB5+Y2BFhz0HiD/eles=;\n\th=From:To:Cc:Subject:Date:In-Reply-To:References:From;\n\tb=p7uhQ8iLHZbmK3qijYVNNR584+tfthIjc05cFCsuI7FnGizAbdv5KJonQynazpfD5\n\tKn2Vhn4e4y59h0GlNBoS5YnmtnGwwJVTyB5b5SNXwGBVwFJuRRIaZfsThz10lM++18\n\tckxhqlY7C8xaDd9RHbt8sL4fffcRAW6bje8rn/KA=",
        "From": "Paul Elder <paul.elder@ideasonboard.com>",
        "To": "libcamera-devel@lists.libcamera.org",
        "Date": "Wed, 24 Jun 2020 04:08:28 +0900",
        "Message-Id": "<20200623190836.53446-15-paul.elder@ideasonboard.com>",
        "X-Mailer": "git-send-email 2.27.0",
        "In-Reply-To": "<20200623190836.53446-1-paul.elder@ideasonboard.com>",
        "References": "<20200623190836.53446-1-paul.elder@ideasonboard.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[libcamera-devel] [PATCH v3 14/22] v4l2: v4l2_camera_proxy: noop if\n\tstreamon when stream is already on",
        "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>",
        "X-List-Received-Date": "Tue, 23 Jun 2020 19:09:36 -0000"
    },
    "content": "If VIDIOC_STREMAON is called when the stream is already on, do a noop.\n\nSigned-off-by: Paul Elder <paul.elder@ideasonboard.com>\nReviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n\n---\nChanges in v3:\n- move isRunning check to after ownership check\n\nNew in v2: (split from \"v4l2: v4l2_camera: Add isRunning()\")\n---\n src/v4l2/v4l2_camera_proxy.cpp | 3 +++\n 1 file changed, 3 insertions(+)",
    "diff": "diff --git a/src/v4l2/v4l2_camera_proxy.cpp b/src/v4l2/v4l2_camera_proxy.cpp\nindex 0c7232d..06fef21 100644\n--- a/src/v4l2/v4l2_camera_proxy.cpp\n+++ b/src/v4l2/v4l2_camera_proxy.cpp\n@@ -628,6 +628,9 @@ int V4L2CameraProxy::vidioc_streamon(V4L2CameraFile *file, int *arg)\n \tif (!hasOwnership(file))\n \t\treturn -EBUSY;\n \n+\tif (vcam_->isRunning())\n+\t\treturn 0;\n+\n \tcurrentBuf_ = 0;\n \n \treturn vcam_->streamOn();\n",
    "prefixes": [
        "libcamera-devel",
        "v3",
        "14/22"
    ]
}