[{"id":3148,"web_url":"https://patchwork.libcamera.org/comment/3148/","msgid":"<20191127144833.fmwt5gqcqazsrthg@uno.localdomain>","date":"2019-11-27T14:48:33","subject":"Re: [libcamera-devel] [PATCH 11/30] libcamera: v4l2_videodevice:\n\tAlign which type variable is used in queueBuffer()","submitter":{"id":3,"url":"https://patchwork.libcamera.org/api/people/3/","name":"Jacopo Mondi","email":"jacopo@jmondi.org"},"content":"Hi Niklas,\n\nOn Wed, Nov 27, 2019 at 12:36:01AM +0100, Niklas Söderlund wrote:\n> Reading V4L2VideoDevice::queueBuffer() is confusing since buf.type is\n> first set to bufferType_ but then both variables are used in V4L2 macros\n> to operate based on which type of buffer is being processed. Aligen on\n> only using buf.type since it have the most existing users.\n\nI'm not sure which one of the two is mostly used to be honest.\n\nThis change won't hurt though if you want it in.\nReviewed-by: Jacopo Mondi <jacopo@jmondi.org>\n\nThanks\n  j\n\n>\n> Signed-off-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>\n> ---\n>  src/libcamera/v4l2_videodevice.cpp | 2 +-\n>  1 file changed, 1 insertion(+), 1 deletion(-)\n>\n> diff --git a/src/libcamera/v4l2_videodevice.cpp b/src/libcamera/v4l2_videodevice.cpp\n> index 166b0abc1b101f88..7b6fa5347ef320f8 100644\n> --- a/src/libcamera/v4l2_videodevice.cpp\n> +++ b/src/libcamera/v4l2_videodevice.cpp\n> @@ -1000,7 +1000,7 @@ int V4L2VideoDevice::queueBuffer(Buffer *buffer)\n>  \t\tbuf.m.planes = v4l2Planes;\n>  \t}\n>\n> -\tif (V4L2_TYPE_IS_OUTPUT(bufferType_)) {\n> +\tif (V4L2_TYPE_IS_OUTPUT(buf.type)) {\n>  \t\tbuf.bytesused = buffer->bytesused_;\n>  \t\tbuf.sequence = buffer->sequence_;\n>  \t\tbuf.timestamp.tv_sec = buffer->timestamp_ / 1000000000;\n> --\n> 2.24.0\n>\n> _______________________________________________\n> libcamera-devel mailing list\n> libcamera-devel@lists.libcamera.org\n> https://lists.libcamera.org/listinfo/libcamera-devel","headers":{"Return-Path":"<jacopo@jmondi.org>","Received":["from relay9-d.mail.gandi.net (relay9-d.mail.gandi.net\n\t[217.70.183.199])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id AF9F360C33\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 27 Nov 2019 15:46:27 +0100 (CET)","from uno.localdomain (93-34-114-233.ip49.fastwebnet.it\n\t[93.34.114.233]) (Authenticated sender: jacopo@jmondi.org)\n\tby relay9-d.mail.gandi.net (Postfix) with ESMTPSA id 2A3E0FF80B;\n\tWed, 27 Nov 2019 14:46:26 +0000 (UTC)"],"X-Originating-IP":"93.34.114.233","Date":"Wed, 27 Nov 2019 15:48:33 +0100","From":"Jacopo Mondi <jacopo@jmondi.org>","To":"Niklas =?utf-8?q?S=C3=B6derlund?= <niklas.soderlund@ragnatech.se>","Cc":"libcamera-devel@lists.libcamera.org","Message-ID":"<20191127144833.fmwt5gqcqazsrthg@uno.localdomain>","References":"<20191126233620.1695316-1-niklas.soderlund@ragnatech.se>\n\t<20191126233620.1695316-12-niklas.soderlund@ragnatech.se>","MIME-Version":"1.0","Content-Type":"multipart/signed; micalg=pgp-sha256;\n\tprotocol=\"application/pgp-signature\"; boundary=\"mdteo7kr5owo7xtt\"","Content-Disposition":"inline","In-Reply-To":"<20191126233620.1695316-12-niklas.soderlund@ragnatech.se>","User-Agent":"NeoMutt/20180716","Subject":"Re: [libcamera-devel] [PATCH 11/30] libcamera: v4l2_videodevice:\n\tAlign which type variable is used in queueBuffer()","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":"Wed, 27 Nov 2019 14:46:27 -0000"}},{"id":3163,"web_url":"https://patchwork.libcamera.org/comment/3163/","msgid":"<20191202095806.v4g36rfpz37jibb5@uno.localdomain>","date":"2019-12-02T09:58:06","subject":"Re: [libcamera-devel] [PATCH 11/30] libcamera: v4l2_videodevice:\n\tAlign which type variable is used in queueBuffer()","submitter":{"id":3,"url":"https://patchwork.libcamera.org/api/people/3/","name":"Jacopo Mondi","email":"jacopo@jmondi.org"},"content":"Hi Niklas,\n   sorry for the double comment\n\nOn Wed, Nov 27, 2019 at 03:48:33PM +0100, Jacopo Mondi wrote:\n> Hi Niklas,\n>\n> On Wed, Nov 27, 2019 at 12:36:01AM +0100, Niklas Söderlund wrote:\n> > Reading V4L2VideoDevice::queueBuffer() is confusing since buf.type is\n> > first set to bufferType_ but then both variables are used in V4L2 macros\n> > to operate based on which type of buffer is being processed. Aligen on\n\ns/Aligen/Align\n\nThanks\n   j\n\n> > only using buf.type since it have the most existing users.\n>\n> I'm not sure which one of the two is mostly used to be honest.\n>\n> This change won't hurt though if you want it in.\n> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>\n>\n> Thanks\n>   j\n>\n> >\n> > Signed-off-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>\n> > ---\n> >  src/libcamera/v4l2_videodevice.cpp | 2 +-\n> >  1 file changed, 1 insertion(+), 1 deletion(-)\n> >\n> > diff --git a/src/libcamera/v4l2_videodevice.cpp b/src/libcamera/v4l2_videodevice.cpp\n> > index 166b0abc1b101f88..7b6fa5347ef320f8 100644\n> > --- a/src/libcamera/v4l2_videodevice.cpp\n> > +++ b/src/libcamera/v4l2_videodevice.cpp\n> > @@ -1000,7 +1000,7 @@ int V4L2VideoDevice::queueBuffer(Buffer *buffer)\n> >  \t\tbuf.m.planes = v4l2Planes;\n> >  \t}\n> >\n> > -\tif (V4L2_TYPE_IS_OUTPUT(bufferType_)) {\n> > +\tif (V4L2_TYPE_IS_OUTPUT(buf.type)) {\n> >  \t\tbuf.bytesused = buffer->bytesused_;\n> >  \t\tbuf.sequence = buffer->sequence_;\n> >  \t\tbuf.timestamp.tv_sec = buffer->timestamp_ / 1000000000;\n> > --\n> > 2.24.0\n> >\n> > _______________________________________________\n> > libcamera-devel mailing list\n> > libcamera-devel@lists.libcamera.org\n> > https://lists.libcamera.org/listinfo/libcamera-devel\n\n\n\n> _______________________________________________\n> libcamera-devel mailing list\n> libcamera-devel@lists.libcamera.org\n> https://lists.libcamera.org/listinfo/libcamera-devel","headers":{"Return-Path":"<jacopo@jmondi.org>","Received":["from relay9-d.mail.gandi.net (relay9-d.mail.gandi.net\n\t[217.70.183.199])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 6610560BFF\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon,  2 Dec 2019 10:55:58 +0100 (CET)","from uno.localdomain (93-34-114-233.ip49.fastwebnet.it\n\t[93.34.114.233]) (Authenticated sender: jacopo@jmondi.org)\n\tby relay9-d.mail.gandi.net (Postfix) with ESMTPSA id CD146FF806;\n\tMon,  2 Dec 2019 09:55:57 +0000 (UTC)"],"X-Originating-IP":"93.34.114.233","Date":"Mon, 2 Dec 2019 10:58:06 +0100","From":"Jacopo Mondi <jacopo@jmondi.org>","To":"Niklas =?utf-8?q?S=C3=B6derlund?= <niklas.soderlund@ragnatech.se>","Cc":"libcamera-devel@lists.libcamera.org","Message-ID":"<20191202095806.v4g36rfpz37jibb5@uno.localdomain>","References":"<20191126233620.1695316-1-niklas.soderlund@ragnatech.se>\n\t<20191126233620.1695316-12-niklas.soderlund@ragnatech.se>\n\t<20191127144833.fmwt5gqcqazsrthg@uno.localdomain>","MIME-Version":"1.0","Content-Type":"multipart/signed; micalg=pgp-sha256;\n\tprotocol=\"application/pgp-signature\"; boundary=\"2e42s5ggohbzid4v\"","Content-Disposition":"inline","In-Reply-To":"<20191127144833.fmwt5gqcqazsrthg@uno.localdomain>","User-Agent":"NeoMutt/20180716","Subject":"Re: [libcamera-devel] [PATCH 11/30] libcamera: v4l2_videodevice:\n\tAlign which type variable is used in queueBuffer()","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":"Mon, 02 Dec 2019 09:55:58 -0000"}},{"id":3232,"web_url":"https://patchwork.libcamera.org/comment/3232/","msgid":"<20191209182401.GB18060@pendragon.ideasonboard.com>","date":"2019-12-09T18:24:01","subject":"Re: [libcamera-devel] [PATCH 11/30] libcamera: v4l2_videodevice:\n\tAlign which type variable is used in queueBuffer()","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"Hi Niklas,\n\nThank you for the patch.\n\nOn Wed, Nov 27, 2019 at 12:36:01AM +0100, Niklas Söderlund wrote:\n> Reading V4L2VideoDevice::queueBuffer() is confusing since buf.type is\n> first set to bufferType_ but then both variables are used in V4L2 macros\n> to operate based on which type of buffer is being processed. Aligen on\n\ns/Aligen/Align/\n\n> only using buf.type since it have the most existing users.\n\ns/have/has/\n\n> Signed-off-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>\n\nReviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n\n> ---\n>  src/libcamera/v4l2_videodevice.cpp | 2 +-\n>  1 file changed, 1 insertion(+), 1 deletion(-)\n> \n> diff --git a/src/libcamera/v4l2_videodevice.cpp b/src/libcamera/v4l2_videodevice.cpp\n> index 166b0abc1b101f88..7b6fa5347ef320f8 100644\n> --- a/src/libcamera/v4l2_videodevice.cpp\n> +++ b/src/libcamera/v4l2_videodevice.cpp\n> @@ -1000,7 +1000,7 @@ int V4L2VideoDevice::queueBuffer(Buffer *buffer)\n>  \t\tbuf.m.planes = v4l2Planes;\n>  \t}\n>  \n> -\tif (V4L2_TYPE_IS_OUTPUT(bufferType_)) {\n> +\tif (V4L2_TYPE_IS_OUTPUT(buf.type)) {\n>  \t\tbuf.bytesused = buffer->bytesused_;\n>  \t\tbuf.sequence = buffer->sequence_;\n>  \t\tbuf.timestamp.tv_sec = buffer->timestamp_ / 1000000000;","headers":{"Return-Path":"<laurent.pinchart@ideasonboard.com>","Received":["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 BEC9860BDB\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon,  9 Dec 2019 19:24:08 +0100 (CET)","from pendragon.ideasonboard.com (81-175-216-236.bb.dnainternet.fi\n\t[81.175.216.236])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 37DF411B7;\n\tMon,  9 Dec 2019 19:24:08 +0100 (CET)"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1575915848;\n\tbh=QMpXJu4uFPw8Jz0G/iEU84XP50WnPSqwpyZ9ax3XP+A=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=GO1t2OxRyKcrgW++wU5gD1aMKmZFrfzfY1iYrfTfI1wHP1nv7fBiBKnBmmJCT7AsM\n\tD1DXXMVweN6oEHqfnle6E66Z0l0sPtMGAprfnn5EDATUIbbgxzf7ykeh6MYzPicdu9\n\tdGFf7GrfUm9+R85j36gQPzyNjZk5UGwvoTfD23fo=","Date":"Mon, 9 Dec 2019 20:24:01 +0200","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Niklas =?utf-8?q?S=C3=B6derlund?= <niklas.soderlund@ragnatech.se>","Cc":"libcamera-devel@lists.libcamera.org","Message-ID":"<20191209182401.GB18060@pendragon.ideasonboard.com>","References":"<20191126233620.1695316-1-niklas.soderlund@ragnatech.se>\n\t<20191126233620.1695316-12-niklas.soderlund@ragnatech.se>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","Content-Transfer-Encoding":"8bit","In-Reply-To":"<20191126233620.1695316-12-niklas.soderlund@ragnatech.se>","User-Agent":"Mutt/1.10.1 (2018-07-13)","Subject":"Re: [libcamera-devel] [PATCH 11/30] libcamera: v4l2_videodevice:\n\tAlign which type variable is used in queueBuffer()","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":"Mon, 09 Dec 2019 18:24:08 -0000"}}]