All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX
@ 2016-08-19 13:04 Mauro Carvalho Chehab
  2016-08-19 13:04 ` [PATCH 01/15] [media] vidioc-dqevent.rst: adjust two table columns for LaTeX output Mauro Carvalho Chehab
                   ` (14 more replies)
  0 siblings, 15 replies; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:04 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser

This patch series addresses (almost all) remaining issues of texts going
out of the page width.

There are just two places that need fixes:
	- Two big tables at Documentation/media/uapi/v4l/subdev-formats.rst;
	- some texts at Documentation/media/uapi/v4l/extended-controls.rst
	  with very long constants (like
	  V4L2_CID_MPEG_VIDEO_H264_SEI_FP_ARRANGEMENT_TYPE)
	  that are linked to very long enum types.

Yet, as mentioned on the previous patch series, some tables don't look
nice. Basically, the flat-tables with cspan columns on it are not
formatted well in LaTeX output. The tables go out of the left margin on
several such cases. Yet, all text are at the visible area. So, the
document is readable on screen. Also, on such tables, texts with more
than one line on span cells are not left-margin justified, and their
size is not well calculated. So, usually, it uses more lines than what
would be needed.

Yet, the document output is OK for usage, IMHO.


Mauro Carvalho Chehab (15):
  [media] vidioc-dqevent.rst: adjust two table columns for LaTeX output
  [media] vidioc-dv-timings-cap.rst: Adjust LaTeX columns
  [media] vidioc-enumstd.rst: adjust video standards table
  [media] vidioc-g-sliced-vbi-cap.rst: make tables fit on LaTeX output
  [media] adjust some vidioc-*rst tables with wrong columns
  [media] vidioc-g-tuner.rst: improve documentation for tuner type
  [media] vidioc-g-tuner.rst: Fix tables to fit at LaTeX output
  [media] fix v4l2-selection-*.rst tables for LaTeX output
  [media] fe_property_parameters.rst: Adjust column sizes
  [media] adjust remaining tables at DVB uAPI documentation
  [media] media-types.rst: adjust tables to fit on LaTeX output
  [media] docs-rst: move cec kAPI documentation to the media book
  [media] cec-core: Convert it to ReST format
  [media] uapi/cec: adjust tables on LaTeX output
  [media] gen-errors.rst fix error table column limits

 Documentation/{cec.txt => media/kapi/cec-core.rst} | 145 +++++++++++++--------
 Documentation/media/media_kapi.rst                 |   1 +
 .../media/uapi/cec/cec-ioc-adap-g-caps.rst         |   4 +-
 .../media/uapi/cec/cec-ioc-adap-g-log-addrs.rst    |   6 +-
 Documentation/media/uapi/cec/cec-ioc-dqevent.rst   |  23 ++--
 Documentation/media/uapi/cec/cec-ioc-g-mode.rst    |   6 +-
 Documentation/media/uapi/cec/cec-ioc-receive.rst   |   6 +-
 Documentation/media/uapi/dvb/audio-fopen.rst       |   2 +
 Documentation/media/uapi/dvb/ca-fopen.rst          |   2 +
 Documentation/media/uapi/dvb/dmx-fread.rst         |   3 +-
 Documentation/media/uapi/dvb/dmx-fwrite.rst        |   2 +
 .../media/uapi/dvb/dmx-set-pes-filter.rst          |   2 +-
 Documentation/media/uapi/dvb/dmx-start.rst         |   2 +-
 Documentation/media/uapi/dvb/dmx_types.rst         |   1 +
 Documentation/media/uapi/dvb/fe-get-info.rst       |   1 +
 Documentation/media/uapi/dvb/fe-read-status.rst    |   1 +
 .../media/uapi/dvb/fe_property_parameters.rst      |   3 +
 Documentation/media/uapi/dvb/video-fopen.rst       |   2 +
 Documentation/media/uapi/gen-errors.rst            |   2 +-
 Documentation/media/uapi/mediactl/media-types.rst  |  14 +-
 .../media/uapi/v4l/v4l2-selection-flags.rst        |   1 +
 .../media/uapi/v4l/v4l2-selection-targets.rst      |   2 +
 Documentation/media/uapi/v4l/vidioc-dqevent.rst    |   8 +-
 .../media/uapi/v4l/vidioc-dv-timings-cap.rst       |  14 +-
 Documentation/media/uapi/v4l/vidioc-enum-fmt.rst   |   4 +-
 .../media/uapi/v4l/vidioc-enum-freq-bands.rst      |   5 +-
 Documentation/media/uapi/v4l/vidioc-enuminput.rst  |   2 +
 Documentation/media/uapi/v4l/vidioc-enumoutput.rst |   2 +-
 Documentation/media/uapi/v4l/vidioc-enumstd.rst    |  23 +++-
 .../media/uapi/v4l/vidioc-g-dv-timings.rst         |  11 +-
 .../media/uapi/v4l/vidioc-g-enc-index.rst          |   6 +-
 .../media/uapi/v4l/vidioc-g-ext-ctrls.rst          |  14 +-
 Documentation/media/uapi/v4l/vidioc-g-fbuf.rst     |   4 +
 Documentation/media/uapi/v4l/vidioc-g-fmt.rst      |   2 +
 Documentation/media/uapi/v4l/vidioc-g-jpegcomp.rst |   2 +-
 .../media/uapi/v4l/vidioc-g-modulator.rst          |  10 +-
 .../media/uapi/v4l/vidioc-g-sliced-vbi-cap.rst     |  30 ++++-
 Documentation/media/uapi/v4l/vidioc-g-tuner.rst    |  44 +++++--
 Documentation/media/uapi/v4l/vidioc-queryctrl.rst  |  16 ++-
 39 files changed, 283 insertions(+), 145 deletions(-)
 rename Documentation/{cec.txt => media/kapi/cec-core.rst} (72%)

-- 
2.7.4



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [PATCH 01/15] [media] vidioc-dqevent.rst: adjust two table columns for LaTeX output
  2016-08-19 13:04 [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX Mauro Carvalho Chehab
@ 2016-08-19 13:04 ` Mauro Carvalho Chehab
  2016-08-19 13:04 ` [PATCH 02/15] [media] vidioc-dv-timings-cap.rst: Adjust LaTeX columns Mauro Carvalho Chehab
                   ` (13 subsequent siblings)
  14 siblings, 0 replies; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:04 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab, Markus Heiser

There are two tables with mangled columns. Fix it.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 Documentation/media/uapi/v4l/vidioc-dqevent.rst | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/Documentation/media/uapi/v4l/vidioc-dqevent.rst b/Documentation/media/uapi/v4l/vidioc-dqevent.rst
index 0a84f3a6ed92..6cd5d7068065 100644
--- a/Documentation/media/uapi/v4l/vidioc-dqevent.rst
+++ b/Documentation/media/uapi/v4l/vidioc-dqevent.rst
@@ -42,7 +42,9 @@ call.
 
 .. _v4l2-event:
 
-.. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{7.0cm}|p{3.5cm}|
+.. tabularcolumns:: |p{3.0cm}|p{4.3cm}|p{2.5cm}|p{7.7cm}|
+
+.. cssclass: longtable
 
 .. flat-table:: struct v4l2_event
     :header-rows:  0
@@ -328,7 +330,7 @@ call.
 
 .. _v4l2-event-ctrl:
 
-.. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{7.0cm}|p{3.5cm}|
+.. tabularcolumns:: |p{3.5cm}|p{3.0cm}|p{1.8cm}|p{8.5cm}|
 
 .. flat-table:: struct v4l2_event_ctrl
     :header-rows:  0
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* [PATCH 02/15] [media] vidioc-dv-timings-cap.rst: Adjust LaTeX columns
  2016-08-19 13:04 [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX Mauro Carvalho Chehab
  2016-08-19 13:04 ` [PATCH 01/15] [media] vidioc-dqevent.rst: adjust two table columns for LaTeX output Mauro Carvalho Chehab
@ 2016-08-19 13:04 ` Mauro Carvalho Chehab
  2016-08-19 13:04 ` [PATCH 03/15] [media] vidioc-enumstd.rst: adjust video standards table Mauro Carvalho Chehab
                   ` (12 subsequent siblings)
  14 siblings, 0 replies; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:04 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab, Markus Heiser

Some tables are not properly displayed on LaTeX. Fix them.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 Documentation/media/uapi/v4l/vidioc-dv-timings-cap.rst | 14 ++++++++------
 1 file changed, 8 insertions(+), 6 deletions(-)

diff --git a/Documentation/media/uapi/v4l/vidioc-dv-timings-cap.rst b/Documentation/media/uapi/v4l/vidioc-dv-timings-cap.rst
index e14e780eb0d1..b2bf4f3a3c25 100644
--- a/Documentation/media/uapi/v4l/vidioc-dv-timings-cap.rst
+++ b/Documentation/media/uapi/v4l/vidioc-dv-timings-cap.rst
@@ -56,7 +56,7 @@ that doesn't support them will return an ``EINVAL`` error code.
 
 .. _v4l2-bt-timings-cap:
 
-.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
+.. tabularcolumns:: |p{1.2cm}|p{3.0cm}|p{13.3cm}|
 
 .. flat-table:: struct v4l2_bt_timings_cap
     :header-rows:  0
@@ -136,14 +136,14 @@ that doesn't support them will return an ``EINVAL`` error code.
 
        -  ``reserved``\ [16]
 
-       -  Reserved for future extensions. Drivers must set the array to
-	  zero.
+       -  Reserved for future extensions.
+	  Drivers must set the array to zero.
 
 
 
 .. _v4l2-dv-timings-cap:
 
-.. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{7.0cm}|p{3.5cm}|
+.. tabularcolumns:: |p{1.0cm}|p{3.5cm}|p{3.5cm}|p{9.5cm}|
 
 .. flat-table:: struct v4l2_dv_timings_cap
     :header-rows:  0
@@ -175,8 +175,9 @@ that doesn't support them will return an ``EINVAL`` error code.
 
        -  ``reserved``\ [2]
 
-       -  Reserved for future extensions. Drivers and applications must set
-	  the array to zero.
+       -  Reserved for future extensions.
+
+	  Drivers and applications must set the array to zero.
 
     -  .. row 4
 
@@ -203,6 +204,7 @@ that doesn't support them will return an ``EINVAL`` error code.
 
        -
 
+.. tabularcolumns:: |p{7.0cm}|p{10.5cm}|
 
 
 .. _dv-bt-cap-capabilities:
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* [PATCH 03/15] [media] vidioc-enumstd.rst: adjust video standards table
  2016-08-19 13:04 [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX Mauro Carvalho Chehab
  2016-08-19 13:04 ` [PATCH 01/15] [media] vidioc-dqevent.rst: adjust two table columns for LaTeX output Mauro Carvalho Chehab
  2016-08-19 13:04 ` [PATCH 02/15] [media] vidioc-dv-timings-cap.rst: Adjust LaTeX columns Mauro Carvalho Chehab
@ 2016-08-19 13:04 ` Mauro Carvalho Chehab
  2016-08-19 13:04 ` [PATCH 04/15] [media] vidioc-g-sliced-vbi-cap.rst: make tables fit on LaTeX output Mauro Carvalho Chehab
                   ` (11 subsequent siblings)
  14 siblings, 0 replies; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:04 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab, Markus Heiser

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset=true, Size: 2228 bytes --]

This table is too big for LaTeX output, and lacks columns
specs for LaTeX format.

Also, it has a hidden column, as there are some cell spans
with the wrong values.

Fix it, so it can be displayed properly on LaTeX/PDF.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 Documentation/media/uapi/v4l/vidioc-enumstd.rst | 23 +++++++++++++++++++----
 1 file changed, 19 insertions(+), 4 deletions(-)

diff --git a/Documentation/media/uapi/v4l/vidioc-enumstd.rst b/Documentation/media/uapi/v4l/vidioc-enumstd.rst
index 9d7d77af0161..28f00a027cc7 100644
--- a/Documentation/media/uapi/v4l/vidioc-enumstd.rst
+++ b/Documentation/media/uapi/v4l/vidioc-enumstd.rst
@@ -272,6 +272,12 @@ support digital TV. See also the Linux DVB API at
     #define V4L2_STD_ALL            (V4L2_STD_525_60        |
 		     V4L2_STD_625_50)
 
+.. raw:: latex
+
+    \newline\newline\begin{adjustbox}{width=\columnwidth}
+
+..                            NTSC/M   PAL/M    /N       /B       /D       /H       /I        SECAM/B    /D       /K1     /L
+.. tabularcolumns:: |p{2.7cm}|p{2.6cm}|p{3.0cm}|p{3.2cm}|p{3.2cm}|p{2.2cm}|p{1.2cm}|p{3.2cm}|p{3.0cm}|p{2.0cm}|p{2.0cm}|p{2.0cm}|
 
 .. _video-standards:
 
@@ -312,7 +318,7 @@ support digital TV. See also the Linux DVB API at
 
        -  :cspan:`1` 525
 
-       -  :cspan:`9` 625
+       -  :cspan:`8` 625
 
     -  .. row 3
 
@@ -320,7 +326,7 @@ support digital TV. See also the Linux DVB API at
 
        -  :cspan:`1` 1001/30000
 
-       -  :cspan:`9` 1/25
+       -  :cspan:`8` 1/25
 
     -  .. row 4
 
@@ -330,13 +336,17 @@ support digital TV. See also the Linux DVB API at
 
        -  3579611.49 ± 10
 
-       -  4433618.75 ± 5 (3582056.25 ± 5)
+       -  4433618.75 ± 5
+
+          (3582056.25 ± 5)
 
        -  :cspan:`3` 4433618.75 ± 5
 
        -  4433618.75 ± 1
 
-       -  :cspan:`3` f\ :sub:`OR` = 4406250 ± 2000, f\ :sub:`OB` = 4250000 ± 2000
+       -  :cspan:`2` f\ :sub:`OR` = 4406250 ± 2000,
+
+	  f\ :sub:`OB` = 4250000 ± 2000
 
     -  .. row 5
 
@@ -390,6 +400,11 @@ support digital TV. See also the Linux DVB API at
 
        -  6.5 [#f8]_
 
+.. raw:: latex
+
+    \end{adjustbox}\newline\newline
+
+
 
 Return Value
 ============
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* [PATCH 04/15] [media] vidioc-g-sliced-vbi-cap.rst: make tables fit on LaTeX output
  2016-08-19 13:04 [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX Mauro Carvalho Chehab
                   ` (2 preceding siblings ...)
  2016-08-19 13:04 ` [PATCH 03/15] [media] vidioc-enumstd.rst: adjust video standards table Mauro Carvalho Chehab
@ 2016-08-19 13:04 ` Mauro Carvalho Chehab
  2016-08-19 13:04 ` [PATCH 05/15] [media] adjust some vidioc-*rst tables with wrong columns Mauro Carvalho Chehab
                   ` (10 subsequent siblings)
  14 siblings, 0 replies; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:04 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab, Markus Heiser

The tables don't fit at the page on this file. As noticed
before, Sphinx (or LaTeX?) does a crap job on tables with
cell span, and some work has to be done to make it fit.

Move the see also reference to a footnote, break one paragraph
into two and adjust the table columns to make it visible.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 .../media/uapi/v4l/vidioc-g-sliced-vbi-cap.rst     | 30 +++++++++++++++++-----
 1 file changed, 23 insertions(+), 7 deletions(-)

diff --git a/Documentation/media/uapi/v4l/vidioc-g-sliced-vbi-cap.rst b/Documentation/media/uapi/v4l/vidioc-g-sliced-vbi-cap.rst
index 0d4b6b0044a0..740324e6e5db 100644
--- a/Documentation/media/uapi/v4l/vidioc-g-sliced-vbi-cap.rst
+++ b/Documentation/media/uapi/v4l/vidioc-g-sliced-vbi-cap.rst
@@ -48,7 +48,7 @@ the sliced VBI API is unsupported or ``type`` is invalid.
 
 .. _v4l2-sliced-vbi-cap:
 
-.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{2.9cm}|p{2.9cm}|p{2.9cm}|
+.. tabularcolumns:: |p{1.2cm}|p{4.2cm}|p{4.1cm}|p{4.0cm}|p{4.0cm}|
 
 .. flat-table:: struct v4l2_sliced_vbi_cap
     :header-rows:  0
@@ -63,6 +63,7 @@ the sliced VBI API is unsupported or ``type`` is invalid.
        -  ``service_set``
 
        -  :cspan:`2` A set of all data services supported by the driver.
+
 	  Equal to the union of all elements of the ``service_lines`` array.
 
     -  .. row 2
@@ -74,8 +75,7 @@ the sliced VBI API is unsupported or ``type`` is invalid.
        -  :cspan:`2` Each element of this array contains a set of data
 	  services the hardware can look for or insert into a particular
 	  scan line. Data services are defined in :ref:`vbi-services`.
-	  Array indices map to ITU-R line numbers (see also :ref:`vbi-525`
-	  and :ref:`vbi-625`) as follows:
+	  Array indices map to ITU-R line numbers\ [#f1]_ as follows:
 
     -  .. row 3
 
@@ -171,14 +171,22 @@ the sliced VBI API is unsupported or ``type`` is invalid.
        -  ``reserved``\ [3]
 
        -  :cspan:`2` This array is reserved for future extensions.
+
 	  Applications and drivers must set it to zero.
 
+.. [#f1]
 
+   See also :ref:`vbi-525` and :ref:`vbi-625`.
+
+
+.. raw:: latex
+
+    \newline\newline\begin{adjustbox}{width=\columnwidth}
+
+.. tabularcolumns:: |p{5.0cm}|p{1.4cm}|p{3.0cm}|p{2.5cm}|p{9.0cm}|
 
 .. _vbi-services:
 
-.. tabularcolumns:: |p{4.4cm}|p{2.2cm}|p{2.2cm}|p{4.4cm}|p{4.3cm}|
-
 .. flat-table:: Sliced VBI services
     :header-rows:  1
     :stub-columns: 0
@@ -203,7 +211,9 @@ the sliced VBI API is unsupported or ``type`` is invalid.
 
        -  0x0001
 
-       -  :ref:`ets300706`, :ref:`itu653`
+       -  :ref:`ets300706`,
+
+	  :ref:`itu653`
 
        -  PAL/SECAM line 7-22, 320-335 (second field 7-22)
 
@@ -242,7 +252,9 @@ the sliced VBI API is unsupported or ``type`` is invalid.
 
        -  0x4000
 
-       -  :ref:`en300294`, :ref:`itu1119`
+       -  :ref:`en300294`,
+
+	  :ref:`itu1119`
 
        -  PAL/SECAM line 23
 
@@ -270,6 +282,10 @@ the sliced VBI API is unsupported or ``type`` is invalid.
 
        -  :cspan:`2` Set of services applicable to 625 line systems.
 
+.. raw:: latex
+
+    \end{adjustbox}\newline\newline
+
 
 Return Value
 ============
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* [PATCH 05/15] [media] adjust some vidioc-*rst tables with wrong columns
  2016-08-19 13:04 [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX Mauro Carvalho Chehab
                   ` (3 preceding siblings ...)
  2016-08-19 13:04 ` [PATCH 04/15] [media] vidioc-g-sliced-vbi-cap.rst: make tables fit on LaTeX output Mauro Carvalho Chehab
@ 2016-08-19 13:04 ` Mauro Carvalho Chehab
  2016-08-19 13:04 ` [PATCH 06/15] [media] vidioc-g-tuner.rst: improve documentation for tuner type Mauro Carvalho Chehab
                   ` (9 subsequent siblings)
  14 siblings, 0 replies; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:04 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab, Markus Heiser,
	Hans Verkuil

Adjust simple cases where the columns on some vidioc files
are overriding their neighbours.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 Documentation/media/uapi/v4l/vidioc-dqevent.rst         |  2 ++
 Documentation/media/uapi/v4l/vidioc-enum-fmt.rst        |  4 +++-
 Documentation/media/uapi/v4l/vidioc-enum-freq-bands.rst |  5 +++--
 Documentation/media/uapi/v4l/vidioc-enuminput.rst       |  2 ++
 Documentation/media/uapi/v4l/vidioc-enumoutput.rst      |  2 +-
 Documentation/media/uapi/v4l/vidioc-g-dv-timings.rst    | 11 +----------
 Documentation/media/uapi/v4l/vidioc-g-enc-index.rst     |  6 +++---
 Documentation/media/uapi/v4l/vidioc-g-ext-ctrls.rst     | 14 ++++++++++----
 Documentation/media/uapi/v4l/vidioc-g-fbuf.rst          |  4 ++++
 Documentation/media/uapi/v4l/vidioc-g-fmt.rst           |  2 ++
 Documentation/media/uapi/v4l/vidioc-g-jpegcomp.rst      |  2 +-
 Documentation/media/uapi/v4l/vidioc-g-modulator.rst     | 10 ++++++----
 Documentation/media/uapi/v4l/vidioc-queryctrl.rst       | 16 ++++++++++++----
 13 files changed, 50 insertions(+), 30 deletions(-)

diff --git a/Documentation/media/uapi/v4l/vidioc-dqevent.rst b/Documentation/media/uapi/v4l/vidioc-dqevent.rst
index 6cd5d7068065..ad4b826a2966 100644
--- a/Documentation/media/uapi/v4l/vidioc-dqevent.rst
+++ b/Documentation/media/uapi/v4l/vidioc-dqevent.rst
@@ -183,6 +183,8 @@ call.
 
 .. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
 
+.. cssclass:: longtable
+
 .. flat-table:: Event Types
     :header-rows:  0
     :stub-columns: 0
diff --git a/Documentation/media/uapi/v4l/vidioc-enum-fmt.rst b/Documentation/media/uapi/v4l/vidioc-enum-fmt.rst
index 6bb30ade6aad..2d1444b0d017 100644
--- a/Documentation/media/uapi/v4l/vidioc-enum-fmt.rst
+++ b/Documentation/media/uapi/v4l/vidioc-enum-fmt.rst
@@ -108,7 +108,9 @@ one until ``EINVAL`` is returned.
        -  :cspan:`2`
 
 	  .. _v4l2-fourcc:
-	  ``#define v4l2_fourcc(a,b,c,d) (((__u32)(a)<<0)|((__u32)(b)<<8)|((__u32)(c)<<16)|((__u32)(d)<<24))``
+	  ``#define v4l2_fourcc(a,b,c,d)``
+
+	  ``(((__u32)(a)<<0)|((__u32)(b)<<8)|((__u32)(c)<<16)|((__u32)(d)<<24))``
 
 	  Several image formats are already defined by this specification in
 	  :ref:`pixfmt`.
diff --git a/Documentation/media/uapi/v4l/vidioc-enum-freq-bands.rst b/Documentation/media/uapi/v4l/vidioc-enum-freq-bands.rst
index ea1ccfb43e6d..c6ae6f14c9f6 100644
--- a/Documentation/media/uapi/v4l/vidioc-enum-freq-bands.rst
+++ b/Documentation/media/uapi/v4l/vidioc-enum-freq-bands.rst
@@ -146,8 +146,9 @@ of the corresponding tuner/modulator is set.
 
        -  ``reserved``\ [9]
 
-       -  Reserved for future extensions. Applications and drivers must set
-	  the array to zero.
+       -  Reserved for future extensions.
+
+	  Applications and drivers must set the array to zero.
 
 
 
diff --git a/Documentation/media/uapi/v4l/vidioc-enuminput.rst b/Documentation/media/uapi/v4l/vidioc-enuminput.rst
index 6b90a1a3506d..8f0b821bd921 100644
--- a/Documentation/media/uapi/v4l/vidioc-enuminput.rst
+++ b/Documentation/media/uapi/v4l/vidioc-enuminput.rst
@@ -181,6 +181,8 @@ at index zero, incrementing by one until the driver returns ``EINVAL``.
 
 .. _input-status:
 
+.. tabularcolumns:: |p{4.8cm}|p{2.6cm}|p{10.1cm}|
+
 .. flat-table:: Input Status Flags
     :header-rows:  0
     :stub-columns: 0
diff --git a/Documentation/media/uapi/v4l/vidioc-enumoutput.rst b/Documentation/media/uapi/v4l/vidioc-enumoutput.rst
index 13939d8d4358..456013fb50a2 100644
--- a/Documentation/media/uapi/v4l/vidioc-enumoutput.rst
+++ b/Documentation/media/uapi/v4l/vidioc-enumoutput.rst
@@ -142,7 +142,7 @@ EINVAL.
 
 .. _output-type:
 
-.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
+.. tabularcolumns:: |p{7.0cm}|p{1.8cm}|p{8.7cm}|
 
 .. flat-table:: Output Type
     :header-rows:  0
diff --git a/Documentation/media/uapi/v4l/vidioc-g-dv-timings.rst b/Documentation/media/uapi/v4l/vidioc-g-dv-timings.rst
index d2ea3bf01fce..58dec578f54d 100644
--- a/Documentation/media/uapi/v4l/vidioc-g-dv-timings.rst
+++ b/Documentation/media/uapi/v4l/vidioc-g-dv-timings.rst
@@ -316,11 +316,6 @@ EBUSY
 
        -  Description
 
-    -  .. row 2
-
-       -
-       -
-
     -  .. row 3
 
        -  ``V4L2_DV_BT_STD_CEA861``
@@ -346,6 +341,7 @@ EBUSY
        -  The timings follow the VESA Generalized Timings Formula standard
 
 
+.. tabularcolumns:: |p{6.0cm}|p{11.5cm}|
 
 .. _dv-bt-flags:
 
@@ -360,11 +356,6 @@ EBUSY
 
        -  Description
 
-    -  .. row 2
-
-       -
-       -
-
     -  .. row 3
 
        -  ``V4L2_DV_FL_REDUCED_BLANKING``
diff --git a/Documentation/media/uapi/v4l/vidioc-g-enc-index.rst b/Documentation/media/uapi/v4l/vidioc-g-enc-index.rst
index cb094b589f0e..9cb98a8eaf2d 100644
--- a/Documentation/media/uapi/v4l/vidioc-g-enc-index.rst
+++ b/Documentation/media/uapi/v4l/vidioc-g-enc-index.rst
@@ -59,12 +59,12 @@ video elementary streams.
 
 .. _v4l2-enc-idx:
 
-.. tabularcolumns:: |p{2.9cm}|p{2.9cm}|p{5.8cm}|p{2.9cm}|p{3.0cm}|
+.. tabularcolumns:: |p{3.5cm}|p{5.6cm}|p{8.4cm}|
 
 .. flat-table:: struct v4l2_enc_idx
     :header-rows:  0
     :stub-columns: 0
-    :widths:       1 1 2 1 1
+    :widths:       1 3 8
 
 
     -  .. row 1
@@ -90,7 +90,7 @@ video elementary streams.
 
        -  ``reserved``\ [4]
 
-       -  :cspan:`2` Reserved for future extensions. Drivers must set the
+       -  Reserved for future extensions. Drivers must set the
 	  array to zero.
 
     -  .. row 4
diff --git a/Documentation/media/uapi/v4l/vidioc-g-ext-ctrls.rst b/Documentation/media/uapi/v4l/vidioc-g-ext-ctrls.rst
index fee65debfee2..33445c6b6bc2 100644
--- a/Documentation/media/uapi/v4l/vidioc-g-ext-ctrls.rst
+++ b/Documentation/media/uapi/v4l/vidioc-g-ext-ctrls.rst
@@ -97,7 +97,9 @@ still cause this situation.
 
 .. _v4l2-ext-control:
 
-.. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{3.5cm}|p{7.0cm}|
+.. tabularcolumns:: |p{1.2cm}|p{3.0cm}|p{1.5cm}|p{11.8cm}|
+
+.. cssclass: longtable
 
 .. flat-table:: struct v4l2_ext_control
     :header-rows:  0
@@ -230,7 +232,9 @@ still cause this situation.
 
 .. _v4l2-ext-controls:
 
-.. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{7.0cm}|p{3.5cm}|
+.. tabularcolumns:: |p{4.0cm}|p{3.0cm}|p{2.0cm}|p{8.5cm}|
+
+.. cssclass:: longtable
 
 .. flat-table:: struct v4l2_ext_controls
     :header-rows:  0
@@ -348,8 +352,9 @@ still cause this situation.
 
        -  ``reserved``\ [2]
 
-       -  Reserved for future extensions. Drivers and applications must set
-	  the array to zero.
+       -  Reserved for future extensions.
+
+	  Drivers and applications must set the array to zero.
 
     -  .. row 7
 
@@ -358,6 +363,7 @@ still cause this situation.
        -  ``controls``
 
        -  Pointer to an array of ``count`` v4l2_ext_control structures.
+
 	  Ignored if ``count`` equals zero.
 
 
diff --git a/Documentation/media/uapi/v4l/vidioc-g-fbuf.rst b/Documentation/media/uapi/v4l/vidioc-g-fbuf.rst
index dc762325be5e..a6cbc532ff05 100644
--- a/Documentation/media/uapi/v4l/vidioc-g-fbuf.rst
+++ b/Documentation/media/uapi/v4l/vidioc-g-fbuf.rst
@@ -80,6 +80,8 @@ destructive video overlay.
 
 .. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{3.5cm}|p{7.0cm}|
 
+.. cssclass:: longtable
+
 .. flat-table:: struct v4l2_framebuffer
     :header-rows:  0
     :stub-columns: 0
@@ -377,6 +379,8 @@ destructive video overlay.
 
 .. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
 
+.. cssclass:: longtable
+
 .. flat-table:: Frame Buffer Flags
     :header-rows:  0
     :stub-columns: 0
diff --git a/Documentation/media/uapi/v4l/vidioc-g-fmt.rst b/Documentation/media/uapi/v4l/vidioc-g-fmt.rst
index ee6f11978fd6..94e42ac3d4d8 100644
--- a/Documentation/media/uapi/v4l/vidioc-g-fmt.rst
+++ b/Documentation/media/uapi/v4l/vidioc-g-fmt.rst
@@ -84,6 +84,8 @@ The format as returned by :ref:`VIDIOC_TRY_FMT <VIDIOC_G_FMT>` must be identical
 
 .. _v4l2-format:
 
+.. tabularcolumns::  |p{1.2cm}|p{4.3cm}|p{3.0cm}|p{9.0cm}|
+
 .. flat-table:: struct v4l2_format
     :header-rows:  0
     :stub-columns: 0
diff --git a/Documentation/media/uapi/v4l/vidioc-g-jpegcomp.rst b/Documentation/media/uapi/v4l/vidioc-g-jpegcomp.rst
index 6f9ee18e005f..9b87c7f4df52 100644
--- a/Documentation/media/uapi/v4l/vidioc-g-jpegcomp.rst
+++ b/Documentation/media/uapi/v4l/vidioc-g-jpegcomp.rst
@@ -57,7 +57,7 @@ encoding. You usually do want to add them.
 
 .. _v4l2-jpegcompression:
 
-.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
+.. tabularcolumns:: |p{1.2cm}|p{3.0cm}|p{13.3cm}|
 
 .. flat-table:: struct v4l2_jpegcompression
     :header-rows:  0
diff --git a/Documentation/media/uapi/v4l/vidioc-g-modulator.rst b/Documentation/media/uapi/v4l/vidioc-g-modulator.rst
index eaa62b6bd931..52c7b95de8e6 100644
--- a/Documentation/media/uapi/v4l/vidioc-g-modulator.rst
+++ b/Documentation/media/uapi/v4l/vidioc-g-modulator.rst
@@ -85,8 +85,9 @@ To change the radio frequency the
 
        -  ``name``\ [32]
 
-       -  Name of the modulator, a NUL-terminated ASCII string. This
-	  information is intended for the user.
+       -  Name of the modulator, a NUL-terminated ASCII string.
+
+	  This information is intended for the user.
 
     -  .. row 3
 
@@ -155,8 +156,9 @@ To change the radio frequency the
 
        -  ``reserved``\ [3]
 
-       -  Reserved for future extensions. Drivers and applications must set
-	  the array to zero.
+       -  Reserved for future extensions.
+
+	  Drivers and applications must set the array to zero.
 
 
 
diff --git a/Documentation/media/uapi/v4l/vidioc-queryctrl.rst b/Documentation/media/uapi/v4l/vidioc-queryctrl.rst
index b2dba5e0822b..437f0f7e3001 100644
--- a/Documentation/media/uapi/v4l/vidioc-queryctrl.rst
+++ b/Documentation/media/uapi/v4l/vidioc-queryctrl.rst
@@ -96,7 +96,9 @@ See also the examples in :ref:`control`.
 
 .. _v4l2-queryctrl:
 
-.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
+.. tabularcolumns:: |p{1.2cm}|p{3.6cm}|p{12.7cm}|
+
+.. cssclass:: longtable
 
 .. flat-table:: struct v4l2_queryctrl
     :header-rows:  0
@@ -218,7 +220,9 @@ See also the examples in :ref:`control`.
 
 .. _v4l2-query-ext-ctrl:
 
-.. tabularcolumns:: |p{4.4cm}|p{4.4cm}|p{8.7cm}|
+.. tabularcolumns:: |p{1.2cm}|p{5.0cm}|p{11.3cm}|
+
+.. cssclass:: longtable
 
 .. flat-table:: struct v4l2_query_ext_ctrl
     :header-rows:  0
@@ -382,7 +386,7 @@ See also the examples in :ref:`control`.
 
 .. _v4l2-querymenu:
 
-.. tabularcolumns:: |p{3.5cm}|p{3.5cm}|p{7.0cm}|p{3.5cm}|
+.. tabularcolumns:: |p{1.2cm}|p{0.6cm}|p{1.6cm}|p{13.5cm}|
 
 .. flat-table:: struct v4l2_querymenu
     :header-rows:  0
@@ -452,7 +456,9 @@ See also the examples in :ref:`control`.
 
 .. _v4l2-ctrl-type:
 
-.. tabularcolumns:: |p{5.3cm}|p{0.9cm}|p{0.9cm}|p{0.9cm}|p{9.5cm}|
+.. tabularcolumns:: |p{5.8cm}|p{1.4cm}|p{1.0cm}|p{1.4cm}|p{6.9cm}|
+
+.. cssclass:: longtable
 
 .. flat-table:: enum v4l2_ctrl_type
     :header-rows:  1
@@ -653,6 +659,8 @@ See also the examples in :ref:`control`.
 
 .. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
 
+.. cssclass:: longtable
+
 .. flat-table:: Control Flags
     :header-rows:  0
     :stub-columns: 0
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* [PATCH 06/15] [media] vidioc-g-tuner.rst: improve documentation for tuner type
  2016-08-19 13:04 [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX Mauro Carvalho Chehab
                   ` (4 preceding siblings ...)
  2016-08-19 13:04 ` [PATCH 05/15] [media] adjust some vidioc-*rst tables with wrong columns Mauro Carvalho Chehab
@ 2016-08-19 13:04 ` Mauro Carvalho Chehab
  2016-08-19 13:04 ` [PATCH 07/15] [media] vidioc-g-tuner.rst: Fix tables to fit at LaTeX output Mauro Carvalho Chehab
                   ` (8 subsequent siblings)
  14 siblings, 0 replies; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:04 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab, Markus Heiser

The tuner type table misses descriptions for each type. While
most of stuff are obvious, the two SDR definitions aren't.

So, add descriptions to all of them.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 Documentation/media/uapi/v4l/vidioc-g-tuner.rst | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/Documentation/media/uapi/v4l/vidioc-g-tuner.rst b/Documentation/media/uapi/v4l/vidioc-g-tuner.rst
index 762918a1e58a..740a4dd0db00 100644
--- a/Documentation/media/uapi/v4l/vidioc-g-tuner.rst
+++ b/Documentation/media/uapi/v4l/vidioc-g-tuner.rst
@@ -260,7 +260,7 @@ To change the radio frequency the
 .. flat-table:: enum v4l2_tuner_type
     :header-rows:  0
     :stub-columns: 0
-    :widths:       3 1 4
+    :widths:       3 1 6
 
 
     -  .. row 1
@@ -269,7 +269,7 @@ To change the radio frequency the
 
        -  1
 
-       -
+       - Tuner supports radio
 
     -  .. row 2
 
@@ -277,7 +277,7 @@ To change the radio frequency the
 
        -  2
 
-       -
+       - Tuner supports analog TV
 
     -  .. row 3
 
@@ -285,7 +285,8 @@ To change the radio frequency the
 
        -  4
 
-       -
+       - Tuner controls the A/D and/or D/A block of a
+	 Sofware Digital Radio (SDR)
 
     -  .. row 4
 
@@ -293,8 +294,7 @@ To change the radio frequency the
 
        -  5
 
-       -
-
+       - Tuner controls the RF part of a Sofware Digital Radio (SDR)
 
 
 .. _tuner-capability:
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* [PATCH 07/15] [media] vidioc-g-tuner.rst: Fix tables to fit at LaTeX output
  2016-08-19 13:04 [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX Mauro Carvalho Chehab
                   ` (5 preceding siblings ...)
  2016-08-19 13:04 ` [PATCH 06/15] [media] vidioc-g-tuner.rst: improve documentation for tuner type Mauro Carvalho Chehab
@ 2016-08-19 13:04 ` Mauro Carvalho Chehab
  2016-08-19 13:04 ` [PATCH 08/15] [media] fix v4l2-selection-*.rst tables for " Mauro Carvalho Chehab
                   ` (7 subsequent siblings)
  14 siblings, 0 replies; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:04 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab, Markus Heiser

Several tables are missing column definitions and/or are too big
to fit into the page. Adjust them.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 Documentation/media/uapi/v4l/vidioc-g-tuner.rst | 32 ++++++++++++++++++-------
 1 file changed, 24 insertions(+), 8 deletions(-)

diff --git a/Documentation/media/uapi/v4l/vidioc-g-tuner.rst b/Documentation/media/uapi/v4l/vidioc-g-tuner.rst
index 740a4dd0db00..a52efdf94795 100644
--- a/Documentation/media/uapi/v4l/vidioc-g-tuner.rst
+++ b/Documentation/media/uapi/v4l/vidioc-g-tuner.rst
@@ -60,8 +60,12 @@ To change the radio frequency the
 :ref:`VIDIOC_S_FREQUENCY <VIDIOC_G_FREQUENCY>` ioctl is available.
 
 
+ .. tabularcolumns:: |p{1.3cm}|p{3.0cm}|p{6.6cm}|p{6.6cm}|
+
 .. _v4l2-tuner:
 
+.. cssclass:: longtable
+
 .. flat-table:: struct v4l2_tuner
     :header-rows:  0
     :stub-columns: 0
@@ -83,8 +87,9 @@ To change the radio frequency the
 
        -  :cspan:`1`
 
-	  Name of the tuner, a NUL-terminated ASCII string. This information
-	  is intended for the user.
+	  Name of the tuner, a NUL-terminated ASCII string.
+
+	  This information is intended for the user.
 
     -  .. row 3
 
@@ -230,8 +235,9 @@ To change the radio frequency the
 
        -  ``signal``
 
-       -  :cspan:`1` The signal strength if known, ranging from 0 to
-	  65535. Higher values indicate a better signal.
+       -  :cspan:`1` The signal strength if known.
+
+	  Ranging from 0 to 65535. Higher values indicate a better signal.
 
     -  .. row 16
 
@@ -239,8 +245,10 @@ To change the radio frequency the
 
        -  ``afc``
 
-       -  :cspan:`1` Automatic frequency control: When the ``afc`` value
-	  is negative, the frequency is too low, when positive too high.
+       -  :cspan:`1` Automatic frequency control.
+
+	  When the ``afc`` value is negative, the frequency is too
+	  low, when positive too high.
 
     -  .. row 17
 
@@ -248,8 +256,9 @@ To change the radio frequency the
 
        -  ``reserved``\ [4]
 
-       -  :cspan:`1` Reserved for future extensions. Drivers and
-	  applications must set the array to zero.
+       -  :cspan:`1` Reserved for future extensions.
+
+	   Drivers and applications must set the array to zero.
 
 
 
@@ -301,6 +310,8 @@ To change the radio frequency the
 
 .. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
 
+.. cssclass:: longtable
+
 .. flat-table:: Tuner and Modulator Capability Flags
     :header-rows:  0
     :stub-columns: 0
@@ -608,7 +619,9 @@ To change the radio frequency the
 	  ``MODE_MONO``. Only ``V4L2_TUNER_ANALOG_TV`` tuners support this
 	  mode.
 
+.. raw:: latex
 
+    \newline\newline\begin{adjustbox}{width=\columnwidth}
 
 .. _tuner-matrix:
 
@@ -706,6 +719,9 @@ To change the radio frequency the
 
        -  Lang1/Lang2 (preferred) or Lang1/Lang1
 
+.. raw:: latex
+
+    \end{adjustbox}\newline\newline
 
 Return Value
 ============
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* [PATCH 08/15] [media] fix v4l2-selection-*.rst tables for LaTeX output
  2016-08-19 13:04 [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX Mauro Carvalho Chehab
                   ` (6 preceding siblings ...)
  2016-08-19 13:04 ` [PATCH 07/15] [media] vidioc-g-tuner.rst: Fix tables to fit at LaTeX output Mauro Carvalho Chehab
@ 2016-08-19 13:04 ` Mauro Carvalho Chehab
  2016-08-19 13:04 ` [PATCH 09/15] [media] fe_property_parameters.rst: Adjust column sizes Mauro Carvalho Chehab
                   ` (6 subsequent siblings)
  14 siblings, 0 replies; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:04 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab, Markus Heiser

Adjust the tables there to fit inside the page margins.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 Documentation/media/uapi/v4l/v4l2-selection-flags.rst   | 1 +
 Documentation/media/uapi/v4l/v4l2-selection-targets.rst | 2 ++
 2 files changed, 3 insertions(+)

diff --git a/Documentation/media/uapi/v4l/v4l2-selection-flags.rst b/Documentation/media/uapi/v4l/v4l2-selection-flags.rst
index 3ce3731faf5f..9ef139f8e21d 100644
--- a/Documentation/media/uapi/v4l/v4l2-selection-flags.rst
+++ b/Documentation/media/uapi/v4l/v4l2-selection-flags.rst
@@ -6,6 +6,7 @@
 Selection flags
 ***************
 
+.. tabularcolumns:: |p{5.2cm}|p{2.0cm}|p{6.5cm}|p{1.2cm}|p{1.6cm}|
 
 .. _v4l2-selection-flags-table:
 
diff --git a/Documentation/media/uapi/v4l/v4l2-selection-targets.rst b/Documentation/media/uapi/v4l/v4l2-selection-targets.rst
index 7519099a50cd..a82b58f5ebcf 100644
--- a/Documentation/media/uapi/v4l/v4l2-selection-targets.rst
+++ b/Documentation/media/uapi/v4l/v4l2-selection-targets.rst
@@ -12,6 +12,8 @@ of the two interfaces they are used.
 
 .. _v4l2-selection-targets-table:
 
+.. tabularcolumns:: |p{5.8cm}|p{1.4cm}|p{6.5cm}|p{1.2cm}|p{1.6cm}|
+
 .. flat-table:: Selection target definitions
     :header-rows:  1
     :stub-columns: 0
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* [PATCH 09/15] [media] fe_property_parameters.rst: Adjust column sizes
  2016-08-19 13:04 [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX Mauro Carvalho Chehab
                   ` (7 preceding siblings ...)
  2016-08-19 13:04 ` [PATCH 08/15] [media] fix v4l2-selection-*.rst tables for " Mauro Carvalho Chehab
@ 2016-08-19 13:04 ` Mauro Carvalho Chehab
  2016-08-19 13:05 ` [PATCH 10/15] [media] adjust remaining tables at DVB uAPI documentation Mauro Carvalho Chehab
                   ` (5 subsequent siblings)
  14 siblings, 0 replies; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:04 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab, Markus Heiser

Add position hints for some tables, in order for them to be
shown properly on LaTeX output.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 Documentation/media/uapi/dvb/fe_property_parameters.rst | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/Documentation/media/uapi/dvb/fe_property_parameters.rst b/Documentation/media/uapi/dvb/fe_property_parameters.rst
index f776d62523da..d7acc72ebbdf 100644
--- a/Documentation/media/uapi/dvb/fe_property_parameters.rst
+++ b/Documentation/media/uapi/dvb/fe_property_parameters.rst
@@ -1234,6 +1234,7 @@ Reed Solomon (RS) frame mode.
 
 Possible values are:
 
+.. tabularcolumns:: |p{5.0cm}|p{12.5cm}|
 
 .. _atscmh-rs-frame-mode:
 
@@ -1395,6 +1396,7 @@ Series Concatenated Convolutional Code Block Mode.
 
 Possible values are:
 
+.. tabularcolumns:: |p{4.5cm}|p{13.0cm}|
 
 .. _atscmh-sccc-block-mode:
 
@@ -1687,6 +1689,7 @@ on OFTM-based standards, e. g. DVB-T/T2, ISDB-T, DTMB
 enum fe_transmit_mode: Number of carriers per channel
 -----------------------------------------------------
 
+.. tabularcolumns:: |p{5.0cm}|p{12.5cm}|
 
 .. _fe-transmit-mode:
 
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* [PATCH 10/15] [media] adjust remaining tables at DVB uAPI documentation
  2016-08-19 13:04 [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX Mauro Carvalho Chehab
                   ` (8 preceding siblings ...)
  2016-08-19 13:04 ` [PATCH 09/15] [media] fe_property_parameters.rst: Adjust column sizes Mauro Carvalho Chehab
@ 2016-08-19 13:05 ` Mauro Carvalho Chehab
  2016-08-19 13:05 ` [PATCH 11/15] [media] media-types.rst: adjust tables to fit on LaTeX output Mauro Carvalho Chehab
                   ` (4 subsequent siblings)
  14 siblings, 0 replies; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:05 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab, Markus Heiser

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset=true, Size: 5650 bytes --]

There are a few broken tables on LaTeX output at the DVB
uAPI documentation. Fix them.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 Documentation/media/uapi/dvb/audio-fopen.rst        | 2 ++
 Documentation/media/uapi/dvb/ca-fopen.rst           | 2 ++
 Documentation/media/uapi/dvb/dmx-fread.rst          | 3 ++-
 Documentation/media/uapi/dvb/dmx-fwrite.rst         | 2 ++
 Documentation/media/uapi/dvb/dmx-set-pes-filter.rst | 2 +-
 Documentation/media/uapi/dvb/dmx-start.rst          | 2 +-
 Documentation/media/uapi/dvb/dmx_types.rst          | 1 +
 Documentation/media/uapi/dvb/fe-get-info.rst        | 1 +
 Documentation/media/uapi/dvb/fe-read-status.rst     | 1 +
 Documentation/media/uapi/dvb/video-fopen.rst        | 2 ++
 10 files changed, 15 insertions(+), 3 deletions(-)

diff --git a/Documentation/media/uapi/dvb/audio-fopen.rst b/Documentation/media/uapi/dvb/audio-fopen.rst
index ec3b23aa79b3..3ef4fd62ffb6 100644
--- a/Documentation/media/uapi/dvb/audio-fopen.rst
+++ b/Documentation/media/uapi/dvb/audio-fopen.rst
@@ -80,6 +80,8 @@ AUDIO_GET_STATUS. All other call will return with an error code.
 Return Value
 ------------
 
+.. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
+
 .. flat-table::
     :header-rows:  0
     :stub-columns: 0
diff --git a/Documentation/media/uapi/dvb/ca-fopen.rst b/Documentation/media/uapi/dvb/ca-fopen.rst
index f284461cce20..9960fc76189c 100644
--- a/Documentation/media/uapi/dvb/ca-fopen.rst
+++ b/Documentation/media/uapi/dvb/ca-fopen.rst
@@ -79,6 +79,8 @@ the device in this mode will fail, and an error code will be returned.
 Return Value
 ------------
 
+.. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
+
 .. flat-table::
     :header-rows:  0
     :stub-columns: 0
diff --git a/Documentation/media/uapi/dvb/dmx-fread.rst b/Documentation/media/uapi/dvb/dmx-fread.rst
index d25b19e4f696..266c9ca259c9 100644
--- a/Documentation/media/uapi/dvb/dmx-fread.rst
+++ b/Documentation/media/uapi/dvb/dmx-fread.rst
@@ -53,10 +53,11 @@ data. The filtered data is transferred from the driver’s internal
 circular buffer to buf. The maximum amount of data to be transferred is
 implied by count.
 
-
 Return Value
 ------------
 
+.. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
+
 .. flat-table::
     :header-rows:  0
     :stub-columns: 0
diff --git a/Documentation/media/uapi/dvb/dmx-fwrite.rst b/Documentation/media/uapi/dvb/dmx-fwrite.rst
index 9efd81a1b5c8..3d76470bef60 100644
--- a/Documentation/media/uapi/dvb/dmx-fwrite.rst
+++ b/Documentation/media/uapi/dvb/dmx-fwrite.rst
@@ -59,6 +59,8 @@ The amount of data to be transferred is implied by count.
 Return Value
 ------------
 
+.. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
+
 .. flat-table::
     :header-rows:  0
     :stub-columns: 0
diff --git a/Documentation/media/uapi/dvb/dmx-set-pes-filter.rst b/Documentation/media/uapi/dvb/dmx-set-pes-filter.rst
index addc321011ce..d71db779b6fd 100644
--- a/Documentation/media/uapi/dvb/dmx-set-pes-filter.rst
+++ b/Documentation/media/uapi/dvb/dmx-set-pes-filter.rst
@@ -61,7 +61,7 @@ On success 0 is returned, on error -1 and the ``errno`` variable is set
 appropriately. The generic error codes are described at the
 :ref:`Generic Error Codes <gen-errors>` chapter.
 
-
+.. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
 
 .. flat-table::
     :header-rows:  0
diff --git a/Documentation/media/uapi/dvb/dmx-start.rst b/Documentation/media/uapi/dvb/dmx-start.rst
index 9835d1e78400..959b5eee2647 100644
--- a/Documentation/media/uapi/dvb/dmx-start.rst
+++ b/Documentation/media/uapi/dvb/dmx-start.rst
@@ -53,7 +53,7 @@ On success 0 is returned, on error -1 and the ``errno`` variable is set
 appropriately. The generic error codes are described at the
 :ref:`Generic Error Codes <gen-errors>` chapter.
 
-
+.. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
 
 .. flat-table::
     :header-rows:  0
diff --git a/Documentation/media/uapi/dvb/dmx_types.rst b/Documentation/media/uapi/dvb/dmx_types.rst
index 7a8900af2680..efd564035958 100644
--- a/Documentation/media/uapi/dvb/dmx_types.rst
+++ b/Documentation/media/uapi/dvb/dmx_types.rst
@@ -12,6 +12,7 @@ Demux Data Types
 Output for the demux
 ====================
 
+.. tabularcolumns:: |p{5.0cm}|p{12.5cm}|
 
 .. _dmx-output:
 
diff --git a/Documentation/media/uapi/dvb/fe-get-info.rst b/Documentation/media/uapi/dvb/fe-get-info.rst
index 80644072087f..85973be62b0c 100644
--- a/Documentation/media/uapi/dvb/fe-get-info.rst
+++ b/Documentation/media/uapi/dvb/fe-get-info.rst
@@ -160,6 +160,7 @@ frontend capabilities
 Capabilities describe what a frontend can do. Some capabilities are
 supported only on some specific frontend types.
 
+.. tabularcolumns:: |p{5.5cm}|p{12.0cm}|
 
 .. _fe-caps:
 
diff --git a/Documentation/media/uapi/dvb/fe-read-status.rst b/Documentation/media/uapi/dvb/fe-read-status.rst
index defe30d036ec..def8160d6807 100644
--- a/Documentation/media/uapi/dvb/fe-read-status.rst
+++ b/Documentation/media/uapi/dvb/fe-read-status.rst
@@ -56,6 +56,7 @@ The fe_status parameter is used to indicate the current state and/or
 state changes of the frontend hardware. It is produced using the enum
 :ref:`fe_status <fe-status>` values on a bitmask
 
+.. tabularcolumns:: |p{3.5cm}|p{14.0cm}|
 
 .. _fe-status:
 
diff --git a/Documentation/media/uapi/dvb/video-fopen.rst b/Documentation/media/uapi/dvb/video-fopen.rst
index 9e5471557b83..9addca95516e 100644
--- a/Documentation/media/uapi/dvb/video-fopen.rst
+++ b/Documentation/media/uapi/dvb/video-fopen.rst
@@ -82,6 +82,8 @@ return an error code.
 Return Value
 ------------
 
+.. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
+
 .. flat-table::
     :header-rows:  0
     :stub-columns: 0
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* [PATCH 11/15] [media] media-types.rst: adjust tables to fit on LaTeX output
  2016-08-19 13:04 [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX Mauro Carvalho Chehab
                   ` (9 preceding siblings ...)
  2016-08-19 13:05 ` [PATCH 10/15] [media] adjust remaining tables at DVB uAPI documentation Mauro Carvalho Chehab
@ 2016-08-19 13:05 ` Mauro Carvalho Chehab
  2016-08-19 13:05 ` [PATCH 12/15] [media] docs-rst: move cec kAPI documentation to the media book Mauro Carvalho Chehab
                   ` (3 subsequent siblings)
  14 siblings, 0 replies; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:05 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab, Markus Heiser

A few tables at the media uAPI documentation have columns
not well dimentioned. Adjust them.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 Documentation/media/uapi/mediactl/media-types.rst | 14 ++++++++++++--
 1 file changed, 12 insertions(+), 2 deletions(-)

diff --git a/Documentation/media/uapi/mediactl/media-types.rst b/Documentation/media/uapi/mediactl/media-types.rst
index c77717b236ce..20f99301bfdb 100644
--- a/Documentation/media/uapi/mediactl/media-types.rst
+++ b/Documentation/media/uapi/mediactl/media-types.rst
@@ -5,9 +5,12 @@
 Types and flags used to represent the media graph elements
 ==========================================================
 
+..  tabularcolumns:: |p{8.0cm}|p{10.5cm}|
 
 .. _media-entity-type:
 
+.. cssclass:: longtable
+
 .. flat-table:: Media entity types
     :header-rows:  0
     :stub-columns: 0
@@ -15,10 +18,12 @@ Types and flags used to represent the media graph elements
 
     -  .. row 1
 
-       ..  _MEDIA-ENT-F-UNKNOWN:
+       .. _MEDIA-ENT-F-UNKNOWN:
        .. _MEDIA-ENT-F-V4L2-SUBDEV-UNKNOWN:
 
-       -  ``MEDIA_ENT_F_UNKNOWN`` and ``MEDIA_ENT_F_V4L2_SUBDEV_UNKNOWN``
+       -  ``MEDIA_ENT_F_UNKNOWN`` and
+
+	  ``MEDIA_ENT_F_V4L2_SUBDEV_UNKNOWN``
 
        -  Unknown entity. That generally indicates that a driver didn't
 	  initialize properly the entity, with is a Kernel bug
@@ -294,6 +299,8 @@ Types and flags used to represent the media graph elements
 	  its source pad.
 
 
+..  tabularcolumns:: |p{5.5cm}|p{12.0cm}|
+
 .. _media-entity-flag:
 
 .. flat-table:: Media entity flags
@@ -319,6 +326,7 @@ Types and flags used to represent the media graph elements
        -  The entity represents a data conector
 
 
+..  tabularcolumns:: |p{6.5cm}|p{6.0cm}|p{5.0cm}|
 
 .. _media-intf-type:
 
@@ -508,6 +516,7 @@ Types and flags used to represent the media graph elements
        -  typically, /dev/snd/timer
 
 
+.. tabularcolumns:: |p{5.5cm}|p{12.0cm}|
 
 .. _media-pad-flag:
 
@@ -551,6 +560,7 @@ Types and flags used to represent the media graph elements
 One and only one of ``MEDIA_PAD_FL_SINK`` and ``MEDIA_PAD_FL_SOURCE``
 must be set for every pad.
 
+.. tabularcolumns:: |p{5.5cm}|p{12.0cm}|
 
 .. _media-link-flag:
 
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* [PATCH 12/15] [media] docs-rst: move cec kAPI documentation to the media book
  2016-08-19 13:04 [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX Mauro Carvalho Chehab
                   ` (10 preceding siblings ...)
  2016-08-19 13:05 ` [PATCH 11/15] [media] media-types.rst: adjust tables to fit on LaTeX output Mauro Carvalho Chehab
@ 2016-08-19 13:05 ` Mauro Carvalho Chehab
  2016-08-19 13:05 ` [PATCH 13/15] [media] cec-core: Convert it to ReST format Mauro Carvalho Chehab
                   ` (2 subsequent siblings)
  14 siblings, 0 replies; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:05 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab

The CEC kAPI documentation should also be part of the media book.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 Documentation/{cec.txt => media/kapi/cec-core.rst} | 0
 Documentation/media/media_kapi.rst                 | 1 +
 2 files changed, 1 insertion(+)
 rename Documentation/{cec.txt => media/kapi/cec-core.rst} (100%)

diff --git a/Documentation/cec.txt b/Documentation/media/kapi/cec-core.rst
similarity index 100%
rename from Documentation/cec.txt
rename to Documentation/media/kapi/cec-core.rst
diff --git a/Documentation/media/media_kapi.rst b/Documentation/media/media_kapi.rst
index b71e8e8048ca..f282ca270369 100644
--- a/Documentation/media/media_kapi.rst
+++ b/Documentation/media/media_kapi.rst
@@ -32,3 +32,4 @@ For more details see the file COPYING in the source distribution of Linux.
     kapi/dtv-core
     kapi/rc-core
     kapi/mc-core
+    kapi/cec-core
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* [PATCH 13/15] [media] cec-core: Convert it to ReST format
  2016-08-19 13:04 [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX Mauro Carvalho Chehab
                   ` (11 preceding siblings ...)
  2016-08-19 13:05 ` [PATCH 12/15] [media] docs-rst: move cec kAPI documentation to the media book Mauro Carvalho Chehab
@ 2016-08-19 13:05 ` Mauro Carvalho Chehab
  2016-08-19 13:24   ` Hans Verkuil
  2016-08-19 13:05 ` [PATCH 14/15] [media] uapi/cec: adjust tables on LaTeX output Mauro Carvalho Chehab
  2016-08-19 13:05 ` [PATCH 15/15] [media] gen-errors.rst fix error table column limits Mauro Carvalho Chehab
  14 siblings, 1 reply; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:05 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab, Kamil Debski,
	Hans Verkuil

There are some things there that aren't ok for ReST format.

Fix them.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 Documentation/media/kapi/cec-core.rst | 145 ++++++++++++++++++++++------------
 1 file changed, 93 insertions(+), 52 deletions(-)

diff --git a/Documentation/media/kapi/cec-core.rst b/Documentation/media/kapi/cec-core.rst
index 75155fe37153..88c33b53ec13 100644
--- a/Documentation/media/kapi/cec-core.rst
+++ b/Documentation/media/kapi/cec-core.rst
@@ -36,39 +36,50 @@ CEC Adapter
 The struct cec_adapter represents the CEC adapter hardware. It is created by
 calling cec_allocate_adapter() and deleted by calling cec_delete_adapter():
 
-struct cec_adapter *cec_allocate_adapter(const struct cec_adap_ops *ops,
+.. c:function::
+   struct cec_adapter *cec_allocate_adapter(const struct cec_adap_ops *ops,
 	       void *priv, const char *name, u32 caps, u8 available_las,
 	       struct device *parent);
-void cec_delete_adapter(struct cec_adapter *adap);
+
+.. c:function::
+   void cec_delete_adapter(struct cec_adapter *adap);
 
 To create an adapter you need to pass the following information:
 
-ops: adapter operations which are called by the CEC framework and that you
-have to implement.
+ops:
+	adapter operations which are called by the CEC framework and that you
+	have to implement.
 
-priv: will be stored in adap->priv and can be used by the adapter ops.
+priv:
+	will be stored in adap->priv and can be used by the adapter ops.
 
-name: the name of the CEC adapter. Note: this name will be copied.
+name:
+	the name of the CEC adapter. Note: this name will be copied.
 
-caps: capabilities of the CEC adapter. These capabilities determine the
+caps:
+	capabilities of the CEC adapter. These capabilities determine the
 	capabilities of the hardware and which parts are to be handled
 	by userspace and which parts are handled by kernelspace. The
 	capabilities are returned by CEC_ADAP_G_CAPS.
 
-available_las: the number of simultaneous logical addresses that this
+available_las:
+	the number of simultaneous logical addresses that this
 	adapter can handle. Must be 1 <= available_las <= CEC_MAX_LOG_ADDRS.
 
-parent: the parent device.
+parent:
+	the parent device.
 
 
 To register the /dev/cecX device node and the remote control device (if
 CEC_CAP_RC is set) you call:
 
-int cec_register_adapter(struct cec_adapter *adap);
+.. c:function::
+	int cec_register_adapter(struct cec_adapter \*adap);
 
 To unregister the devices call:
 
-void cec_unregister_adapter(struct cec_adapter *adap);
+.. c:function::
+	void cec_unregister_adapter(struct cec_adapter \*adap);
 
 Note: if cec_register_adapter() fails, then call cec_delete_adapter() to
 clean up. But if cec_register_adapter() succeeded, then only call
@@ -83,18 +94,23 @@ Implementing the Low-Level CEC Adapter
 The following low-level adapter operations have to be implemented in
 your driver:
 
-struct cec_adap_ops {
-	/* Low-level callbacks */
-	int (*adap_enable)(struct cec_adapter *adap, bool enable);
-	int (*adap_monitor_all_enable)(struct cec_adapter *adap, bool enable);
-	int (*adap_log_addr)(struct cec_adapter *adap, u8 logical_addr);
-	int (*adap_transmit)(struct cec_adapter *adap, u8 attempts,
-			     u32 signal_free_time, struct cec_msg *msg);
-	void (*adap_log_status)(struct cec_adapter *adap);
+.. c:type:: struct cec_adap_ops
 
-	/* High-level callbacks */
-	...
-};
+.. code-block:: none
+
+	struct cec_adap_ops
+	{
+		/* Low-level callbacks */
+		int (*adap_enable)(struct cec_adapter *adap, bool enable);
+		int (*adap_monitor_all_enable)(struct cec_adapter *adap, bool enable);
+		int (*adap_log_addr)(struct cec_adapter *adap, u8 logical_addr);
+		int (*adap_transmit)(struct cec_adapter *adap, u8 attempts,
+				      u32 signal_free_time, struct cec_msg *msg);
+		void (\*adap_log_status)(struct cec_adapter *adap);
+
+		/* High-level callbacks */
+		...
+	};
 
 The three low-level ops deal with various aspects of controlling the CEC adapter
 hardware:
@@ -102,6 +118,7 @@ hardware:
 
 To enable/disable the hardware:
 
+.. c:function::
 	int (*adap_enable)(struct cec_adapter *adap, bool enable);
 
 This callback enables or disables the CEC hardware. Enabling the CEC hardware
@@ -115,6 +132,7 @@ Note that adap_enable must return 0 if enable is false.
 
 To enable/disable the 'monitor all' mode:
 
+.. c:function::
 	int (*adap_monitor_all_enable)(struct cec_adapter *adap, bool enable);
 
 If enabled, then the adapter should be put in a mode to also monitor messages
@@ -127,6 +145,7 @@ Note that adap_monitor_all_enable must return 0 if enable is false.
 
 To program a new logical address:
 
+.. c:function::
 	int (*adap_log_addr)(struct cec_adapter *adap, u8 logical_addr);
 
 If logical_addr == CEC_LOG_ADDR_INVALID then all programmed logical addresses
@@ -140,6 +159,7 @@ Note that adap_log_addr must return 0 if logical_addr is CEC_LOG_ADDR_INVALID.
 
 To transmit a new message:
 
+.. c:function::
 	int (*adap_transmit)(struct cec_adapter *adap, u8 attempts,
 			     u32 signal_free_time, struct cec_msg *msg);
 
@@ -158,6 +178,7 @@ microseconds (one data bit period is 2.4 ms).
 
 To log the current CEC hardware status:
 
+.. c:function::
 	void (*adap_status)(struct cec_adapter *adap, struct seq_file *file);
 
 This optional callback can be used to show the status of the CEC hardware.
@@ -169,29 +190,41 @@ driven) by calling into the framework in the following situations:
 
 When a transmit finished (successfully or otherwise):
 
-void cec_transmit_done(struct cec_adapter *adap, u8 status, u8 arb_lost_cnt,
+.. c:function::
+	void cec_transmit_done(struct cec_adapter *adap, u8 status, u8 arb_lost_cnt,
 		       u8 nack_cnt, u8 low_drive_cnt, u8 error_cnt);
 
 The status can be one of:
 
-CEC_TX_STATUS_OK: the transmit was successful.
-CEC_TX_STATUS_ARB_LOST: arbitration was lost: another CEC initiator
-took control of the CEC line and you lost the arbitration.
-CEC_TX_STATUS_NACK: the message was nacked (for a directed message) or
-acked (for a broadcast message). A retransmission is needed.
-CEC_TX_STATUS_LOW_DRIVE: low drive was detected on the CEC bus. This
-indicates that a follower detected an error on the bus and requested a
-retransmission.
-CEC_TX_STATUS_ERROR: some unspecified error occurred: this can be one of
-the previous two if the hardware cannot differentiate or something else
-entirely.
-CEC_TX_STATUS_MAX_RETRIES: could not transmit the message after
-trying multiple times. Should only be set by the driver if it has hardware
-support for retrying messages. If set, then the framework assumes that it
-doesn't have to make another attempt to transmit the message since the
-hardware did that already.
+CEC_TX_STATUS_OK:
+	the transmit was successful.
 
-The *_cnt arguments are the number of error conditions that were seen.
+CEC_TX_STATUS_ARB_LOST:
+	arbitration was lost: another CEC initiator
+	took control of the CEC line and you lost the arbitration.
+
+CEC_TX_STATUS_NACK:
+	the message was nacked (for a directed message) or
+	acked (for a broadcast message). A retransmission is needed.
+
+CEC_TX_STATUS_LOW_DRIVE:
+	low drive was detected on the CEC bus. This indicates that
+	a follower detected an error on the bus and requested a
+	retransmission.
+
+CEC_TX_STATUS_ERROR:
+	some unspecified error occurred: this can be one of
+	the previous two if the hardware cannot differentiate or something
+	else entirely.
+
+CEC_TX_STATUS_MAX_RETRIES:
+	could not transmit the message after trying multiple times.
+	Should only be set by the driver if it has hardware support for
+	retrying messages. If set, then the framework assumes that it
+	doesn't have to make another attempt to transmit the message
+	since the hardware did that already.
+
+The \*_cnt arguments are the number of error conditions that were seen.
 This may be 0 if no information is available. Drivers that do not support
 hardware retry can just set the counter corresponding to the transmit error
 to 1, if the hardware does support retry then either set these counters to
@@ -200,7 +233,8 @@ times, or fill in the correct values as reported by the hardware.
 
 When a CEC message was received:
 
-void cec_received_msg(struct cec_adapter *adap, struct cec_msg *msg);
+.. c:function::
+	void cec_received_msg(struct cec_adapter *adap, struct cec_msg *msg);
 
 Speaks for itself.
 
@@ -210,17 +244,20 @@ Implementing the High-Level CEC Adapter
 The low-level operations drive the hardware, the high-level operations are
 CEC protocol driven. The following high-level callbacks are available:
 
-struct cec_adap_ops {
-	/* Low-level callbacks */
-	...
+.. code-block:: none
 
-	/* High-level CEC message callback */
-	int (*received)(struct cec_adapter *adap, struct cec_msg *msg);
-};
+	struct cec_adap_ops {
+		/\* Low-level callbacks \*/
+		...
+
+		/\* High-level CEC message callback \*/
+		int (\*received)(struct cec_adapter \*adap, struct cec_msg \*msg);
+	};
 
 The received() callback allows the driver to optionally handle a newly
 received CEC message
 
+.. c:function::
 	int (*received)(struct cec_adapter *adap, struct cec_msg *msg);
 
 If the driver wants to process a CEC message, then it can implement this
@@ -234,13 +271,16 @@ CEC framework functions
 
 CEC Adapter drivers can call the following CEC framework functions:
 
-int cec_transmit_msg(struct cec_adapter *adap, struct cec_msg *msg,
-		     bool block);
+.. c:function::
+	int cec_transmit_msg(struct cec_adapter *adap, struct cec_msg *msg,
+			     bool block);
 
 Transmit a CEC message. If block is true, then wait until the message has been
 transmitted, otherwise just queue it and return.
 
-void cec_s_phys_addr(struct cec_adapter *adap, u16 phys_addr, bool block);
+.. c:function::
+	void cec_s_phys_addr(struct cec_adapter *adap, u16 phys_addr,
+			     bool block);
 
 Change the physical address. This function will set adap->phys_addr and
 send an event if it has changed. If cec_s_log_addrs() has been called and
@@ -254,8 +294,9 @@ then the CEC adapter will be disabled. If you change a valid physical address
 to another valid physical address, then this function will first set the
 address to CEC_PHYS_ADDR_INVALID before enabling the new physical address.
 
-int cec_s_log_addrs(struct cec_adapter *adap,
-		    struct cec_log_addrs *log_addrs, bool block);
+.. c:function::
+	int cec_s_log_addrs(struct cec_adapter *adap,
+			    struct cec_log_addrs *log_addrs, bool block);
 
 Claim the CEC logical addresses. Should never be called if CEC_CAP_LOG_ADDRS
 is set. If block is true, then wait until the logical addresses have been
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* [PATCH 14/15] [media] uapi/cec: adjust tables on LaTeX output
  2016-08-19 13:04 [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX Mauro Carvalho Chehab
                   ` (12 preceding siblings ...)
  2016-08-19 13:05 ` [PATCH 13/15] [media] cec-core: Convert it to ReST format Mauro Carvalho Chehab
@ 2016-08-19 13:05 ` Mauro Carvalho Chehab
  2016-08-19 13:05 ` [PATCH 15/15] [media] gen-errors.rst fix error table column limits Mauro Carvalho Chehab
  14 siblings, 0 replies; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:05 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab, Markus Heiser,
	Hans Verkuil

Fix tables to avoid text to overflow the cell limits.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 .../media/uapi/cec/cec-ioc-adap-g-caps.rst         |  4 ++--
 .../media/uapi/cec/cec-ioc-adap-g-log-addrs.rst    |  6 ++++--
 Documentation/media/uapi/cec/cec-ioc-dqevent.rst   | 23 +++++++++-------------
 Documentation/media/uapi/cec/cec-ioc-g-mode.rst    |  6 +++---
 Documentation/media/uapi/cec/cec-ioc-receive.rst   |  6 +++---
 5 files changed, 21 insertions(+), 24 deletions(-)

diff --git a/Documentation/media/uapi/cec/cec-ioc-adap-g-caps.rst b/Documentation/media/uapi/cec/cec-ioc-adap-g-caps.rst
index 4e70eae7e6ab..e0eaadaf2305 100644
--- a/Documentation/media/uapi/cec/cec-ioc-adap-g-caps.rst
+++ b/Documentation/media/uapi/cec/cec-ioc-adap-g-caps.rst
@@ -44,7 +44,7 @@ returns the information to the application. The ioctl never fails.
 
 .. _cec-caps:
 
-.. tabularcolumns:: |p{1.0cm}|p{1.0cm}|p{15.5cm}|
+.. tabularcolumns:: |p{1.2cm}|p{2.5cm}|p{13.8cm}|
 
 .. flat-table:: struct cec_caps
     :header-rows:  0
@@ -91,7 +91,7 @@ returns the information to the application. The ioctl never fails.
 
 .. _cec-capabilities:
 
-.. tabularcolumns:: |p{4.4cm}|p{1.5cm}|p{11.6cm}|
+.. tabularcolumns:: |p{4.4cm}|p{2.5cm}|p{10.6cm}|
 
 .. flat-table:: CEC Capabilities Flags
     :header-rows:  0
diff --git a/Documentation/media/uapi/cec/cec-ioc-adap-g-log-addrs.rst b/Documentation/media/uapi/cec/cec-ioc-adap-g-log-addrs.rst
index 11fac7e24554..959e920eb7c3 100644
--- a/Documentation/media/uapi/cec/cec-ioc-adap-g-log-addrs.rst
+++ b/Documentation/media/uapi/cec/cec-ioc-adap-g-log-addrs.rst
@@ -69,7 +69,9 @@ logical address types are already defined will return with error ``EBUSY``.
 
 .. _cec-log-addrs:
 
-.. tabularcolumns:: |p{1.0cm}|p{1.0cm}|p{15.5cm}|
+.. tabularcolumns:: |p{1.0cm}|p{7.5cm}|p{8.0cm}|
+
+.. cssclass:: longtable
 
 .. flat-table:: struct cec_log_addrs
     :header-rows:  0
@@ -311,7 +313,7 @@ logical address types are already defined will return with error ``EBUSY``.
 
 .. _cec-log-addr-types:
 
-.. tabularcolumns:: |p{2.6cm}|p{0.9cm}|p{14.0cm}|
+.. tabularcolumns:: |p{6.6cm}|p{2.2cm}|p{8.7cm}|
 
 .. flat-table:: CEC Logical Address Types
     :header-rows:  0
diff --git a/Documentation/media/uapi/cec/cec-ioc-dqevent.rst b/Documentation/media/uapi/cec/cec-ioc-dqevent.rst
index b4c73ed50509..c27b56881a4a 100644
--- a/Documentation/media/uapi/cec/cec-ioc-dqevent.rst
+++ b/Documentation/media/uapi/cec/cec-ioc-dqevent.rst
@@ -54,7 +54,7 @@ it is guaranteed that the state did change in between the two events.
 
 .. _cec-event-state-change_s:
 
-.. tabularcolumns:: |p{1.8cm}|p{1.8cm}|p{13.9cm}|
+.. tabularcolumns:: |p{1.2cm}|p{2.9cm}|p{13.4cm}|
 
 .. flat-table:: struct cec_event_state_change
     :header-rows:  0
@@ -82,7 +82,7 @@ it is guaranteed that the state did change in between the two events.
 
 .. _cec-event-lost-msgs_s:
 
-.. tabularcolumns:: |p{1.0cm}|p{1.0cm}|p{15.5cm}|
+.. tabularcolumns:: |p{1.0cm}|p{2.0cm}|p{14.5cm}|
 
 .. flat-table:: struct cec_event_lost_msgs
     :header-rows:  0
@@ -110,7 +110,7 @@ it is guaranteed that the state did change in between the two events.
 
 .. _cec-event:
 
-.. tabularcolumns:: |p{1.6cm}|p{1.6cm}|p{1.6cm}|p{12.7cm}|
+.. tabularcolumns:: |p{1.0cm}|p{4.2cm}|p{2.5cm}|p{8.8cm}|
 
 .. flat-table:: struct cec_event
     :header-rows:  0
@@ -124,21 +124,18 @@ it is guaranteed that the state did change in between the two events.
 
        -  ``ts``
 
-       -  Timestamp of the event in ns.
+       -  :cspan:`1` Timestamp of the event in ns.
+
 	  The timestamp has been taken from the ``CLOCK_MONOTONIC`` clock. To access
 	  the same clock from userspace use :c:func:`clock_gettime(2)`.
 
-       -
-
     -  .. row 2
 
        -  __u32
 
        -  ``event``
 
-       -  The CEC event type, see :ref:`cec-events`.
-
-       -
+       -  :cspan:`1` The CEC event type, see :ref:`cec-events`.
 
     -  .. row 3
 
@@ -146,9 +143,7 @@ it is guaranteed that the state did change in between the two events.
 
        -  ``flags``
 
-       -  Event flags, see :ref:`cec-event-flags`.
-
-       -
+       -  :cspan:`1` Event flags, see :ref:`cec-event-flags`.
 
     -  .. row 4
 
@@ -183,7 +178,7 @@ it is guaranteed that the state did change in between the two events.
 
 .. _cec-events:
 
-.. tabularcolumns:: |p{2.6cm}|p{0.9cm}|p{14.0cm}|
+.. tabularcolumns:: |p{5.6cm}|p{0.9cm}|p{11.0cm}|
 
 .. flat-table:: CEC Events Types
     :header-rows:  0
@@ -214,7 +209,7 @@ it is guaranteed that the state did change in between the two events.
 
 .. _cec-event-flags:
 
-.. tabularcolumns:: |p{4.4cm}|p{1.5cm}|p{11.6cm}|
+.. tabularcolumns:: |p{6.0cm}|p{0.6cm}|p{10.9cm}|
 
 .. flat-table:: CEC Event Flags
     :header-rows:  0
diff --git a/Documentation/media/uapi/cec/cec-ioc-g-mode.rst b/Documentation/media/uapi/cec/cec-ioc-g-mode.rst
index d213432eedd7..32261e0510ca 100644
--- a/Documentation/media/uapi/cec/cec-ioc-g-mode.rst
+++ b/Documentation/media/uapi/cec/cec-ioc-g-mode.rst
@@ -76,7 +76,7 @@ Available initiator modes are:
 
 .. _cec-mode-initiator_e:
 
-.. tabularcolumns:: |p{2.6cm}|p{0.9cm}|p{14.0cm}|
+.. tabularcolumns:: |p{5.6cm}|p{0.9cm}|p{11.0cm}|
 
 .. flat-table:: Initiator Modes
     :header-rows:  0
@@ -121,7 +121,7 @@ Available follower modes are:
 
 .. _cec-mode-follower_e:
 
-.. tabularcolumns:: |p{2.6cm}|p{0.9cm}|p{14.0cm}|
+.. tabularcolumns:: |p{6.6cm}|p{0.9cm}|p{10.0cm}|
 
 .. flat-table:: Follower Modes
     :header-rows:  0
@@ -215,7 +215,7 @@ Core message processing details:
 
 .. _cec-core-processing:
 
-.. tabularcolumns:: |p{1.9cm}|p{15.6cm}|
+.. tabularcolumns:: |p{6.6cm}|p{10.9cm}|
 
 .. flat-table:: Core Message Processing
     :header-rows:  0
diff --git a/Documentation/media/uapi/cec/cec-ioc-receive.rst b/Documentation/media/uapi/cec/cec-ioc-receive.rst
index 1a06c8d62ac9..7615c94dc826 100644
--- a/Documentation/media/uapi/cec/cec-ioc-receive.rst
+++ b/Documentation/media/uapi/cec/cec-ioc-receive.rst
@@ -75,7 +75,7 @@ result.
 
 .. _cec-msg:
 
-.. tabularcolumns:: |p{1.0cm}|p{1.0cm}|p{15.5cm}|
+.. tabularcolumns:: |p{1.0cm}|p{3.5cm}|p{13.0cm}|
 
 .. flat-table:: struct cec_msg
     :header-rows:  0
@@ -254,7 +254,7 @@ result.
 
 .. _cec-tx-status:
 
-.. tabularcolumns:: |p{2.6cm}|p{0.9cm}|p{14.0cm}|
+.. tabularcolumns:: |p{5.6cm}|p{0.9cm}|p{11.0cm}|
 
 .. flat-table:: CEC Transmit Status
     :header-rows:  0
@@ -324,7 +324,7 @@ result.
 
 .. _cec-rx-status:
 
-.. tabularcolumns:: |p{2.6cm}|p{0.9cm}|p{14.0cm}|
+.. tabularcolumns:: |p{5.6cm}|p{0.9cm}|p{11.0cm}|
 
 .. flat-table:: CEC Receive Status
     :header-rows:  0
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* [PATCH 15/15] [media] gen-errors.rst fix error table column limits
  2016-08-19 13:04 [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX Mauro Carvalho Chehab
                   ` (13 preceding siblings ...)
  2016-08-19 13:05 ` [PATCH 14/15] [media] uapi/cec: adjust tables on LaTeX output Mauro Carvalho Chehab
@ 2016-08-19 13:05 ` Mauro Carvalho Chehab
  14 siblings, 0 replies; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:05 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab, Markus Heiser

Fix the generic errors table to avoid column overflows on
LaTeX output.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
 Documentation/media/uapi/gen-errors.rst | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Documentation/media/uapi/gen-errors.rst b/Documentation/media/uapi/gen-errors.rst
index d37284d50e56..6e983b9880fc 100644
--- a/Documentation/media/uapi/gen-errors.rst
+++ b/Documentation/media/uapi/gen-errors.rst
@@ -9,7 +9,7 @@ Generic Error Codes
 
 .. _gen-errors:
 
-.. tabularcolumns:: |p{1.0cm}|p{16.5cm}|
+.. tabularcolumns:: |p{2.5cm}|p{15.0cm}|
 
 .. flat-table:: Generic error codes
     :header-rows:  0
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 19+ messages in thread

* Re: [PATCH 13/15] [media] cec-core: Convert it to ReST format
  2016-08-19 13:05 ` [PATCH 13/15] [media] cec-core: Convert it to ReST format Mauro Carvalho Chehab
@ 2016-08-19 13:24   ` Hans Verkuil
  2016-08-19 13:37     ` Mauro Carvalho Chehab
  0 siblings, 1 reply; 19+ messages in thread
From: Hans Verkuil @ 2016-08-19 13:24 UTC (permalink / raw)
  To: Mauro Carvalho Chehab, Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Jonathan Corbet, linux-doc, Markus Heiser,
	Mauro Carvalho Chehab, Kamil Debski

On 08/19/2016 03:05 PM, Mauro Carvalho Chehab wrote:
> There are some things there that aren't ok for ReST format.
>
> Fix them.
>
> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>

OK, so I posted a similar patch for this:

https://patchwork.linuxtv.org/patch/36376/

It's part of one of my pull requests, but I guess you can skip that patch.

	Hans

> ---
>  Documentation/media/kapi/cec-core.rst | 145 ++++++++++++++++++++++------------
>  1 file changed, 93 insertions(+), 52 deletions(-)
>
> diff --git a/Documentation/media/kapi/cec-core.rst b/Documentation/media/kapi/cec-core.rst
> index 75155fe37153..88c33b53ec13 100644
> --- a/Documentation/media/kapi/cec-core.rst
> +++ b/Documentation/media/kapi/cec-core.rst
> @@ -36,39 +36,50 @@ CEC Adapter
>  The struct cec_adapter represents the CEC adapter hardware. It is created by
>  calling cec_allocate_adapter() and deleted by calling cec_delete_adapter():
>
> -struct cec_adapter *cec_allocate_adapter(const struct cec_adap_ops *ops,
> +.. c:function::
> +   struct cec_adapter *cec_allocate_adapter(const struct cec_adap_ops *ops,
>  	       void *priv, const char *name, u32 caps, u8 available_las,
>  	       struct device *parent);
> -void cec_delete_adapter(struct cec_adapter *adap);
> +
> +.. c:function::
> +   void cec_delete_adapter(struct cec_adapter *adap);
>
>  To create an adapter you need to pass the following information:
>
> -ops: adapter operations which are called by the CEC framework and that you
> -have to implement.
> +ops:
> +	adapter operations which are called by the CEC framework and that you
> +	have to implement.
>
> -priv: will be stored in adap->priv and can be used by the adapter ops.
> +priv:
> +	will be stored in adap->priv and can be used by the adapter ops.
>
> -name: the name of the CEC adapter. Note: this name will be copied.
> +name:
> +	the name of the CEC adapter. Note: this name will be copied.
>
> -caps: capabilities of the CEC adapter. These capabilities determine the
> +caps:
> +	capabilities of the CEC adapter. These capabilities determine the
>  	capabilities of the hardware and which parts are to be handled
>  	by userspace and which parts are handled by kernelspace. The
>  	capabilities are returned by CEC_ADAP_G_CAPS.
>
> -available_las: the number of simultaneous logical addresses that this
> +available_las:
> +	the number of simultaneous logical addresses that this
>  	adapter can handle. Must be 1 <= available_las <= CEC_MAX_LOG_ADDRS.
>
> -parent: the parent device.
> +parent:
> +	the parent device.
>
>
>  To register the /dev/cecX device node and the remote control device (if
>  CEC_CAP_RC is set) you call:
>
> -int cec_register_adapter(struct cec_adapter *adap);
> +.. c:function::
> +	int cec_register_adapter(struct cec_adapter \*adap);
>
>  To unregister the devices call:
>
> -void cec_unregister_adapter(struct cec_adapter *adap);
> +.. c:function::
> +	void cec_unregister_adapter(struct cec_adapter \*adap);
>
>  Note: if cec_register_adapter() fails, then call cec_delete_adapter() to
>  clean up. But if cec_register_adapter() succeeded, then only call
> @@ -83,18 +94,23 @@ Implementing the Low-Level CEC Adapter
>  The following low-level adapter operations have to be implemented in
>  your driver:
>
> -struct cec_adap_ops {
> -	/* Low-level callbacks */
> -	int (*adap_enable)(struct cec_adapter *adap, bool enable);
> -	int (*adap_monitor_all_enable)(struct cec_adapter *adap, bool enable);
> -	int (*adap_log_addr)(struct cec_adapter *adap, u8 logical_addr);
> -	int (*adap_transmit)(struct cec_adapter *adap, u8 attempts,
> -			     u32 signal_free_time, struct cec_msg *msg);
> -	void (*adap_log_status)(struct cec_adapter *adap);
> +.. c:type:: struct cec_adap_ops
>
> -	/* High-level callbacks */
> -	...
> -};
> +.. code-block:: none
> +
> +	struct cec_adap_ops
> +	{
> +		/* Low-level callbacks */
> +		int (*adap_enable)(struct cec_adapter *adap, bool enable);
> +		int (*adap_monitor_all_enable)(struct cec_adapter *adap, bool enable);
> +		int (*adap_log_addr)(struct cec_adapter *adap, u8 logical_addr);
> +		int (*adap_transmit)(struct cec_adapter *adap, u8 attempts,
> +				      u32 signal_free_time, struct cec_msg *msg);
> +		void (\*adap_log_status)(struct cec_adapter *adap);
> +
> +		/* High-level callbacks */
> +		...
> +	};
>
>  The three low-level ops deal with various aspects of controlling the CEC adapter
>  hardware:
> @@ -102,6 +118,7 @@ hardware:
>
>  To enable/disable the hardware:
>
> +.. c:function::
>  	int (*adap_enable)(struct cec_adapter *adap, bool enable);
>
>  This callback enables or disables the CEC hardware. Enabling the CEC hardware
> @@ -115,6 +132,7 @@ Note that adap_enable must return 0 if enable is false.
>
>  To enable/disable the 'monitor all' mode:
>
> +.. c:function::
>  	int (*adap_monitor_all_enable)(struct cec_adapter *adap, bool enable);
>
>  If enabled, then the adapter should be put in a mode to also monitor messages
> @@ -127,6 +145,7 @@ Note that adap_monitor_all_enable must return 0 if enable is false.
>
>  To program a new logical address:
>
> +.. c:function::
>  	int (*adap_log_addr)(struct cec_adapter *adap, u8 logical_addr);
>
>  If logical_addr == CEC_LOG_ADDR_INVALID then all programmed logical addresses
> @@ -140,6 +159,7 @@ Note that adap_log_addr must return 0 if logical_addr is CEC_LOG_ADDR_INVALID.
>
>  To transmit a new message:
>
> +.. c:function::
>  	int (*adap_transmit)(struct cec_adapter *adap, u8 attempts,
>  			     u32 signal_free_time, struct cec_msg *msg);
>
> @@ -158,6 +178,7 @@ microseconds (one data bit period is 2.4 ms).
>
>  To log the current CEC hardware status:
>
> +.. c:function::
>  	void (*adap_status)(struct cec_adapter *adap, struct seq_file *file);
>
>  This optional callback can be used to show the status of the CEC hardware.
> @@ -169,29 +190,41 @@ driven) by calling into the framework in the following situations:
>
>  When a transmit finished (successfully or otherwise):
>
> -void cec_transmit_done(struct cec_adapter *adap, u8 status, u8 arb_lost_cnt,
> +.. c:function::
> +	void cec_transmit_done(struct cec_adapter *adap, u8 status, u8 arb_lost_cnt,
>  		       u8 nack_cnt, u8 low_drive_cnt, u8 error_cnt);
>
>  The status can be one of:
>
> -CEC_TX_STATUS_OK: the transmit was successful.
> -CEC_TX_STATUS_ARB_LOST: arbitration was lost: another CEC initiator
> -took control of the CEC line and you lost the arbitration.
> -CEC_TX_STATUS_NACK: the message was nacked (for a directed message) or
> -acked (for a broadcast message). A retransmission is needed.
> -CEC_TX_STATUS_LOW_DRIVE: low drive was detected on the CEC bus. This
> -indicates that a follower detected an error on the bus and requested a
> -retransmission.
> -CEC_TX_STATUS_ERROR: some unspecified error occurred: this can be one of
> -the previous two if the hardware cannot differentiate or something else
> -entirely.
> -CEC_TX_STATUS_MAX_RETRIES: could not transmit the message after
> -trying multiple times. Should only be set by the driver if it has hardware
> -support for retrying messages. If set, then the framework assumes that it
> -doesn't have to make another attempt to transmit the message since the
> -hardware did that already.
> +CEC_TX_STATUS_OK:
> +	the transmit was successful.
>
> -The *_cnt arguments are the number of error conditions that were seen.
> +CEC_TX_STATUS_ARB_LOST:
> +	arbitration was lost: another CEC initiator
> +	took control of the CEC line and you lost the arbitration.
> +
> +CEC_TX_STATUS_NACK:
> +	the message was nacked (for a directed message) or
> +	acked (for a broadcast message). A retransmission is needed.
> +
> +CEC_TX_STATUS_LOW_DRIVE:
> +	low drive was detected on the CEC bus. This indicates that
> +	a follower detected an error on the bus and requested a
> +	retransmission.
> +
> +CEC_TX_STATUS_ERROR:
> +	some unspecified error occurred: this can be one of
> +	the previous two if the hardware cannot differentiate or something
> +	else entirely.
> +
> +CEC_TX_STATUS_MAX_RETRIES:
> +	could not transmit the message after trying multiple times.
> +	Should only be set by the driver if it has hardware support for
> +	retrying messages. If set, then the framework assumes that it
> +	doesn't have to make another attempt to transmit the message
> +	since the hardware did that already.
> +
> +The \*_cnt arguments are the number of error conditions that were seen.
>  This may be 0 if no information is available. Drivers that do not support
>  hardware retry can just set the counter corresponding to the transmit error
>  to 1, if the hardware does support retry then either set these counters to
> @@ -200,7 +233,8 @@ times, or fill in the correct values as reported by the hardware.
>
>  When a CEC message was received:
>
> -void cec_received_msg(struct cec_adapter *adap, struct cec_msg *msg);
> +.. c:function::
> +	void cec_received_msg(struct cec_adapter *adap, struct cec_msg *msg);
>
>  Speaks for itself.
>
> @@ -210,17 +244,20 @@ Implementing the High-Level CEC Adapter
>  The low-level operations drive the hardware, the high-level operations are
>  CEC protocol driven. The following high-level callbacks are available:
>
> -struct cec_adap_ops {
> -	/* Low-level callbacks */
> -	...
> +.. code-block:: none
>
> -	/* High-level CEC message callback */
> -	int (*received)(struct cec_adapter *adap, struct cec_msg *msg);
> -};
> +	struct cec_adap_ops {
> +		/\* Low-level callbacks \*/
> +		...
> +
> +		/\* High-level CEC message callback \*/
> +		int (\*received)(struct cec_adapter \*adap, struct cec_msg \*msg);
> +	};
>
>  The received() callback allows the driver to optionally handle a newly
>  received CEC message
>
> +.. c:function::
>  	int (*received)(struct cec_adapter *adap, struct cec_msg *msg);
>
>  If the driver wants to process a CEC message, then it can implement this
> @@ -234,13 +271,16 @@ CEC framework functions
>
>  CEC Adapter drivers can call the following CEC framework functions:
>
> -int cec_transmit_msg(struct cec_adapter *adap, struct cec_msg *msg,
> -		     bool block);
> +.. c:function::
> +	int cec_transmit_msg(struct cec_adapter *adap, struct cec_msg *msg,
> +			     bool block);
>
>  Transmit a CEC message. If block is true, then wait until the message has been
>  transmitted, otherwise just queue it and return.
>
> -void cec_s_phys_addr(struct cec_adapter *adap, u16 phys_addr, bool block);
> +.. c:function::
> +	void cec_s_phys_addr(struct cec_adapter *adap, u16 phys_addr,
> +			     bool block);
>
>  Change the physical address. This function will set adap->phys_addr and
>  send an event if it has changed. If cec_s_log_addrs() has been called and
> @@ -254,8 +294,9 @@ then the CEC adapter will be disabled. If you change a valid physical address
>  to another valid physical address, then this function will first set the
>  address to CEC_PHYS_ADDR_INVALID before enabling the new physical address.
>
> -int cec_s_log_addrs(struct cec_adapter *adap,
> -		    struct cec_log_addrs *log_addrs, bool block);
> +.. c:function::
> +	int cec_s_log_addrs(struct cec_adapter *adap,
> +			    struct cec_log_addrs *log_addrs, bool block);
>
>  Claim the CEC logical addresses. Should never be called if CEC_CAP_LOG_ADDRS
>  is set. If block is true, then wait until the logical addresses have been
>


^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: [PATCH 13/15] [media] cec-core: Convert it to ReST format
  2016-08-19 13:24   ` Hans Verkuil
@ 2016-08-19 13:37     ` Mauro Carvalho Chehab
  2016-08-19 13:41       ` Mauro Carvalho Chehab
  0 siblings, 1 reply; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:37 UTC (permalink / raw)
  To: Hans Verkuil
  Cc: Linux Media Mailing List, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab, Kamil Debski

Em Fri, 19 Aug 2016 15:24:16 +0200
Hans Verkuil <hansverk@cisco.com> escreveu:

> On 08/19/2016 03:05 PM, Mauro Carvalho Chehab wrote:
> > There are some things there that aren't ok for ReST format.
> >
> > Fix them.
> >
> > Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>  
> 
> OK, so I posted a similar patch for this:
> 
> https://patchwork.linuxtv.org/patch/36376/
> 
> It's part of one of my pull requests, but I guess you can skip that patch.

Sorry, I didn't notice. I'm actually waiting for Jon to merge the
remaining patches for the Sphinx rst core before starting handling
and merging our patches. I want to avoid having a separate branch for
documentation this time.

IMHO, my approach is better than you for functions, as it declares
functions and struct using the proper macros that are also used
by kernel-doc script.

Yet, I didn't touch at MAINTAINERS nor I used ``constant`` or
:c:type:/:c:func: for references of the functions/struct. 
Would you care to rebase your patch on the top of mine doing such
changes?

Thanks!
Mauro

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: [PATCH 13/15] [media] cec-core: Convert it to ReST format
  2016-08-19 13:37     ` Mauro Carvalho Chehab
@ 2016-08-19 13:41       ` Mauro Carvalho Chehab
  0 siblings, 0 replies; 19+ messages in thread
From: Mauro Carvalho Chehab @ 2016-08-19 13:41 UTC (permalink / raw)
  To: Hans Verkuil
  Cc: Linux Media Mailing List, Mauro Carvalho Chehab, Jonathan Corbet,
	linux-doc, Markus Heiser, Mauro Carvalho Chehab, Kamil Debski

Em Fri, 19 Aug 2016 10:37:50 -0300
Mauro Carvalho Chehab <mchehab@s-opensource.com> escreveu:

> Em Fri, 19 Aug 2016 15:24:16 +0200
> Hans Verkuil <hansverk@cisco.com> escreveu:
> 
> > On 08/19/2016 03:05 PM, Mauro Carvalho Chehab wrote:  
> > > There are some things there that aren't ok for ReST format.
> > >
> > > Fix them.
> > >
> > > Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>    
> > 
> > OK, so I posted a similar patch for this:
> > 
> > https://patchwork.linuxtv.org/patch/36376/
> > 
> > It's part of one of my pull requests, but I guess you can skip that patch.  
> 
> Sorry, I didn't notice. I'm actually waiting for Jon to merge the
> remaining patches for the Sphinx rst core before starting handling
> and merging our patches. I want to avoid having a separate branch for
> documentation this time.
> 
> IMHO, my approach is better than you for functions, as it declares
> functions and struct using the proper macros that are also used
> by kernel-doc script.
> 
> Yet, I didn't touch at MAINTAINERS nor I used ``constant`` or
> :c:type:/:c:func: for references of the functions/struct. 
> Would you care to rebase your patch on the top of mine doing such
> changes?

Hmm... actually we should do something else...

As those functions are declared (or should be declared) using the
kernel documentation macros, we should have references for them
already. So, we need to actually change the text there to point
to the references created by kernel-doc script.

like:

	https://linuxtv.org/downloads/v4l-dvb-apis-new/_sources/media/kapi/v4l2-dev.txt

Thanks,
Mauro

^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2016-08-19 13:42 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-19 13:04 [PATCH 00/15] Fix (most of) the remaining issues with uAPI book and LaTeX Mauro Carvalho Chehab
2016-08-19 13:04 ` [PATCH 01/15] [media] vidioc-dqevent.rst: adjust two table columns for LaTeX output Mauro Carvalho Chehab
2016-08-19 13:04 ` [PATCH 02/15] [media] vidioc-dv-timings-cap.rst: Adjust LaTeX columns Mauro Carvalho Chehab
2016-08-19 13:04 ` [PATCH 03/15] [media] vidioc-enumstd.rst: adjust video standards table Mauro Carvalho Chehab
2016-08-19 13:04 ` [PATCH 04/15] [media] vidioc-g-sliced-vbi-cap.rst: make tables fit on LaTeX output Mauro Carvalho Chehab
2016-08-19 13:04 ` [PATCH 05/15] [media] adjust some vidioc-*rst tables with wrong columns Mauro Carvalho Chehab
2016-08-19 13:04 ` [PATCH 06/15] [media] vidioc-g-tuner.rst: improve documentation for tuner type Mauro Carvalho Chehab
2016-08-19 13:04 ` [PATCH 07/15] [media] vidioc-g-tuner.rst: Fix tables to fit at LaTeX output Mauro Carvalho Chehab
2016-08-19 13:04 ` [PATCH 08/15] [media] fix v4l2-selection-*.rst tables for " Mauro Carvalho Chehab
2016-08-19 13:04 ` [PATCH 09/15] [media] fe_property_parameters.rst: Adjust column sizes Mauro Carvalho Chehab
2016-08-19 13:05 ` [PATCH 10/15] [media] adjust remaining tables at DVB uAPI documentation Mauro Carvalho Chehab
2016-08-19 13:05 ` [PATCH 11/15] [media] media-types.rst: adjust tables to fit on LaTeX output Mauro Carvalho Chehab
2016-08-19 13:05 ` [PATCH 12/15] [media] docs-rst: move cec kAPI documentation to the media book Mauro Carvalho Chehab
2016-08-19 13:05 ` [PATCH 13/15] [media] cec-core: Convert it to ReST format Mauro Carvalho Chehab
2016-08-19 13:24   ` Hans Verkuil
2016-08-19 13:37     ` Mauro Carvalho Chehab
2016-08-19 13:41       ` Mauro Carvalho Chehab
2016-08-19 13:05 ` [PATCH 14/15] [media] uapi/cec: adjust tables on LaTeX output Mauro Carvalho Chehab
2016-08-19 13:05 ` [PATCH 15/15] [media] gen-errors.rst fix error table column limits Mauro Carvalho Chehab

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.