Message ID | 20221020195533.114049-16-hdegoede@redhat.com |
---|---|
State | Accepted |
Commit | 7bc1bfa562a81e5023eb8e6bb715c2de45631123 |
Headers | show |
Series | media: atomisp: Convert to videobuf2 | expand |
On Thu, Oct 20, 2022 at 09:55:31PM +0200, Hans de Goede wrote: > Make atomisp_g_fmt_cap() default to YUV420 so that it matches with what > atomisp_try_fmt_cap() and atomisp_queue_setup() do when they need to > pick a default pixelformat. ... > f->fmt.pix.width = 10000; > f->fmt.pix.height = 10000; Side note: Same as before, perhaps better to use limits.h instead. Unless it's defined by hardware limitations, in such case perhaps define them with explanatory naming.
diff --git a/drivers/staging/media/atomisp/pci/atomisp_ioctl.c b/drivers/staging/media/atomisp/pci/atomisp_ioctl.c index 384b231de8bc..c8f6f0c2f368 100644 --- a/drivers/staging/media/atomisp/pci/atomisp_ioctl.c +++ b/drivers/staging/media/atomisp/pci/atomisp_ioctl.c @@ -959,7 +959,7 @@ static int atomisp_g_fmt_cap(struct file *file, void *fh, if (f->fmt.pix.sizeimage) return 0; - f->fmt.pix.pixelformat = V4L2_PIX_FMT_YUYV; + f->fmt.pix.pixelformat = V4L2_PIX_FMT_YUV420; f->fmt.pix.width = 10000; f->fmt.pix.height = 10000;
Make atomisp_g_fmt_cap() default to YUV420 so that it matches with what atomisp_try_fmt_cap() and atomisp_queue_setup() do when they need to pick a default pixelformat. Signed-off-by: Hans de Goede <hdegoede@redhat.com> --- drivers/staging/media/atomisp/pci/atomisp_ioctl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)