Loading Documentation/DocBook/Makefile +1 −0 Original line number Diff line number Diff line Loading @@ -72,6 +72,7 @@ installmandocs: mandocs # no-op for the DocBook toolchain epubdocs: latexdocs: ### #External programs used Loading Documentation/Makefile.sphinx +6 −1 Original line number Diff line number Diff line Loading @@ -66,12 +66,16 @@ quiet_cmd_sphinx = SPHINX $@ --> file://$(abspath $(BUILDDIR)/$3/$4); htmldocs: @$(foreach var,$(SPHINXDIRS),$(call loop_cmd,sphinx,html,$(var),,$(var))) pdfdocs: latexdocs: ifeq ($(HAVE_PDFLATEX),0) $(warning The 'xelatex' command was not found. Make sure you have it installed and in PATH to produce PDF output.) @echo " SKIP Sphinx $@ target." else # HAVE_PDFLATEX @$(call loop_cmd,sphinx,latex,.,latex,.) endif # HAVE_PDFLATEX pdfdocs: latexdocs ifneq ($(HAVE_PDFLATEX),0) $(Q)$(MAKE) PDFLATEX=xelatex LATEXOPTS="-interaction=nonstopmode" -C $(BUILDDIR)/latex endif # HAVE_PDFLATEX Loading @@ -95,6 +99,7 @@ endif # HAVE_SPHINX dochelp: @echo ' Linux kernel internal documentation in different formats (Sphinx):' @echo ' htmldocs - HTML' @echo ' latexdocs - LaTeX' @echo ' pdfdocs - PDF' @echo ' epubdocs - EPUB' @echo ' xmldocs - XML' Loading Documentation/conf.py +35 −12 Original line number Diff line number Diff line Loading @@ -34,7 +34,7 @@ from load_config import loadConfig # Add any Sphinx extension module names here, as strings. They can be # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom # ones. extensions = ['kernel-doc', 'rstFlatTable', 'kernel_include'] extensions = ['kernel-doc', 'rstFlatTable', 'kernel_include', 'cdomain'] # The name of the math extension changed on Sphinx 1.4 if minor > 3: Loading Loading @@ -277,26 +277,46 @@ latex_elements = { % Allow generate some pages in landscape \\usepackage{lscape} % Put notes in gray color and let them be inside a table \\definecolor{MyGray}{rgb}{0.80,0.80,0.80} \\makeatletter\\newenvironment{graybox}{% \\begin{lrbox}{\\@tempboxa}\\begin{minipage}{\\columnwidth}}{\\end{minipage}\\end{lrbox}% \\colorbox{MyGray}{\\usebox{\\@tempboxa}} % Put notes in color and let them be inside a table \\definecolor{NoteColor}{RGB}{204,255,255} \\definecolor{WarningColor}{RGB}{255,204,204} \\definecolor{AttentionColor}{RGB}{255,255,204} \\definecolor{OtherColor}{RGB}{204,204,204} \\newlength{\\mynoticelength} \\makeatletter\\newenvironment{coloredbox}[1]{% \\setlength{\\fboxrule}{1pt} \\setlength{\\fboxsep}{7pt} \\setlength{\\mynoticelength}{\\linewidth} \\addtolength{\\mynoticelength}{-2\\fboxsep} \\addtolength{\\mynoticelength}{-2\\fboxrule} \\begin{lrbox}{\\@tempboxa}\\begin{minipage}{\\mynoticelength}}{\\end{minipage}\\end{lrbox}% \\ifthenelse% {\\equal{\\py@noticetype}{note}}% {\\colorbox{NoteColor}{\\usebox{\\@tempboxa}}}% {% \\ifthenelse% {\\equal{\\py@noticetype}{warning}}% {\\colorbox{WarningColor}{\\usebox{\\@tempboxa}}}% {% \\ifthenelse% {\\equal{\\py@noticetype}{attention}}% {\\colorbox{AttentionColor}{\\usebox{\\@tempboxa}}}% {\\colorbox{OtherColor}{\\usebox{\\@tempboxa}}}% }% }% }\\makeatother \\makeatletter \\renewenvironment{notice}[2]{ \\begin{graybox} \\bf\\it \\renewenvironment{notice}[2]{% \\def\\py@noticetype{#1} \\begin{coloredbox}{#1} \\bf\\it \\par\\strong{#2} \\csname py@noticestart@#1\\endcsname } { \\csname py@noticeend@\\py@noticetype\\endcsname \\end{graybox} \\end{coloredbox} } \\makeatother Loading @@ -306,6 +326,9 @@ latex_elements = { \\setromanfont{DejaVu Sans} \\setmonofont{DejaVu Sans Mono} % To allow adjusting table sizes \\usepackage{adjustbox} ''' } Loading Documentation/kernel-documentation.rst +29 −0 Original line number Diff line number Diff line Loading @@ -107,6 +107,35 @@ Here are some specific guidelines for the kernel documentation: the order as encountered."), having the higher levels the same overall makes it easier to follow the documents. the C domain ------------ The `Sphinx C Domain`_ (name c) is suited for documentation of C API. E.g. a function prototype: .. code-block:: rst .. c:function:: int ioctl( int fd, int request ) The C domain of the kernel-doc has some additional features. E.g. you can *rename* the reference name of a function with a common name like ``open`` or ``ioctl``: .. code-block:: rst .. c:function:: int ioctl( int fd, int request ) :name: VIDIOC_LOG_STATUS The func-name (e.g. ioctl) remains in the output but the ref-name changed from ``ioctl`` to ``VIDIOC_LOG_STATUS``. The index entry for this function is also changed to ``VIDIOC_LOG_STATUS`` and the function can now referenced by: .. code-block:: rst :c:func:`VIDIOC_LOG_STATUS` list tables ----------- Loading Documentation/media/uapi/cec/cec-func-open.rst +1 −1 Original line number Diff line number Diff line Loading @@ -32,7 +32,7 @@ Arguments Open flags. Access mode must be ``O_RDWR``. When the ``O_NONBLOCK`` flag is given, the :ref:`CEC_RECEIVE <CEC_RECEIVE>` and :ref:`CEC_DQEVENT <CEC_DQEVENT>` ioctls :ref:`CEC_RECEIVE <CEC_RECEIVE>` and :c:func:`CEC_DQEVENT` ioctls will return the ``EAGAIN`` error code when no message or event is available, and ioctls :ref:`CEC_TRANSMIT <CEC_TRANSMIT>`, :ref:`CEC_ADAP_S_PHYS_ADDR <CEC_ADAP_S_PHYS_ADDR>` and Loading Loading
Documentation/DocBook/Makefile +1 −0 Original line number Diff line number Diff line Loading @@ -72,6 +72,7 @@ installmandocs: mandocs # no-op for the DocBook toolchain epubdocs: latexdocs: ### #External programs used Loading
Documentation/Makefile.sphinx +6 −1 Original line number Diff line number Diff line Loading @@ -66,12 +66,16 @@ quiet_cmd_sphinx = SPHINX $@ --> file://$(abspath $(BUILDDIR)/$3/$4); htmldocs: @$(foreach var,$(SPHINXDIRS),$(call loop_cmd,sphinx,html,$(var),,$(var))) pdfdocs: latexdocs: ifeq ($(HAVE_PDFLATEX),0) $(warning The 'xelatex' command was not found. Make sure you have it installed and in PATH to produce PDF output.) @echo " SKIP Sphinx $@ target." else # HAVE_PDFLATEX @$(call loop_cmd,sphinx,latex,.,latex,.) endif # HAVE_PDFLATEX pdfdocs: latexdocs ifneq ($(HAVE_PDFLATEX),0) $(Q)$(MAKE) PDFLATEX=xelatex LATEXOPTS="-interaction=nonstopmode" -C $(BUILDDIR)/latex endif # HAVE_PDFLATEX Loading @@ -95,6 +99,7 @@ endif # HAVE_SPHINX dochelp: @echo ' Linux kernel internal documentation in different formats (Sphinx):' @echo ' htmldocs - HTML' @echo ' latexdocs - LaTeX' @echo ' pdfdocs - PDF' @echo ' epubdocs - EPUB' @echo ' xmldocs - XML' Loading
Documentation/conf.py +35 −12 Original line number Diff line number Diff line Loading @@ -34,7 +34,7 @@ from load_config import loadConfig # Add any Sphinx extension module names here, as strings. They can be # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom # ones. extensions = ['kernel-doc', 'rstFlatTable', 'kernel_include'] extensions = ['kernel-doc', 'rstFlatTable', 'kernel_include', 'cdomain'] # The name of the math extension changed on Sphinx 1.4 if minor > 3: Loading Loading @@ -277,26 +277,46 @@ latex_elements = { % Allow generate some pages in landscape \\usepackage{lscape} % Put notes in gray color and let them be inside a table \\definecolor{MyGray}{rgb}{0.80,0.80,0.80} \\makeatletter\\newenvironment{graybox}{% \\begin{lrbox}{\\@tempboxa}\\begin{minipage}{\\columnwidth}}{\\end{minipage}\\end{lrbox}% \\colorbox{MyGray}{\\usebox{\\@tempboxa}} % Put notes in color and let them be inside a table \\definecolor{NoteColor}{RGB}{204,255,255} \\definecolor{WarningColor}{RGB}{255,204,204} \\definecolor{AttentionColor}{RGB}{255,255,204} \\definecolor{OtherColor}{RGB}{204,204,204} \\newlength{\\mynoticelength} \\makeatletter\\newenvironment{coloredbox}[1]{% \\setlength{\\fboxrule}{1pt} \\setlength{\\fboxsep}{7pt} \\setlength{\\mynoticelength}{\\linewidth} \\addtolength{\\mynoticelength}{-2\\fboxsep} \\addtolength{\\mynoticelength}{-2\\fboxrule} \\begin{lrbox}{\\@tempboxa}\\begin{minipage}{\\mynoticelength}}{\\end{minipage}\\end{lrbox}% \\ifthenelse% {\\equal{\\py@noticetype}{note}}% {\\colorbox{NoteColor}{\\usebox{\\@tempboxa}}}% {% \\ifthenelse% {\\equal{\\py@noticetype}{warning}}% {\\colorbox{WarningColor}{\\usebox{\\@tempboxa}}}% {% \\ifthenelse% {\\equal{\\py@noticetype}{attention}}% {\\colorbox{AttentionColor}{\\usebox{\\@tempboxa}}}% {\\colorbox{OtherColor}{\\usebox{\\@tempboxa}}}% }% }% }\\makeatother \\makeatletter \\renewenvironment{notice}[2]{ \\begin{graybox} \\bf\\it \\renewenvironment{notice}[2]{% \\def\\py@noticetype{#1} \\begin{coloredbox}{#1} \\bf\\it \\par\\strong{#2} \\csname py@noticestart@#1\\endcsname } { \\csname py@noticeend@\\py@noticetype\\endcsname \\end{graybox} \\end{coloredbox} } \\makeatother Loading @@ -306,6 +326,9 @@ latex_elements = { \\setromanfont{DejaVu Sans} \\setmonofont{DejaVu Sans Mono} % To allow adjusting table sizes \\usepackage{adjustbox} ''' } Loading
Documentation/kernel-documentation.rst +29 −0 Original line number Diff line number Diff line Loading @@ -107,6 +107,35 @@ Here are some specific guidelines for the kernel documentation: the order as encountered."), having the higher levels the same overall makes it easier to follow the documents. the C domain ------------ The `Sphinx C Domain`_ (name c) is suited for documentation of C API. E.g. a function prototype: .. code-block:: rst .. c:function:: int ioctl( int fd, int request ) The C domain of the kernel-doc has some additional features. E.g. you can *rename* the reference name of a function with a common name like ``open`` or ``ioctl``: .. code-block:: rst .. c:function:: int ioctl( int fd, int request ) :name: VIDIOC_LOG_STATUS The func-name (e.g. ioctl) remains in the output but the ref-name changed from ``ioctl`` to ``VIDIOC_LOG_STATUS``. The index entry for this function is also changed to ``VIDIOC_LOG_STATUS`` and the function can now referenced by: .. code-block:: rst :c:func:`VIDIOC_LOG_STATUS` list tables ----------- Loading
Documentation/media/uapi/cec/cec-func-open.rst +1 −1 Original line number Diff line number Diff line Loading @@ -32,7 +32,7 @@ Arguments Open flags. Access mode must be ``O_RDWR``. When the ``O_NONBLOCK`` flag is given, the :ref:`CEC_RECEIVE <CEC_RECEIVE>` and :ref:`CEC_DQEVENT <CEC_DQEVENT>` ioctls :ref:`CEC_RECEIVE <CEC_RECEIVE>` and :c:func:`CEC_DQEVENT` ioctls will return the ``EAGAIN`` error code when no message or event is available, and ioctls :ref:`CEC_TRANSMIT <CEC_TRANSMIT>`, :ref:`CEC_ADAP_S_PHYS_ADDR <CEC_ADAP_S_PHYS_ADDR>` and Loading