* [PATCH -next] media: zoran: use resource_size
@ 2021-01-06 13:17 Zheng Yongjun
2021-01-06 13:30 ` 答复: " zhengyongjun
2021-01-06 14:51 ` Dan Carpenter
0 siblings, 2 replies; 5+ messages in thread
From: Zheng Yongjun @ 2021-01-06 13:17 UTC (permalink / raw)
To: clabbe, mchehab, mjpeg-users, linux-media, devel, linux-kernel
Cc: gregkh, Zheng Yongjun
Use resource_size rather than a verbose computation on
the end and start fields.
Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
---
drivers/staging/media/zoran/zoran_driver.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/media/zoran/zoran_driver.c b/drivers/staging/media/zoran/zoran_driver.c
index 808196ea5b81..d60b4c73ea80 100644
--- a/drivers/staging/media/zoran/zoran_driver.c
+++ b/drivers/staging/media/zoran/zoran_driver.c
@@ -1020,7 +1020,7 @@ int zoran_queue_init(struct zoran *zr, struct vb2_queue *vq)
vq->buf_struct_size = sizeof(struct zr_buffer);
vq->ops = &zr_video_qops;
vq->mem_ops = &vb2_dma_contig_memops;
- vq->gfp_flags = GFP_DMA32,
+ vq->gfp_flags = GFP_DMA32;
vq->timestamp_flags = V4L2_BUF_FLAG_TIMESTAMP_MONOTONIC;
vq->min_buffers_needed = 9;
vq->lock = &zr->lock;
--
2.22.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* 答复: [PATCH -next] media: zoran: use resource_size
2021-01-06 13:17 [PATCH -next] media: zoran: use resource_size Zheng Yongjun
@ 2021-01-06 13:30 ` zhengyongjun
2021-01-06 14:51 ` Dan Carpenter
1 sibling, 0 replies; 5+ messages in thread
From: zhengyongjun @ 2021-01-06 13:30 UTC (permalink / raw)
To: clabbe, mchehab, mjpeg-users, linux-media, devel, linux-kernel; +Cc: gregkh
Sorry, this is my fault, all this media related patch commit msg is wrong, I will send patch v2, please ignore it.
-----邮件原件-----
发件人: zhengyongjun
发送时间: 2021年1月6日 21:17
收件人: clabbe@baylibre.com; mchehab@kernel.org; mjpeg-users@lists.sourceforge.net; linux-media@vger.kernel.org; devel@driverdev.osuosl.org; linux-kernel@vger.kernel.org
抄送: gregkh@linuxfoundation.org; zhengyongjun <zhengyongjun3@huawei.com>
主题: [PATCH -next] media: zoran: use resource_size
Use resource_size rather than a verbose computation on the end and start fields.
Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
---
drivers/staging/media/zoran/zoran_driver.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/media/zoran/zoran_driver.c b/drivers/staging/media/zoran/zoran_driver.c
index 808196ea5b81..d60b4c73ea80 100644
--- a/drivers/staging/media/zoran/zoran_driver.c
+++ b/drivers/staging/media/zoran/zoran_driver.c
@@ -1020,7 +1020,7 @@ int zoran_queue_init(struct zoran *zr, struct vb2_queue *vq)
vq->buf_struct_size = sizeof(struct zr_buffer);
vq->ops = &zr_video_qops;
vq->mem_ops = &vb2_dma_contig_memops;
- vq->gfp_flags = GFP_DMA32,
+ vq->gfp_flags = GFP_DMA32;
vq->timestamp_flags = V4L2_BUF_FLAG_TIMESTAMP_MONOTONIC;
vq->min_buffers_needed = 9;
vq->lock = &zr->lock;
--
2.22.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH -next] media: zoran: use resource_size
2021-01-06 13:17 [PATCH -next] media: zoran: use resource_size Zheng Yongjun
2021-01-06 13:30 ` 答复: " zhengyongjun
@ 2021-01-06 14:51 ` Dan Carpenter
2021-01-06 20:19 ` LABBE Corentin
1 sibling, 1 reply; 5+ messages in thread
From: Dan Carpenter @ 2021-01-06 14:51 UTC (permalink / raw)
To: Zheng Yongjun
Cc: clabbe, mchehab, mjpeg-users, linux-media, devel, linux-kernel, gregkh
On Wed, Jan 06, 2021 at 09:17:02PM +0800, Zheng Yongjun wrote:
> Use resource_size rather than a verbose computation on
> the end and start fields.
>
> Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
> ---
> drivers/staging/media/zoran/zoran_driver.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/staging/media/zoran/zoran_driver.c b/drivers/staging/media/zoran/zoran_driver.c
> index 808196ea5b81..d60b4c73ea80 100644
> --- a/drivers/staging/media/zoran/zoran_driver.c
> +++ b/drivers/staging/media/zoran/zoran_driver.c
> @@ -1020,7 +1020,7 @@ int zoran_queue_init(struct zoran *zr, struct vb2_queue *vq)
> vq->buf_struct_size = sizeof(struct zr_buffer);
> vq->ops = &zr_video_qops;
> vq->mem_ops = &vb2_dma_contig_memops;
> - vq->gfp_flags = GFP_DMA32,
> + vq->gfp_flags = GFP_DMA32;
The commit doesn't match the patch. Also this driver is in
staging because it's going to be deleted soon so there probably isn't
much point doing cleanups.
If you're looking at the Smatch resource_size() message, then that's a
tricky thing because of the + 1 on part of the "end - start + 1"...
It's sometimes hard to know if we should add the + 1 which resource_size()
does or not. (That check is ancient and not up to modern standards).
regards,
dan carpenter
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH -next] media: zoran: use resource_size
2021-01-06 14:51 ` Dan Carpenter
@ 2021-01-06 20:19 ` LABBE Corentin
2021-01-07 10:45 ` Dan Carpenter
0 siblings, 1 reply; 5+ messages in thread
From: LABBE Corentin @ 2021-01-06 20:19 UTC (permalink / raw)
To: Dan Carpenter
Cc: Zheng Yongjun, mchehab, mjpeg-users, linux-media, devel,
linux-kernel, gregkh
Le Wed, Jan 06, 2021 at 05:51:00PM +0300, Dan Carpenter a écrit :
> On Wed, Jan 06, 2021 at 09:17:02PM +0800, Zheng Yongjun wrote:
> > Use resource_size rather than a verbose computation on
> > the end and start fields.
> >
> > Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
> > ---
> > drivers/staging/media/zoran/zoran_driver.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/staging/media/zoran/zoran_driver.c b/drivers/staging/media/zoran/zoran_driver.c
> > index 808196ea5b81..d60b4c73ea80 100644
> > --- a/drivers/staging/media/zoran/zoran_driver.c
> > +++ b/drivers/staging/media/zoran/zoran_driver.c
> > @@ -1020,7 +1020,7 @@ int zoran_queue_init(struct zoran *zr, struct vb2_queue *vq)
> > vq->buf_struct_size = sizeof(struct zr_buffer);
> > vq->ops = &zr_video_qops;
> > vq->mem_ops = &vb2_dma_contig_memops;
> > - vq->gfp_flags = GFP_DMA32,
> > + vq->gfp_flags = GFP_DMA32;
>
> The commit doesn't match the patch. Also this driver is in
> staging because it's going to be deleted soon so there probably isn't
> much point doing cleanups.
>
No, the driver just came back in staging since I fixed the videobuf2 conversion.
One of the reason it is kept in staging is that media maintainer want to test it with its own zoran card but covid19 delayed the physical recovery of it.
So the patch need to be resent, please.
Regards
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH -next] media: zoran: use resource_size
2021-01-06 20:19 ` LABBE Corentin
@ 2021-01-07 10:45 ` Dan Carpenter
0 siblings, 0 replies; 5+ messages in thread
From: Dan Carpenter @ 2021-01-07 10:45 UTC (permalink / raw)
To: LABBE Corentin
Cc: devel, gregkh, linux-kernel, Zheng Yongjun, mjpeg-users, mchehab,
linux-media
On Wed, Jan 06, 2021 at 09:19:58PM +0100, LABBE Corentin wrote:
> Le Wed, Jan 06, 2021 at 05:51:00PM +0300, Dan Carpenter a écrit :
> > On Wed, Jan 06, 2021 at 09:17:02PM +0800, Zheng Yongjun wrote:
> > > Use resource_size rather than a verbose computation on
> > > the end and start fields.
> > >
> > > Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
> > > ---
> > > drivers/staging/media/zoran/zoran_driver.c | 2 +-
> > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/drivers/staging/media/zoran/zoran_driver.c b/drivers/staging/media/zoran/zoran_driver.c
> > > index 808196ea5b81..d60b4c73ea80 100644
> > > --- a/drivers/staging/media/zoran/zoran_driver.c
> > > +++ b/drivers/staging/media/zoran/zoran_driver.c
> > > @@ -1020,7 +1020,7 @@ int zoran_queue_init(struct zoran *zr, struct vb2_queue *vq)
> > > vq->buf_struct_size = sizeof(struct zr_buffer);
> > > vq->ops = &zr_video_qops;
> > > vq->mem_ops = &vb2_dma_contig_memops;
> > > - vq->gfp_flags = GFP_DMA32,
> > > + vq->gfp_flags = GFP_DMA32;
> >
> > The commit doesn't match the patch. Also this driver is in
> > staging because it's going to be deleted soon so there probably isn't
> > much point doing cleanups.
> >
>
> No, the driver just came back in staging since I fixed the videobuf2 conversion.
Ah... Thanks.
regards,
dan carpenter
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2021-01-07 10:47 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-06 13:17 [PATCH -next] media: zoran: use resource_size Zheng Yongjun
2021-01-06 13:30 ` 答复: " zhengyongjun
2021-01-06 14:51 ` Dan Carpenter
2021-01-06 20:19 ` LABBE Corentin
2021-01-07 10:45 ` Dan Carpenter
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).