#
01798455 |
| 02-Mar-2023 |
Hans Verkuil <hverkuil-cisco@xs4all.nl> |
media: common: saa7146: add support for missing .vidioc_try_fmt_vbi_cap
Support for VIDIOC_TRY_FMT for the vbi device was missing. Add it.
This fixes a V4L2 compliance issue.
Signed-off-by: Hans V
media: common: saa7146: add support for missing .vidioc_try_fmt_vbi_cap
Support for VIDIOC_TRY_FMT for the vbi device was missing. Add it.
This fixes a V4L2 compliance issue.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
show more ...
|
#
b2943a0e |
| 02-Mar-2023 |
Hans Verkuil <hverkuil-cisco@xs4all.nl> |
media: common: saa7146: allow S_STD(G_STD)
If the requested TV standard is identical to the current TV standard, then return 0, even when the vb2 queues are busy.
This fixes a V4L2 compliance issue
media: common: saa7146: allow S_STD(G_STD)
If the requested TV standard is identical to the current TV standard, then return 0, even when the vb2 queues are busy.
This fixes a V4L2 compliance issue.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
show more ...
|
#
ff6dad2f |
| 02-Mar-2023 |
Hans Verkuil <hverkuil-cisco@xs4all.nl> |
media: common: saa7146: check minimum video format size
There was no check for the minimum width and height, so 0 values were just passed on. Fix this.
Signed-off-by: Hans Verkuil <hverkuil-cisco@x
media: common: saa7146: check minimum video format size
There was no check for the minimum width and height, so 0 values were just passed on. Fix this.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
show more ...
|
#
e4561809 |
| 02-Mar-2023 |
Hans Verkuil <hverkuil-cisco@xs4all.nl> |
media: common: saa7146: fix compliance problems with field handling
The initial field value of the format is ANY, which isn't allowed. Change to INTERLACED.
VIDIOC_TRY_FMT will overwrite vv->last_f
media: common: saa7146: fix compliance problems with field handling
The initial field value of the format is ANY, which isn't allowed. Change to INTERLACED.
VIDIOC_TRY_FMT will overwrite vv->last_field, which is an unwanted side-effect, so drop this.
And finally vidioc_s_fmt_vid_cap didn't initialize vv->last_field correctly.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
show more ...
|
#
0b6e30bd |
| 01-Mar-2023 |
Hans Verkuil <hverkuil-cisco@xs4all.nl> |
media: saa7146: convert to vb2
Convert this driver from the old videobuf framework to the vb2 frame.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mch
media: saa7146: convert to vb2
Convert this driver from the old videobuf framework to the vb2 frame.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
show more ...
|
#
b3b2dd37 |
| 02-Mar-2023 |
Hans Verkuil <hverkuil-cisco@xs4all.nl> |
media: common: saa7146: use for_each_sg_dma_page
When building the pgtables, use for_each_sg_dma_page.
Also clean up the code a bit.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-o
media: common: saa7146: use for_each_sg_dma_page
When building the pgtables, use for_each_sg_dma_page.
Also clean up the code a bit.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
show more ...
|
#
500174a2 |
| 02-Mar-2023 |
Hans Verkuil <hverkuil-cisco@xs4all.nl> |
media: common: saa7146: fix broken V4L2_PIX_FMT_YUV422P support
The U and V components were swapped. Drop the FORMAT_BYTE_SWAP to fix this.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Si
media: common: saa7146: fix broken V4L2_PIX_FMT_YUV422P support
The U and V components were swapped. Drop the FORMAT_BYTE_SWAP to fix this.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
show more ...
|
#
c79dbdae |
| 02-Mar-2023 |
Hans Verkuil <hverkuil-cisco@xs4all.nl> |
media: common: saa7146: drop 'fmt' from struct saa7146_buf
Use the video_fmt in saa7146_vv instead of having a pointer to it in struct saa7146_buf.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4al
media: common: saa7146: drop 'fmt' from struct saa7146_buf
Use the video_fmt in saa7146_vv instead of having a pointer to it in struct saa7146_buf.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
show more ...
|
#
acdb1573 |
| 01-Mar-2023 |
Hans Verkuil <hverkuil-cisco@xs4all.nl> |
media: saa7146: drop 'dev' and 'resources' from struct saa7146_fh
Instead use vv->resources and video_drvdata(file) to obtain this information.
This prepares for the vb2 conversion later when saa71
media: saa7146: drop 'dev' and 'resources' from struct saa7146_fh
Instead use vv->resources and video_drvdata(file) to obtain this information.
This prepares for the vb2 conversion later when saa7146_fh is dropped completely.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
show more ...
|
#
7777694f |
| 02-Mar-2023 |
Hans Verkuil <hverkuil-cisco@xs4all.nl> |
media: saa7146: drop overlay support
Destructive overlay support (i.e. where the video frame is DMA-ed straight into a framebuffer) is effectively dead. It was a necessary evil in the early days whe
media: saa7146: drop overlay support
Destructive overlay support (i.e. where the video frame is DMA-ed straight into a framebuffer) is effectively dead. It was a necessary evil in the early days when computers were not fast enough to copy SDTV video frames around, but today that's no longer a problem.
It requires access to the framebuffer memory, which is a bad idea and very hard to do safely. In addition, in drm it is today almost impossible to get hold of the framebuffer address.
So drop support for this.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
show more ...
|
#
39d08ab9 |
| 01-Feb-2023 |
Hans Verkuil <hverkuil-cisco@xs4all.nl> |
media: Revert "media: saa7146: deprecate hexium_gemini/orion, mxb and ttpci"
This reverts commit e33fdb5a02490059e2f48ced2c038c8a46c6476d.
The saa7146-based devices are still in use, esp. for DVB.
media: Revert "media: saa7146: deprecate hexium_gemini/orion, mxb and ttpci"
This reverts commit e33fdb5a02490059e2f48ced2c038c8a46c6476d.
The saa7146-based devices are still in use, esp. for DVB. So move these drivers back to mainline.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
show more ...
|
#
e33fdb5a |
| 11-Aug-2022 |
Hans Verkuil <hverkuil-cisco@xs4all.nl> |
media: saa7146: deprecate hexium_gemini/orion, mxb and ttpci
Deprecate the hexium_gemini, hexium_orion, mxb and ttpci saa7146-based drivers: these drivers do not use the vb2 framework for video stre
media: saa7146: deprecate hexium_gemini/orion, mxb and ttpci
Deprecate the hexium_gemini, hexium_orion, mxb and ttpci saa7146-based drivers: these drivers do not use the vb2 framework for video streaming, instead it uses the old videobuf framework.
We want to get rid of these old drivers, so deprecated these for future removal.
[hverkuil: update MAINTAINERS file]
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
show more ...
|
#
f2d8b691 |
| 22-Jan-2022 |
Sakari Ailus <sakari.ailus@linux.intel.com> |
media: v4l: ioctl: Set bus_info in v4l_querycap()
The bus_info field is set by most drivers based on the type of the device bus as well as the name of the device. Do this in v4l_querycap() so driver
media: v4l: ioctl: Set bus_info in v4l_querycap()
The bus_info field is set by most drivers based on the type of the device bus as well as the name of the device. Do this in v4l_querycap() so drivers don't need to. This keeps compatibility with non-default and silly bus_info.
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
show more ...
|
#
e56429b0 |
| 03-Mar-2021 |
Tasos Sahanidis <tasos@tasossah.com> |
media: saa7146: use sg_dma_len when building pgtable
The new AMD IOMMU DMA implementation concatenates sglist entries under certain conditions, and because saa7146 accessed the length member directl
media: saa7146: use sg_dma_len when building pgtable
The new AMD IOMMU DMA implementation concatenates sglist entries under certain conditions, and because saa7146 accessed the length member directly, it did not support this scenario.
This fixes IO_PAGE_FAULTs by using the sg_dma_len macro.
Fixes: be62dbf554c5 ("iommu/amd: Convert AMD iommu driver to the dma-iommu api") Signed-off-by: Tasos Sahanidis <tasos@tasossah.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
show more ...
|
#
3f65c6f6 |
| 30-Oct-2020 |
Arnd Bergmann <arnd@arndb.de> |
media: v4l2: allocate v4l2_clip objects early
The v4l2_format based ioctls can have an indirect pointer to an array of v4l2_clip structures for overlay mode, depending on the 'type' member. There ar
media: v4l2: allocate v4l2_clip objects early
The v4l2_format based ioctls can have an indirect pointer to an array of v4l2_clip structures for overlay mode, depending on the 'type' member. There are only five drivers that use the overlay mode and copy the data through the __user pointer.
Change the five drivers to use memcpy() instead, and copy the data in common code using the check_array_args() helpers. This allows for a subsequent patch that use the same mechanism for compat ioctl handlers.
Note that there is another pointer for a 'bitmap' that is only used in the 'vivid' driver and nowhere else. There is no easy way to use the same trick without adding complexity to the common code, so this remains a __user pointer.
[hverkuil: fix: CHECK: spaces preferred around that '*' (ctx:VxV)] [hverkuil: fix: CHECK: Alignment should match open parenthesis]
Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
show more ...
|
#
1ec4c6ef |
| 15-Dec-2019 |
Aditya Pakki <pakki001@umn.edu> |
media: saa7146: Avoid using BUG_ON as an assertion
In video_begin and video_end, saa7146_format_by_fourcc can return NULL and is checked via BUG_ON. However, by returning the error to the callers up
media: saa7146: Avoid using BUG_ON as an assertion
In video_begin and video_end, saa7146_format_by_fourcc can return NULL and is checked via BUG_ON. However, by returning the error to the callers upstream, we can avoid the crash and handle it via recovery code.
Signed-off-by: Aditya Pakki <pakki001@umn.edu> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
show more ...
|
#
2169e6da |
| 11-Jun-2019 |
Hans Verkuil <hverkuil-cisco@xs4all.nl> |
media: media/pci: don't set description for ENUM_FMT
The V4L2 core sets the description for the driver in order to ensure consistent naming.
So drop the strscpy of the description in drivers. Also
media: media/pci: don't set description for ENUM_FMT
The V4L2 core sets the description for the driver in order to ensure consistent naming.
So drop the strscpy of the description in drivers. Also remove any description strings in driver-internal structures since those are no longer needed.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
show more ...
|
#
21615365 |
| 17-Jun-2019 |
Hans Verkuil <hverkuil@xs4all.nl> |
media: media/pci: set device_caps in struct video_device
Instead of filling in the struct v4l2_capability device_caps field, fill in the struct video_device device_caps field.
That way the V4L2 cor
media: media/pci: set device_caps in struct video_device
Instead of filling in the struct v4l2_capability device_caps field, fill in the struct video_device device_caps field.
That way the V4L2 core knows what the capabilities of the video device are.
But this only really works if all drivers use this, so convert all pci drivers in this patch.
Tested with cx88-blackbird and ivtv PVR-350.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
show more ...
|
#
4b129dc9 |
| 18-Feb-2019 |
Mauro Carvalho Chehab <mchehab+samsung@kernel.org> |
media: common: fix several typos
Use codespell to fix lots of typos over frontends.
Manually verified to avoid false-positives.
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
|
#
cc1e6315 |
| 10-Sep-2018 |
Mauro Carvalho Chehab <mchehab+samsung@kernel.org> |
media: replace strcpy() by strscpy()
The strcpy() function is being deprecated upstream. Replace it by the safer strscpy().
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org> Reviewe
media: replace strcpy() by strscpy()
The strcpy() function is being deprecated upstream. Replace it by the safer strscpy().
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org> Reviewed-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
show more ...
|
#
c0decac1 |
| 10-Sep-2018 |
Mauro Carvalho Chehab <mchehab+samsung@kernel.org> |
media: use strscpy() instead of strlcpy()
The implementation of strscpy() is more robust and safer.
That's now the recommended way to copy NUL terminated strings.
Signed-off-by: Mauro Carvalho Che
media: use strscpy() instead of strlcpy()
The implementation of strscpy() is more robust and safer.
That's now the recommended way to copy NUL terminated strings.
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org> Reviewed-by: Kees Cook <keescook@chromium.org> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
show more ...
|
#
6e6a8b5a |
| 04-Jan-2018 |
Mauro Carvalho Chehab <mchehab@s-opensource.com> |
media: replace all <spaces><tab> occurrences
There are a lot of places where sequences of space/tabs are found. Get rid of all spaces before tabs.
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-op
media: replace all <spaces><tab> occurrences
There are a lot of places where sequences of space/tabs are found. Get rid of all spaces before tabs.
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
show more ...
|
#
e40d14a8 |
| 01-Oct-2017 |
Jérémy Lefaure <jeremy.lefaure@lse.epita.fr> |
media: use ARRAY_SIZE
Using the ARRAY_SIZE macro improves the readability of the code. Also, it is not always useful to use a variable to store this constant calculated at compile time.
Found with
media: use ARRAY_SIZE
Using the ARRAY_SIZE macro improves the readability of the code. Also, it is not always useful to use a variable to store this constant calculated at compile time.
Found with Coccinelle with the following semantic patch: @r depends on (org || report)@ type T; T[] E; position p; @@ ( (sizeof(E)@p /sizeof(*E)) | (sizeof(E)@p /sizeof(E[...])) | (sizeof(E)@p /sizeof(T)) )
Signed-off-by: Jérémy Lefaure <jeremy.lefaure@lse.epita.fr> Reviewed-by: Michael Ira Krufky <mkrufky@linuxtv.org> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
show more ...
|
#
12a83612 |
| 16-Oct-2017 |
Kees Cook <keescook@chromium.org> |
media: saa7146: Convert timers to use timer_setup()
In preparation for unconditionally passing the struct timer_list pointer to all timer callbacks, switch to using the new timer_setup() and from_ti
media: saa7146: Convert timers to use timer_setup()
In preparation for unconditionally passing the struct timer_list pointer to all timer callbacks, switch to using the new timer_setup() and from_timer() to pass the timer pointer explicitly.
Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
show more ...
|
#
ad627017 |
| 13-Sep-2017 |
Bhumika Goyal <bhumirks@gmail.com> |
[media] saa7146: make saa7146_use_ops const
Make these const as they are not modified in the file referencing them. They are only used when their function pointer fields invokes a function and there
[media] saa7146: make saa7146_use_ops const
Make these const as they are not modified in the file referencing them. They are only used when their function pointer fields invokes a function and therefore none of the structure fields are getting modified. Also, add a const to the declaration in the header.
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
show more ...
|