aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)AuthorFilesLines
7 daysmedia-info: Include missing <cstdint> for uintptr_tHEADmasterKhem Raj1-0/+1
gcc 13 moved some includes around and as a result <cstdint> is no longer transitively included [1]. Explicitly include it. [1] https://gcc.gnu.org/gcc-13/porting_to.html#header-dep-changes Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2023-01-14cec-ctl: --store-pin shouldn't enable pin monitoringHans Verkuil1-3/+3
The use of --store-pin is meant to just set a filename for storing the pin monitoring data, it is not meant to enable pin monitoring itself, that's for --monitor-pin. Using just --store-pin without --monitor-pin seemed to work, but it was actually not logging some data, causing warnings to be issued when analyzing the result. With this patch --monitor-pin is required to actually enable pin monitoring. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2023-01-09v4l2-tracer: check for strerrorname_np()Deborah Brouwer4-4/+12
The v4l2-tracer converts the errno integer to a string using strerrorname_np(). Check if this function is available and, if not, use strerror() instead. Signed-off-by: Deborah Brouwer <deborah.brouwer@collabora.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-12-30v4l2grab: add support for 422P formatMauro Carvalho Chehab1-0/+2
This format is similar to 420, except that it uses full length on vertical. Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-12-30v4l2grab: add support for NV16 and NV61Mauro Carvalho Chehab1-0/+4
Those formats are similar to NV12/NV21, except that it uses a full length at the second plane. Add support for it. Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-12-30v4l2grab: allow adding planars with full sizeMauro Carvalho Chehab1-24/+24
Not all planar formats have decimation. Add support for full size ones. Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-12-30v4l2grab: expand video format switch caseMauro Carvalho Chehab1-14/+18
As we're planning to add more formats, let's first split the switch to avoid if's for two and three plane formats. Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-12-30v4l2grab: fix image size calculation for some formatsMauro Carvalho Chehab1-4/+4
Some formats use multiple planes with vertical and/or horizontal decimation. The image size estimation for those planes are wrong, producing false warnings. Fix it. Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-12-30v4l2grab: validate it the returned image is big enoughMauro Carvalho Chehab1-9/+36
If the returned image is too small, the conversion will fail. So, before letting that happen, validate the image size. Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
2022-12-30v4l2grab: fix raw output on mmapMauro Carvalho Chehab1-1/+1
When raw mode is selected, it should not convert the image to RGB24. This works fine on all modes but mmap (without threads). Fix it. Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-12-30v4l2grab: fix buffer conversion sizeMauro Carvalho Chehab1-1/+1
use the resolution returned by the driver in order to allocate the memory for storing the converted buffer. That fixes a core dump when the driver returns a resolution bigger than the requested image. Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
2022-12-15libv4lconvert: Fix v4lconvert_grey_to_rgb24 not taking stride into accountBenjamin Mugnier3-3/+4
Drivers are allowed to generate buffers where stride != width. Where as v4lconvert_grey_to_rgb24() assumed that stride == width is always true. This resulted in wrong frames for monochrome sensors, with padding bytes being visible diagonally and messing up the image alignment. Tested with rasbperry pi unicam driver using strides of 32 paired with the st-vgxy61 driver, which native resolution is 1944x1204, producing a frame of 1952x1204. Signed-off-by: Benjamin Mugnier <benjamin.mugnier@foss.st.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-12-06v4l2-tracer: add support for most basic controlsHans Verkuil2-2/+28
The v4l2-tracer utility didn't support tracing simple controls without a payload (i.e. the 'size' field is 0) and just a simple value. This adds support for that, plus the four standard INTEGER64 controls that use field value64. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Deborah Brouwer <deborah.brouwer@collabora.com> Reviewed-by: Daniel Almeida <daniel.almeida@collabora.com>
2022-12-06utils: add v4l2-tracer utilityDeborah Brouwer17-0/+5161
The v4l2-tracer traces, records and replays userspace applications that implement the v4l2 memory-to-memory stateless video decoder interface. It writes the traced system calls and video frame data to a file in JSON format. It reads the JSON file to replay the same system calls and to send the same video frame data to the kernel driver. The JSON file can be replayed in different environments or on different machines. Signed-off-by: Deborah Brouwer <deborah.brouwer@collabora.com> Reviewed-by: Daniel Almeida <daniel.almeida@collabora.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-11-25v4l-utils: sync with latest upstream git repoHans Verkuil8-49/+197
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-11-25dvbv5-zap: Record all the channel video/audio/other PIDsSimon Arlott1-68/+119
The channel format doesn't include the language of the audio PIDs, so how is anyone supposed to select the right one? Make it possible to request all of them. This also includes subtitles. Link: https://lore.kernel.org/linux-media/16e9ea29-3373-f59f-772d-b7a9b2df21cb@0882a8b5-c6c3-11e9-b005-00805fc181fe Signed-off-by: Simon Arlott <v4l@octiron.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-11-25libdvbv5: Read all "other" PIDs for channelsSimon Arlott1-7/+4
When there are multiple PID_* entries in the channels file, keep all of them instead of only the last one. Link: https://lore.kernel.org/linux-media/da8f5aa8-e413-1678-d93d-6e8d20fb97b6@0882a8b5-c6c3-11e9-b005-00805fc181fe Signed-off-by: Simon Arlott <v4l@octiron.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-11-25libdvbv5: cleanup ASTC service location parsingMartin VallevandMartin Vallevand1-5/+12
Logic attempted to move raw data from the generic DVB descriptor into a linked list with a different structure. Calculation for the destination length would always fail as a result. Commit moves specific data elements Link: https://lore.kernel.org/linux-media/61b25413-d877-3a8f-344b-651e4b7885a2@rogers.com [mchehab: patch was mangled by e-mailer] Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-11-25v4l2-tpg.patch: add missing get_random_u8()Hans Verkuil1-1/+7
When syncing from the mainline kernel code, the v4l2-tpg.h header has to be patched, and the patch was outdated. Add the missing get_random_u8() function. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-11-24configure.ac, Makefile.am: Support building without NLSPeter Kjellerstedt2-1/+6
Avoid entering the v4l-utils-po and libdvbv5-po directories if NLS support is disabled, as the generated Makefiles in those directories are empty then. Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-11-24v4l-utils: sync with upstream git repoHans Verkuil12-46/+224
The main change was renaming Y/CbCr and Y/CrCb to Y/UV and Y/VU in the pixelformat descriptors. Accept both variants. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-11-14libv4lconvert: Fix v4lconvert_nv16_to_yuyv() not taking stride into accountHans de Goede3-11/+15
The atomisp driver can generate V4L2_PIX_FMT_NV16 buffers where stride != width. Where as v4lconvert_nv16_to_yuyv() assumed that stride == width is always true. Add a stride argument to v4lconvert_nv16_to_yuyv() to fix this. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-11-14libv4lconvert: Fix v4lconvert_nv12_*() not taking stride into accountHans de Goede3-11/+19
The atomisp driver can generate V4L2_PIX_FMT_NV12 buffers where stride != width. Where as v4lconvert_nv12_*() assumed that stride == width is always true. Add a stride argument to v4lconvert_nv12_*() to fix this. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-11-14libv4lconvert: Fix v4lconvert_rgb565_to_rgb/bgr24() not taking stride into ↵Hans de Goede3-6/+8
account The atomisp driver can generate V4L2_PIX_FMT_RGB565 buffers where stride != width. Where as v4lconvert_rgb565_to_rgb/bgr24() assumed that stride == width is always true. Add a stride argument to v4lconvert_rgb565_to_rgb/bgr24() to fix this. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-11-14libv4lconvert: Fix v4lconvert_yuv420_to_rgb/bgr24() not taking stride into ↵Hans de Goede3-19/+27
account The atomisp driver can generate V4L2_PIX_FMT_YUV420 buffers where stride != width. Where as v4lconvert_yuv420_to_rgb/bgr24() assumed that stride == width is always true. Add a stride argument to v4lconvert_yuv420_to_rgb/bgr24() to fix this. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2022-11-06v4l2-compliance: support g++ 7.5.0Hans Verkuil2-16/+12
The old g++ 7.5.0 compiler doesn't support some of the newer struct initialization methods. Just assign the fields explicitly. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
2022-11-05keytable: Convert deprecated libbpf APISudip Mukherjee2-27/+34
The libbpf APIs bpf_load_program_xattr(), bpf_create_map_node() and bpf_create_map_in_map_node() have been deprecated since v0.7. Convert them to use bpf_prog_load() and bpf_map_create(). Also, modify config script to add a check for libbpf version. Signed-off-by: Sudip Mukherjee <sudipm.mukherjee@gmail.com> Signed-off-by: Sean Young <sean@mess.org>
2022-11-05keytable: provide configuration for empty keymapSean Young2-13/+12
The lirc documentation contains some drastic measures for disabling in-kernel decoding. Provide a simpler method of disabling kernel decoding: simply set /etc/rc_maps.cfg to: * * empty.toml Signed-off-by: Sean Young <sean@mess.org>
2022-11-02cec-follower: add --ignore-standby/view-on optionsHans Verkuil4-2/+28
These options are useful to test what happens if Standby or Image/Text View On messages are lost every so often. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-10-21test-media: wait longer after rmmod/modprobe if DEBUG_KOBJECT_RELEASE=yHans Verkuil1-7/+9
If DEBUG_KOBJECT_RELEASE=y then it takes a lot longer to clean up and create /dev/char/* device nodes. Give the system more time to settle after an rmmod or modprobe. This fixes an issue where v4l2-ctl tries to use a /dev/char/81:xx device that hasn't been created yet. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-29v4l2-compliance: support INTEGER and INTEGER64 control arraysHans Verkuil1-9/+15
The control tests didn't take support for such controls into account. Fix the tests. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-29v4l2-ctl: -C foo -C bar only shows fooHans Verkuil1-1/+1
DUe to an incorrect 'return' which should have been a 'continue' only the first compound control would be shown instead of all requested compound controls. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-29v4l2-ctl: print_control should check for array controlsHans Verkuil1-0/+1
Add a check for nr_of_dims > 0, since such controls also have a payload (i.e. are not simple integers). Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-29v4l2-info: move flags2s to v4l2-info.hDeborah Brouwer2-6/+9
Make the flag2s function available to other utilities. Signed-off-by: Deborah Brouwer <deborah.brouwer@collabora.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-24v4l-utils: sync with upstream git repoHans Verkuil2-0/+16
Just cec header changes, but they affect the cec utilities. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-20v4l2-info: add flag V4L2_PIX_FMT_FLAG_SET_CSCDeborah Brouwer1-0/+1
Add a string value for V4L2_PIX_FMT_FLAG_SET_CSC in pixflags2s(). Signed-off-by: Deborah Brouwer <deborah.brouwer@collabora.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-09-09libdvbv5: Fix Doygen deprecation warningsLaurent Pinchart1-59/+0
A number of Doxygen options have become obsolete, and Doxygen complains about this when building the documentation: warning: Tag 'TCL_SUBST' at line 229 of file 'doc/Doxyfile' has become obsolete. To avoid this warning please remove this line from your configuration file or upgrade it using "doxygen -u" warning: Tag 'COLS_IN_ALPHA_INDEX' at line 1031 of file 'doc/Doxyfile' has become obsolete. To avoid this warning please remove this line from your configuration file or upgrade it using "doxygen -u" warning: Tag 'LATEX_SOURCE_CODE' at line 1716 of file 'doc/Doxyfile' has become obsolete. To avoid this warning please remove this line from your configuration file or upgrade it using "doxygen -u" warning: Tag 'XML_SCHEMA' at line 1841 of file 'doc/Doxyfile' has become obsolete. To avoid this warning please remove this line from your configuration file or upgrade it using "doxygen -u" warning: Tag 'XML_DTD' at line 1847 of file 'doc/Doxyfile' has become obsolete. To avoid this warning please remove this line from your configuration file or upgrade it using "doxygen -u" warning: Tag 'PERL_PATH' at line 2057 of file 'doc/Doxyfile' has become obsolete. To avoid this warning please remove this line from your configuration file or upgrade it using "doxygen -u" warning: Tag 'CLASS_DIAGRAMS' at line 2070 of file 'doc/Doxyfile' has become obsolete. To avoid this warning please remove this line from your configuration file or upgrade it using "doxygen -u" warning: Tag 'MSCGEN_PATH' at line 2079 of file 'doc/Doxyfile' has become obsolete. To avoid this warning please remove this line from your configuration file or upgrade it using "doxygen -u" We don't use those options, so drop them. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
2022-09-09libdvbv5: Fix invalid header file name in Doxygen INPUTLaurent Pinchart1-1/+1
The list of INPUT files in doxygen_libdvbv5.cfg contains desc_descriptor_id.h, which doesn't exist. The correct file name is desc_registration_id.h. Fix it. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
2022-08-30v4l-utils: sync with upstream media treeHans Verkuil8-23/+14
Main change: drop the references to V4L2_CAP_ASYNCIO. Also fix some of the capability reporting functions (there were some duplicates and in one place V4L2_CAP_IO_MC support was missing). Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-08-29v4l2 utils: Support V4L2_PIX_FMT_YUV[AX]32Laurent Pinchart7-0/+45
Add support for the V4L2_PIX_FMT_YUVA32 and V4L2_PIX_FMT_YUVX32 pixel formats in the v4l2-ctl, v4l2-compliance, qvidcap and qv4l2 utilities. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-08-29test-media: check results of cmp in the vicodec testsHans Verkuil1-3/+28
While the vicodec tests did verify if the output of several decode tests was what was expected by using 'cmp', it did not report the result in a 'FAIL/OK' format, so failures would not be detected during the daily build. Fix this to prevent undetected regressions in the future. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-08-26libdvbv5: fix string overreadHans Verkuil1-1/+3
Fixes: dvb-dev-remote.c:1539:15: warning: 'send_buf' reading 80 bytes from a region of size 13 [-Wstringop-overread] Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-08-26xc3028-firmware: fix use-after-freeHans Verkuil1-2/+4
Fixes: firmware-tool.c:702:51: warning: pointer 'temp_data' may be used after 'free' [-Wuse-after-free] Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-08-24v4l2-compliance: test of vivid's pixel array in requestsHans Verkuil1-2/+59
Verify that using an array control in a request works fine. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-08-24v4l2-compliance: check vivid pixel array control behaviorHans Verkuil2-0/+56
Changing the input will change the format, which will also change the dimensions of the pixel array control, and reset the contents of that array to the default value. Check that this is in fact happening. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-08-24v4l2-ctl: show all dimensions for V4L2_EVENT_CTRL_CH_DIMENSIONSHans Verkuil1-1/+4
Don't show just the first changed dimension, show all dimensions. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-08-24v4l2-ctl: add support for V4L2_EVENT_CTRL_CH_DIMENSIONSHans Verkuil3-7/+16
If this flag is set, get the new dimensions and show it. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-08-24v4l-utils: sync with upstream kernelHans Verkuil7-15/+125
Sync with the latest https://git.linuxtv.org/media_stage.git/ kernel. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-07-28v4l2-ctl/rds-ctl: move tuner info helpers to v4l2-info.cppHans Verkuil4-185/+128
Move the helper functions to decode tuner/modulator related fields to v4l2-info.cpp to avoid code duplication in between v4l2-ctl and rds-ctl. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
2022-07-28rds-ctl: drop cap2s(), use v4l2_info_capability() insteadHans Verkuil3-44/+5
Use the helper function v4l2_info_capability() from v4l2-info.cpp to show the driver info instead of duplicating that code. Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>

Privacy Policy