Patch Detail
Show a patch.
GET /api/patches/9369/?format=api
{ "id": 9369, "url": "https://patchwork.libcamera.org/api/patches/9369/?format=api", "web_url": "https://patchwork.libcamera.org/patch/9369/", "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": "<20200822200037.20892-4-laurent.pinchart@ideasonboard.com>", "date": "2020-08-22T20:00:35", "name": "[libcamera-devel,3/5] libcamera: Drop explicit construction of std::queue", "commit_ref": null, "pull_url": null, "state": "accepted", "archived": false, "hash": "81e884debb313cb653ba9392de946016ab74b5f1", "submitter": { "id": 2, "url": "https://patchwork.libcamera.org/api/people/2/?format=api", "name": "Laurent Pinchart", "email": "laurent.pinchart@ideasonboard.com" }, "delegate": null, "mbox": "https://patchwork.libcamera.org/patch/9369/mbox/", "series": [ { "id": 1235, "url": "https://patchwork.libcamera.org/api/series/1235/?format=api", "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=1235", "date": "2020-08-22T20:00:32", "name": "libcamera: Switch to C++17", "version": 1, "mbox": "https://patchwork.libcamera.org/series/1235/mbox/" } ], "comments": "https://patchwork.libcamera.org/api/patches/9369/comments/", "check": "pending", "checks": "https://patchwork.libcamera.org/api/patches/9369/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 40287BE174\n\tfor <parsemail@patchwork.libcamera.org>;\n\tSat, 22 Aug 2020 20:01:05 +0000 (UTC)", "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 0E4AC6278A;\n\tSat, 22 Aug 2020 22:01:05 +0200 (CEST)", "from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id C4B4561EA0\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tSat, 22 Aug 2020 22:01:01 +0200 (CEST)", "from pendragon.lan (62-78-145-57.bb.dnainternet.fi [62.78.145.57])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 5DAE829E\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tSat, 22 Aug 2020 22:01:01 +0200 (CEST)" ], "Authentication-Results": "lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"gOJR+jsm\"; dkim-atps=neutral", "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1598126461;\n\tbh=tMryMAYFiC3cHfO+JCVWQRWa7OPbnj4h2RR1UFosYrA=;\n\th=From:To:Subject:Date:In-Reply-To:References:From;\n\tb=gOJR+jsmBcfILpAjBheeMQdN0R48OsGHseO/AM8/h6hot1ZDnUWJp4BCXQ2gXIoJ8\n\t/vbliV0kp1trrKDk2WkUhSlbvQVF5i21ZjN3e2smWvBWLOdKd5HqinCZrBkZ2VorTg\n\tRKgn6VeX7LmEVYd9pD+upkvZU8Gc6HpSwx3/FEQ8=", "From": "Laurent Pinchart <laurent.pinchart@ideasonboard.com>", "To": "libcamera-devel@lists.libcamera.org", "Date": "Sat, 22 Aug 2020 23:00:35 +0300", "Message-Id": "<20200822200037.20892-4-laurent.pinchart@ideasonboard.com>", "X-Mailer": "git-send-email 2.27.0", "In-Reply-To": "<20200822200037.20892-1-laurent.pinchart@ideasonboard.com>", "References": "<20200822200037.20892-1-laurent.pinchart@ideasonboard.com>", "MIME-Version": "1.0", "Subject": "[libcamera-devel] [PATCH 3/5] libcamera: Drop explicit construction\n\tof std::queue", "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": "Now that libcamera is using C++17 and requires gcc 7 or newer, we can\nuse the implicit std::queue constructor. Simplify the code accordingly.\n\nSigned-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n---\n src/libcamera/pipeline/ipu3/cio2.cpp | 4 +---\n src/libcamera/pipeline/raspberrypi/raspberrypi.cpp | 5 ++---\n 2 files changed, 3 insertions(+), 6 deletions(-)", "diff": "diff --git a/src/libcamera/pipeline/ipu3/cio2.cpp b/src/libcamera/pipeline/ipu3/cio2.cpp\nindex abe6d8a592d6..e43ec70fe3e4 100644\n--- a/src/libcamera/pipeline/ipu3/cio2.cpp\n+++ b/src/libcamera/pipeline/ipu3/cio2.cpp\n@@ -300,9 +300,7 @@ void CIO2Device::tryReturnBuffer(FrameBuffer *buffer)\n \n void CIO2Device::freeBuffers()\n {\n-\t/* The default std::queue constructor is explicit with gcc 5 and 6. */\n-\tavailableBuffers_ = std::queue<FrameBuffer *>{};\n-\n+\tavailableBuffers_ = {};\n \tbuffers_.clear();\n \n \tif (output_->releaseBuffers())\ndiff --git a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\nindex eeaf335cbcd2..b8f0549f0c60 100644\n--- a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n+++ b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n@@ -848,9 +848,8 @@ void PipelineHandlerRPi::stop(Camera *camera)\n \n \t/* This also stops the streams. */\n \tdata->clearIncompleteRequests();\n-\t/* The default std::queue constructor is explicit with gcc 5 and 6. */\n-\tdata->bayerQueue_ = std::queue<FrameBuffer *>{};\n-\tdata->embeddedQueue_ = std::queue<FrameBuffer *>{};\n+\tdata->bayerQueue_ = {};\n+\tdata->embeddedQueue_ = {};\n \n \t/* Stop the IPA. */\n \tdata->ipa_->stop();\n", "prefixes": [ "libcamera-devel", "3/5" ] }