media: core: Report the maximum possible number of buffers for the queue
authorBenjamin Gaignard <benjamin.gaignard@collabora.com>
Thu, 9 Nov 2023 16:35:00 +0000 (17:35 +0100)
committerMauro Carvalho Chehab <mchehab@kernel.org>
Thu, 23 Nov 2023 11:38:05 +0000 (12:38 +0100)
commitd055a76c006540defd4eb80dcdea217cee0a141a
treea950d391cfd3be26f0ffc2672c066472fd032446
parentc838530d230bc638d79b78737fc4488ffc28c1ee
media: core: Report the maximum possible number of buffers for the queue

Use one of the struct v4l2_create_buffers reserved bytes to report
the maximum possible number of buffers for the queue.
V4l2 framework set V4L2_BUF_CAP_SUPPORTS_MAX_NUM_BUFFERS flags in queue
capabilities so userland can know when the field is valid.
Does the same change in v4l2_create_buffers32 structure.

Signed-off-by: Benjamin Gaignard <benjamin.gaignard@collabora.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Documentation/userspace-api/media/v4l/vidioc-create-bufs.rst
Documentation/userspace-api/media/v4l/vidioc-reqbufs.rst
drivers/media/common/videobuf2/videobuf2-v4l2.c
drivers/media/v4l2-core/v4l2-compat-ioctl32.c
drivers/media/v4l2-core/v4l2-ioctl.c
include/uapi/linux/videodev2.h