summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@s-opensource.com>2016-09-08 06:41:26 -0300
committerMauro Carvalho Chehab <mchehab@s-opensource.com>2016-09-09 09:57:23 -0300
commit56683d7dea0ecc3045b3041bc9071eb4fb72c4fb (patch)
tree45f574dca8b1c65fb2f8c4489050da88807ea385
parentbe831b34c2182731df77710e2fb8130060b1012f (diff)
[media] docs-rst: fix cross-references for videodev2.h
There are several broken references there, due to the conversion to C domain. Fix them using this shell script and manually adjust what's broken: # funcs is a file with the broken functions/references for i in $(cat funcs|sort|uniq|perl -ne 'print "$1\n" if (m/(\S+)$/)'); do i=${i//-/_} echo $i j=${i//_/-} for k in $(git grep -l "_$j:" Documentation/); do sed s,\_$j\:,"c\:type\:\: $i", <$k >a && mv a $k done for k in $(git grep -l "$j" Documentation/media/*.exceptions); do sed s,$j,":c\:type\:\`$i\`", <$k >a && mv a $k done for k in $(git grep -l "$j" Documentation/); do sed "s,:ref:\`$i <$j>\`,:c:type:\`$i\`," <$k >a && mv a $k sed "s,:ref:\`$j\`,:c:type:\`$i\`," <$k >a && mv a $k sed -E "s,:ref:\`(.*)<$j>\`,:c:type:\`\1<$i>\`," <$k >a && mv a $k done for k in $(git grep -l "<$j>" include/media); do sed -E "s,:ref:\`(.*)<$j>\`,enum \&$i," <$k >a && mv a $k done done Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
-rw-r--r--Documentation/media/uapi/v4l/buffer.rst14
-rw-r--r--Documentation/media/uapi/v4l/field-order.rst4
-rw-r--r--Documentation/media/uapi/v4l/hist-v4l2.rst30
-rw-r--r--Documentation/media/uapi/v4l/pixfmt-002.rst10
-rw-r--r--Documentation/media/uapi/v4l/pixfmt-003.rst10
-rw-r--r--Documentation/media/uapi/v4l/pixfmt-006.rst16
-rw-r--r--Documentation/media/uapi/v4l/planar-apis.rst2
-rw-r--r--Documentation/media/uapi/v4l/subdev-formats.rst10
-rw-r--r--Documentation/media/uapi/v4l/tuner.rst4
-rw-r--r--Documentation/media/uapi/v4l/v4l2.rst4
-rw-r--r--Documentation/media/uapi/v4l/vidioc-create-bufs.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-cropcap.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-dbg-g-register.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-dqevent.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-enum-fmt.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-enum-frameintervals.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-enum-framesizes.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-enum-freq-bands.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-expbuf.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-g-crop.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-g-edid.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-g-fbuf.rst4
-rw-r--r--Documentation/media/uapi/v4l/vidioc-g-fmt.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-g-frequency.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-g-modulator.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-g-parm.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-g-selection.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-g-sliced-vbi-cap.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-g-tuner.rst4
-rw-r--r--Documentation/media/uapi/v4l/vidioc-querycap.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-queryctrl.rst4
-rw-r--r--Documentation/media/uapi/v4l/vidioc-reqbufs.rst4
-rw-r--r--Documentation/media/uapi/v4l/vidioc-s-hw-freq-seek.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-subdev-enum-frame-interval.rst7
-rw-r--r--Documentation/media/uapi/v4l/vidioc-subdev-enum-frame-size.rst6
-rw-r--r--Documentation/media/uapi/v4l/vidioc-subdev-enum-mbus-code.rst6
-rw-r--r--Documentation/media/uapi/v4l/vidioc-subdev-g-crop.rst8
-rw-r--r--Documentation/media/uapi/v4l/vidioc-subdev-g-fmt.rst2
-rw-r--r--Documentation/media/uapi/v4l/vidioc-subdev-g-frame-interval.rst8
-rw-r--r--Documentation/media/uapi/v4l/vidioc-subdev-g-selection.rst4
-rw-r--r--Documentation/media/videodev2.h.rst.exceptions204
41 files changed, 201 insertions, 202 deletions
diff --git a/Documentation/media/uapi/v4l/buffer.rst b/Documentation/media/uapi/v4l/buffer.rst
index e71a458712d3..21893ee1384a 100644
--- a/Documentation/media/uapi/v4l/buffer.rst
+++ b/Documentation/media/uapi/v4l/buffer.rst
@@ -74,7 +74,7 @@ struct v4l2_buffer
- Type of the buffer, same as struct
:c:type:`v4l2_format` ``type`` or struct
:c:type:`v4l2_requestbuffers` ``type``, set
- by the application. See :ref:`v4l2-buf-type`
+ by the application. See :c:type:`v4l2_buf_type`
- .. row 3
@@ -110,7 +110,7 @@ struct v4l2_buffer
-
- Indicates the field order of the image in the buffer, see
- :ref:`v4l2-field`. This field is not used when the buffer
+ :c:type:`v4l2_field`. This field is not used when the buffer
contains VBI data. Drivers must set it when ``type`` refers to a
capture stream, applications when it refers to an output stream.
@@ -142,7 +142,7 @@ struct v4l2_buffer
- When ``type`` is ``V4L2_BUF_TYPE_VIDEO_CAPTURE`` and the
``V4L2_BUF_FLAG_TIMECODE`` flag is set in ``flags``, this
structure contains a frame timecode. In
- :ref:`V4L2_FIELD_ALTERNATE <v4l2-field>` mode the top and
+ :c:type:`V4L2_FIELD_ALTERNATE <v4l2_field>` mode the top and
bottom field contain the same timecode. Timecodes are intended to
help video editing and are typically recorded on video tapes, but
also embedded in compressed formats like MPEG. This field is
@@ -162,7 +162,7 @@ struct v4l2_buffer
- :cspan:`3`
- In :ref:`V4L2_FIELD_ALTERNATE <v4l2-field>` mode the top and
+ In :c:type:`V4L2_FIELD_ALTERNATE <v4l2_field>` mode the top and
bottom field have the same sequence number. The count starts at
zero and includes dropped or repeated frames. A dropped frame was
received by an input device but could not be stored due to lack of
@@ -187,7 +187,7 @@ struct v4l2_buffer
-
- This field must be set by applications and/or drivers in
- accordance with the selected I/O method. See :ref:`v4l2-memory`
+ accordance with the selected I/O method. See :c:type:`v4l2_memory`
- .. row 11
@@ -402,7 +402,7 @@ struct v4l2_plane
-.. _v4l2-buf-type:
+.. c:type:: v4l2_buf_type
enum v4l2_buf_type
==================
@@ -773,7 +773,7 @@ Buffer Flags
-.. _v4l2-memory:
+.. c:type:: v4l2_memory
enum v4l2_memory
================
diff --git a/Documentation/media/uapi/v4l/field-order.rst b/Documentation/media/uapi/v4l/field-order.rst
index 1fa082f34c6f..0d71d5a3fbde 100644
--- a/Documentation/media/uapi/v4l/field-order.rst
+++ b/Documentation/media/uapi/v4l/field-order.rst
@@ -52,11 +52,11 @@ this end applications initialize the ``field`` field of struct
should have the value ``V4L2_FIELD_ANY`` (0).
-.. _v4l2-field:
-
enum v4l2_field
===============
+.. c:type:: v4l2_field
+
.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
.. flat-table::
diff --git a/Documentation/media/uapi/v4l/hist-v4l2.rst b/Documentation/media/uapi/v4l/hist-v4l2.rst
index d86d6343a20a..dfd55e9066b3 100644
--- a/Documentation/media/uapi/v4l/hist-v4l2.rst
+++ b/Documentation/media/uapi/v4l/hist-v4l2.rst
@@ -438,7 +438,7 @@ This unnamed version was finally merged into Linux 2.5.46.
``VIDIOC_S_FMT`` and ``VIDIOC_TRY_FMT``; ioctl. The ``VIDIOC_G_WIN``
and ``VIDIOC_S_WIN`` ioctls to prepare for a video overlay were
removed. The ``type`` field changed to type enum
- :ref:`v4l2_buf_type <v4l2-buf-type>` and the buffer type names
+ :c:type:`v4l2_buf_type` and the buffer type names
changed as follows.
@@ -452,7 +452,7 @@ This unnamed version was finally merged into Linux 2.5.46.
- Old defines
- - enum :ref:`v4l2_buf_type <v4l2-buf-type>`
+ - enum :c:type:`v4l2_buf_type`
- .. row 2
@@ -534,7 +534,7 @@ This unnamed version was finally merged into Linux 2.5.46.
10. In struct :c:type:`v4l2_fmtdesc` a enum
- :ref:`v4l2_buf_type <v4l2-buf-type>` field named ``type`` was
+ :c:type:`v4l2_buf_type` field named ``type`` was
added as in struct :c:type:`v4l2_format`. The
``VIDIOC_ENUM_FBUFFMT`` ioctl is no longer needed and was removed.
These calls can be replaced by
@@ -555,7 +555,7 @@ This unnamed version was finally merged into Linux 2.5.46.
itself was removed.
The interlace flags were replaced by a enum
- :ref:`v4l2_field <v4l2-field>` value in a newly added ``field``
+ :c:type:`v4l2_field` value in a newly added ``field``
field.
@@ -569,7 +569,7 @@ This unnamed version was finally merged into Linux 2.5.46.
- Old flag
- - enum :ref:`v4l2_field <v4l2-field>`
+ - enum :c:type:`v4l2_field`
- .. row 2
@@ -615,23 +615,23 @@ This unnamed version was finally merged into Linux 2.5.46.
The color space flags were replaced by a enum
- :ref:`v4l2_colorspace <v4l2-colorspace>` value in a newly added
+ :c:type:`v4l2_colorspace` value in a newly added
``colorspace`` field, where one of ``V4L2_COLORSPACE_SMPTE170M``,
``V4L2_COLORSPACE_BT878``, ``V4L2_COLORSPACE_470_SYSTEM_M`` or
``V4L2_COLORSPACE_470_SYSTEM_BG`` replaces ``V4L2_FMT_CS_601YUV``.
12. In struct :c:type:`v4l2_requestbuffers` the
``type`` field was properly defined as enum
- :ref:`v4l2_buf_type <v4l2-buf-type>`. Buffer types changed as
+ :c:type:`v4l2_buf_type`. Buffer types changed as
mentioned above. A new ``memory`` field of type enum
- :ref:`v4l2_memory <v4l2-memory>` was added to distinguish between
+ :c:type:`v4l2_memory` was added to distinguish between
I/O methods using buffers allocated by the driver or the
application. See :ref:`io` for details.
13. In struct :c:type:`v4l2_buffer` the ``type`` field was
- properly defined as enum :ref:`v4l2_buf_type <v4l2-buf-type>`.
+ properly defined as enum :c:type:`v4l2_buf_type`.
Buffer types changed as mentioned above. A ``field`` field of type
- enum :ref:`v4l2_field <v4l2-field>` was added to indicate if a
+ enum :c:type:`v4l2_field` was added to indicate if a
buffer contains a top or bottom field. The old field flags were
removed. Since no unadjusted system time clock was added to the
kernel as planned, the ``timestamp`` field changed back from type
@@ -639,7 +639,7 @@ This unnamed version was finally merged into Linux 2.5.46.
nanoseconds, to struct :c:type:`timeval`. With the addition
of a second memory mapping method the ``offset`` field moved into
union ``m``, and a new ``memory`` field of type enum
- :ref:`v4l2_memory <v4l2-memory>` was added to distinguish between
+ :c:type:`v4l2_memory` was added to distinguish between
I/O methods. See :ref:`io` for details.
The ``V4L2_BUF_REQ_CONTIG`` flag was used by the V4L compatibility
@@ -667,7 +667,7 @@ This unnamed version was finally merged into Linux 2.5.46.
16. In struct :c:type:`v4l2_window` the ``x``, ``y``,
``width`` and ``height`` field moved into a ``w`` substructure as
- above. A ``field`` field of type %v4l2-field; was added to
+ above. A ``field`` field of type :c:type:`v4l2_field` was added to
distinguish between field and frame (interlaced) overlay.
17. The digital zoom interface, including struct
@@ -1029,7 +1029,7 @@ V4L2 in Linux 2.6.22
====================
1. Two new field orders ``V4L2_FIELD_INTERLACED_TB`` and
- ``V4L2_FIELD_INTERLACED_BT`` were added. See :ref:`v4l2-field` for
+ ``V4L2_FIELD_INTERLACED_BT`` were added. See :c:type:`v4l2_field` for
details.
2. Three new clipping/blending methods with a global or straight or
@@ -1357,8 +1357,8 @@ V4L2 in Linux 3.19
==================
1. Rewrote Colorspace chapter, added new enum
- :ref:`v4l2_ycbcr_encoding <v4l2-ycbcr-encoding>` and enum
- :ref:`v4l2_quantization <v4l2-quantization>` fields to struct
+ :c:type:`v4l2_ycbcr_encoding` and enum
+ :c:type:`v4l2_quantization` fields to struct
:c:type:`v4l2_pix_format`, struct
:c:type:`v4l2_pix_format_mplane` and
struct :c:type:`v4l2_mbus_framefmt`.
diff --git a/Documentation/media/uapi/v4l/pixfmt-002.rst b/Documentation/media/uapi/v4l/pixfmt-002.rst
index 28f14e41631c..fd73f4697878 100644
--- a/Documentation/media/uapi/v4l/pixfmt-002.rst
+++ b/Documentation/media/uapi/v4l/pixfmt-002.rst
@@ -61,7 +61,7 @@ Single-planar format structure
- .. row 5
- - enum :ref:`v4l2_field <v4l2-field>`
+ - enum :c:type::`v4l2_field`
- ``field``
@@ -121,7 +121,7 @@ Single-planar format structure
- .. row 9
- - enum :ref:`v4l2_colorspace <v4l2-colorspace>`
+ - enum :c:type:`v4l2_colorspace`
- ``colorspace``
@@ -170,7 +170,7 @@ Single-planar format structure
- .. row 12
- - enum :ref:`v4l2_ycbcr_encoding <v4l2-ycbcr-encoding>`
+ - enum :c:type:`v4l2_ycbcr_encoding`
- ``ycbcr_enc``
@@ -180,7 +180,7 @@ Single-planar format structure
- .. row 13
- - enum :ref:`v4l2_quantization <v4l2-quantization>`
+ - enum :c:type:`v4l2_quantization`
- ``quantization``
@@ -190,7 +190,7 @@ Single-planar format structure
- .. row 14
- - enum :ref:`v4l2_xfer_func <v4l2-xfer-func>`
+ - enum :c:type:`v4l2_xfer_func`
- ``xfer_func``
diff --git a/Documentation/media/uapi/v4l/pixfmt-003.rst b/Documentation/media/uapi/v4l/pixfmt-003.rst
index e39fa2b732d7..a3c83df3bce5 100644
--- a/Documentation/media/uapi/v4l/pixfmt-003.rst
+++ b/Documentation/media/uapi/v4l/pixfmt-003.rst
@@ -88,7 +88,7 @@ describing all planes of that format.
- .. row 4
- - enum :ref:`v4l2_field <v4l2-field>`
+ - enum :c:type:`v4l2_field`
- ``field``
@@ -96,7 +96,7 @@ describing all planes of that format.
- .. row 5
- - enum :ref:`v4l2_colorspace <v4l2-colorspace>`
+ - enum :c:type:`v4l2_colorspace`
- ``colorspace``
@@ -131,7 +131,7 @@ describing all planes of that format.
- .. row 9
- - enum :ref:`v4l2_ycbcr_encoding <v4l2-ycbcr-encoding>`
+ - enum :c:type:`v4l2_ycbcr_encoding`
- ``ycbcr_enc``
@@ -141,7 +141,7 @@ describing all planes of that format.
- .. row 10
- - enum :ref:`v4l2_quantization <v4l2-quantization>`
+ - enum :c:type:`v4l2_quantization`
- ``quantization``
@@ -151,7 +151,7 @@ describing all planes of that format.
- .. row 11
- - enum :ref:`v4l2_xfer_func <v4l2-xfer-func>`
+ - enum :c:type:`v4l2_xfer_func`
- ``xfer_func``
diff --git a/Documentation/media/uapi/v4l/pixfmt-006.rst b/Documentation/media/uapi/v4l/pixfmt-006.rst
index a97fc28e039d..819299d0291a 100644
--- a/Documentation/media/uapi/v4l/pixfmt-006.rst
+++ b/Documentation/media/uapi/v4l/pixfmt-006.rst
@@ -5,15 +5,15 @@ Defining Colorspaces in V4L2
****************************
In V4L2 colorspaces are defined by four values. The first is the
-colorspace identifier (enum :ref:`v4l2_colorspace <v4l2-colorspace>`)
+colorspace identifier (enum :c:type:`v4l2_colorspace`)
which defines the chromaticities, the default transfer function, the
default Y'CbCr encoding and the default quantization method. The second
is the transfer function identifier (enum
-:ref:`v4l2_xfer_func <v4l2-xfer-func>`) to specify non-standard
+:c:type:`v4l2_xfer_func`) to specify non-standard
transfer functions. The third is the Y'CbCr encoding identifier (enum
-:ref:`v4l2_ycbcr_encoding <v4l2-ycbcr-encoding>`) to specify
+:c:type:`v4l2_ycbcr_encoding`) to specify
non-standard Y'CbCr encodings and the fourth is the quantization
-identifier (enum :ref:`v4l2_quantization <v4l2-quantization>`) to
+identifier (enum :c:type:`v4l2_quantization`) to
specify non-standard quantization methods. Most of the time only the
colorspace field of struct :c:type:`v4l2_pix_format`
or struct :c:type:`v4l2_pix_format_mplane`
@@ -27,7 +27,7 @@ needs to be filled in.
.. tabularcolumns:: |p{6.0cm}|p{11.5cm}|
-.. _v4l2-colorspace:
+.. c:type:: v4l2_colorspace
.. flat-table:: V4L2 Colorspaces
:header-rows: 1
@@ -119,7 +119,7 @@ needs to be filled in.
-.. _v4l2-xfer-func:
+.. c:type:: v4l2_xfer_func
.. flat-table:: V4L2 Transfer Function
:header-rows: 1
@@ -182,7 +182,7 @@ needs to be filled in.
-.. _v4l2-ycbcr-encoding:
+.. c:type:: v4l2_ycbcr_encoding
.. tabularcolumns:: |p{6.5cm}|p{11.0cm}|
@@ -247,7 +247,7 @@ needs to be filled in.
-.. _v4l2-quantization:
+.. c:type:: v4l2_quantization
.. tabularcolumns:: |p{6.5cm}|p{11.0cm}|
diff --git a/Documentation/media/uapi/v4l/planar-apis.rst b/Documentation/media/uapi/v4l/planar-apis.rst
index bd0f88b01c9a..4e059fb44153 100644
--- a/Documentation/media/uapi/v4l/planar-apis.rst
+++ b/Documentation/media/uapi/v4l/planar-apis.rst
@@ -22,7 +22,7 @@ application can choose whether to use one or the other by passing a
corresponding buffer type to its ioctl calls. Multi-planar versions of
buffer types are suffixed with an ``_MPLANE`` string. For a list of
available multi-planar buffer types see enum
-:ref:`v4l2_buf_type <v4l2-buf-type>`.
+:c:type:`v4l2_buf_type`.
Multi-planar formats
diff --git a/Documentation/media/uapi/v4l/subdev-formats.rst b/Documentation/media/uapi/v4l/subdev-formats.rst
index f0d7754f1906..568d5dd56561 100644
--- a/Documentation/media/uapi/v4l/subdev-formats.rst
+++ b/Documentation/media/uapi/v4l/subdev-formats.rst
@@ -46,7 +46,7 @@ Media Bus Formats
- ``field``
- - Field order, from enum :ref:`v4l2_field <v4l2-field>`. See
+ - Field order, from enum :c:type:`v4l2_field`. See
:ref:`field-order` for details.
- .. row 5
@@ -56,12 +56,12 @@ Media Bus Formats
- ``colorspace``
- Image colorspace, from enum
- :ref:`v4l2_colorspace <v4l2-colorspace>`. See
+ :c:type:`v4l2_colorspace`. See
:ref:`colorspaces` for details.
- .. row 6
- - enum :ref:`v4l2_ycbcr_encoding <v4l2-ycbcr-encoding>`
+ - enum :c:type:`v4l2_ycbcr_encoding`
- ``ycbcr_enc``
@@ -71,7 +71,7 @@ Media Bus Formats
- .. row 7
- - enum :ref:`v4l2_quantization <v4l2-quantization>`
+ - enum :c:type:`v4l2_quantization`
- ``quantization``
@@ -81,7 +81,7 @@ Media Bus Formats
- .. row 8
- - enum :ref:`v4l2_xfer_func <v4l2-xfer-func>`
+ - enum :c:type:`v4l2_xfer_func`
- ``xfer_func``
diff --git a/Documentation/media/uapi/v4l/tuner.rst b/Documentation/media/uapi/v4l/tuner.rst
index 4064841d8963..ad117b068831 100644
--- a/Documentation/media/uapi/v4l/tuner.rst
+++ b/Documentation/media/uapi/v4l/tuner.rst
@@ -33,8 +33,8 @@ current video or radio input is queried.
:ref:`VIDIOC_S_TUNER <VIDIOC_G_TUNER>` does not switch the
current tuner, when there is more than one at all. The tuner is solely
determined by the current video input. Drivers must support both ioctls
- and set the ``V4L2_CAP_TUNER`` flag in the struct :ref:`v4l2_capability
- <v4l2-capability>` returned by the :ref:`VIDIOC_QUERYCAP` ioctl when the
+ and set the ``V4L2_CAP_TUNER`` flag in the struct :c:type:`v4l2_capability`
+ returned by the :ref:`VIDIOC_QUERYCAP` ioctl when the
device has one or more tuners.
diff --git a/Documentation/media/uapi/v4l/v4l2.rst b/Documentation/media/uapi/v4l/v4l2.rst
index e020c57f98d4..55b959dda07e 100644
--- a/Documentation/media/uapi/v4l/v4l2.rst
+++ b/Documentation/media/uapi/v4l/v4l2.rst
@@ -112,8 +112,8 @@ DVB device nodes. Add support for Tuner sub-device.
:revision: 3.19 / 2014-12-05 (*hv*)
Rewrote Colorspace chapter, added new enum
-:ref:`v4l2_ycbcr_encoding <v4l2-ycbcr-encoding>` and enum
-:ref:`v4l2_quantization <v4l2-quantization>` fields to struct
+:c:type:`v4l2_ycbcr_encoding` and enum
+:c:type:`v4l2_quantization` fields to struct
:c:type:`v4l2_pix_format`, struct
:c:type:`v4l2_pix_format_mplane` and struct
:c:type:`v4l2_mbus_framefmt`.
diff --git a/Documentation/media/uapi/v4l/vidioc-create-bufs.rst b/Documentation/media/uapi/v4l/vidioc-create-bufs.rst
index b93422400608..810634e47d54 100644
--- a/Documentation/media/uapi/v4l/vidioc-create-bufs.rst
+++ b/Documentation/media/uapi/v4l/vidioc-create-bufs.rst
@@ -111,7 +111,7 @@ than the number requested.
- Applications set this field to ``V4L2_MEMORY_MMAP``,
``V4L2_MEMORY_DMABUF`` or ``V4L2_MEMORY_USERPTR``. See
- :ref:`v4l2-memory`
+ :c:type:`v4l2_memory`
- .. row 4
diff --git a/Documentation/media/uapi/v4l/vidioc-cropcap.rst b/Documentation/media/uapi/v4l/vidioc-cropcap.rst
index 945596fcd65f..f7d448cad4eb 100644
--- a/Documentation/media/uapi/v4l/vidioc-cropcap.rst
+++ b/Documentation/media/uapi/v4l/vidioc-cropcap.rst
@@ -69,7 +69,7 @@ overlay devices.
- Type of the data stream, set by the application. Only these types
are valid here: ``V4L2_BUF_TYPE_VIDEO_CAPTURE``,
``V4L2_BUF_TYPE_VIDEO_OUTPUT`` and
- ``V4L2_BUF_TYPE_VIDEO_OVERLAY``. See :ref:`v4l2-buf-type`.
+ ``V4L2_BUF_TYPE_VIDEO_OVERLAY``. See :c:type:`v4l2_buf_type`.
- .. row 2
diff --git a/Documentation/media/uapi/v4l/vidioc-dbg-g-register.rst b/Documentation/media/uapi/v4l/vidioc-dbg-g-register.rst
index 08f3c510e440..b875ee2aece7 100644
--- a/Documentation/media/uapi/v4l/vidioc-dbg-g-register.rst
+++ b/Documentation/media/uapi/v4l/vidioc-dbg-g-register.rst
@@ -144,7 +144,7 @@ instructions.
- ``match``
- - How to match the chip, see :ref:`v4l2-dbg-match`.
+ - How to match the chip, see :c:type:`v4l2_dbg_match`.
- .. row 2
diff --git a/Documentation/media/uapi/v4l/vidioc-dqevent.rst b/Documentation/media/uapi/v4l/vidioc-dqevent.rst
index 1e435ab674a2..6347d2f83a44 100644
--- a/Documentation/media/uapi/v4l/vidioc-dqevent.rst
+++ b/Documentation/media/uapi/v4l/vidioc-dqevent.rst
@@ -324,7 +324,7 @@ call.
- ``field``
- - The upcoming field. See enum :ref:`v4l2_field <v4l2-field>`.
+ - The upcoming field. See enum :c:type:`v4l2_field`.
diff --git a/Documentation/media/uapi/v4l/vidioc-enum-fmt.rst b/Documentation/media/uapi/v4l/vidioc-enum-fmt.rst
index 1df8fccf067f..91fbc4ba209c 100644
--- a/Documentation/media/uapi/v4l/vidioc-enum-fmt.rst
+++ b/Documentation/media/uapi/v4l/vidioc-enum-fmt.rst
@@ -73,7 +73,7 @@ one until ``EINVAL`` is returned.
``V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE``,
``V4L2_BUF_TYPE_VIDEO_OUTPUT``,
``V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE`` and
- ``V4L2_BUF_TYPE_VIDEO_OVERLAY``. See :ref:`v4l2-buf-type`.
+ ``V4L2_BUF_TYPE_VIDEO_OVERLAY``. See :c:type:`v4l2_buf_type`.
- .. row 3
diff --git a/Documentation/media/uapi/v4l/vidioc-enum-frameintervals.rst b/Documentation/media/uapi/v4l/vidioc-enum-frameintervals.rst
index 07e94420c4c5..83f641f9f231 100644
--- a/Documentation/media/uapi/v4l/vidioc-enum-frameintervals.rst
+++ b/Documentation/media/uapi/v4l/vidioc-enum-frameintervals.rst
@@ -231,7 +231,7 @@ Enums
=====
-.. _v4l2-frmivaltypes:
+.. c:type:: v4l2_frmivaltypes
.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
diff --git a/Documentation/media/uapi/v4l/vidioc-enum-framesizes.rst b/Documentation/media/uapi/v4l/vidioc-enum-framesizes.rst
index a4ddfe9f8956..9a9571d11f7d 100644
--- a/Documentation/media/uapi/v4l/vidioc-enum-framesizes.rst
+++ b/Documentation/media/uapi/v4l/vidioc-enum-framesizes.rst
@@ -254,7 +254,7 @@ Enums
=====
-.. _v4l2-frmsizetypes:
+.. c:type:: v4l2_frmsizetypes
.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
diff --git a/Documentation/media/uapi/v4l/vidioc-enum-freq-bands.rst b/Documentation/media/uapi/v4l/vidioc-enum-freq-bands.rst
index c38478227031..cc27ad4e2fa7 100644
--- a/Documentation/media/uapi/v4l/vidioc-enum-freq-bands.rst
+++ b/Documentation/media/uapi/v4l/vidioc-enum-freq-bands.rst
@@ -75,7 +75,7 @@ of the corresponding tuner/modulator is set.
set to ``V4L2_TUNER_RADIO`` for ``/dev/radioX`` device nodes, and
to ``V4L2_TUNER_ANALOG_TV`` for all others. Set this field to
``V4L2_TUNER_RADIO`` for modulators (currently only radio
- modulators are supported). See :ref:`v4l2-tuner-type`
+ modulators are supported). See :c:type:`v4l2_tuner_type`
- .. row 3
diff --git a/Documentation/media/uapi/v4l/vidioc-expbuf.rst b/Documentation/media/uapi/v4l/vidioc-expbuf.rst
index 650757ad8aed..2ae2f5483351 100644
--- a/Documentation/media/uapi/v4l/vidioc-expbuf.rst
+++ b/Documentation/media/uapi/v4l/vidioc-expbuf.rst
@@ -133,7 +133,7 @@ Examples
- Type of the buffer, same as struct
:c:type:`v4l2_format` ``type`` or struct
:c:type:`v4l2_requestbuffers` ``type``, set
- by the application. See :ref:`v4l2-buf-type`
+ by the application. See :c:type:`v4l2_buf_type`
- .. row 2
diff --git a/Documentation/media/uapi/v4l/vidioc-g-crop.rst b/Documentation/media/uapi/v4l/vidioc-g-crop.rst
index 4ddd8c08fd1c..9b24ca591ea4 100644
--- a/Documentation/media/uapi/v4l/vidioc-g-crop.rst
+++ b/Documentation/media/uapi/v4l/vidioc-g-crop.rst
@@ -94,7 +94,7 @@ When cropping is not supported then no parameters are changed and
- Type of the data stream, set by the application. Only these types
are valid here: ``V4L2_BUF_TYPE_VIDEO_CAPTURE``,
``V4L2_BUF_TYPE_VIDEO_OUTPUT`` and
- ``V4L2_BUF_TYPE_VIDEO_OVERLAY``. See :ref:`v4l2-buf-type`.
+ ``V4L2_BUF_TYPE_VIDEO_OVERLAY``. See :c:type:`v4l2_buf_type`.
- .. row 2
diff --git a/Documentation/media/uapi/v4l/vidioc-g-edid.rst b/Documentation/media/uapi/v4l/vidioc-g-edid.rst
index b288d8ee49ef..1fffca7cc38f 100644
--- a/Documentation/media/uapi/v4l/vidioc-g-edid.rst
+++ b/Documentation/media/uapi/v4l/vidioc-g-edid.rst
@@ -97,7 +97,7 @@ the EDID data in some way. In any case, the end result is the same: the
EDID is no longer available.
-.. _v4l2-edid:
+.. c:type:: v4l2_edid
.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
diff --git a/Documentation/media/uapi/v4l/vidioc-g-fbuf.rst b/Documentation/media/uapi/v4l/vidioc-g-fbuf.rst
index 4ac2625e545d..1ad40a9dd743 100644
--- a/Documentation/media/uapi/v4l/vidioc-g-fbuf.rst
+++ b/Documentation/media/uapi/v4l/vidioc-g-fbuf.rst
@@ -200,7 +200,7 @@ destructive video overlay.
- .. row 12
-
- - enum :ref:`v4l2_field <v4l2-field>`
+ - enum :c:type:`v4l2_field`
- ``field``
@@ -266,7 +266,7 @@ destructive video overlay.
- .. row 16
-
- - enum :ref:`v4l2_colorspace <v4l2-colorspace>`
+ - enum :c:type:`v4l2_colorspace`
-