08 Jun, 2020

1 commit

  • Rationale:
    Reduces attack surface on kernel devs opening the links for MITM
    as HTTPS traffic is much harder to manipulate.

    Deterministic algorithm:
    For each file:
    For each line:
    If doesn't contain `\bxmlns\b`:
    For each link, `\bhttp://[^# \t\r\n]*(?:\w|/)`:
    If both the HTTP and HTTPS versions
    return 200 OK and serve the same content:
    Replace HTTP with HTTPS.

    Signed-off-by: Alexander A. Klimov
    Link: https://lore.kernel.org/r/20200526060544.25127-1-grandmaster@al2klimov.de
    Signed-off-by: Jonathan Corbet

    Alexander A. Klimov
     

21 Apr, 2020

1 commit

  • The building system can auto-generate a list of documents since
    commit: 9d42afbe6bd4 ("docs: pdf: add all Documentation/*/index.rst to PDF output").

    The added logic there allows keeping the existing list, but
    there's not real reason to keep it. Now, the media document
    has gone (it was split into tree).

    So, it sounds about time to get rid of the manual entries,
    and let the script to generate it automatically instead.

    Signed-off-by: Mauro Carvalho Chehab
    Link: https://lore.kernel.org/r/9345dba7164497dbf28578f6ec271e479379610c.1586881715.git.mchehab+huawei@kernel.org
    Signed-off-by: Jonathan Corbet

    Mauro Carvalho Chehab
     

21 Mar, 2020

1 commit

  • The autosectionlabel extension is nice, as it allows to refer to
    a section by its name without requiring any extra tag to create
    a reference name.

    However, on its default, it has two serious problems:

    1) the namespace is global. So, two files with different
    "introduction" section would create a label with the
    same name. This is easily solvable by forcing the extension
    to prepend the file name with:

    autosectionlabel_prefix_document = True

    2) It doesn't work hierarchically. So, if there are two level 1
    sessions (let's say, one labeled "open" and another one "ioctl")
    and both have a level 2 "synopsis" label, both section 2 will
    have the same identical name.

    Currently, there's no way to tell Sphinx to create an
    hierarchical reference like:

    open / synopsis
    ioctl / synopsis

    This causes around 800 warnings. So, the fix should be to
    not let autosectionlabel to produce references for anything
    that it is not at a chapter level within any doc, with:

    autosectionlabel_maxdepth = 2

    Fixes: 58ad30cf91f0 ("docs: fix reference to core-api/namespaces.rst")
    Signed-off-by: Mauro Carvalho Chehab
    Link: https://lore.kernel.org/r/74f4d8d91c648d7101c45b4b99cc93532f4dadc6.1584716446.git.mchehab+huawei@kernel.org
    Signed-off-by: Jonathan Corbet

    Mauro Carvalho Chehab
     

20 Mar, 2020

1 commit

  • Fix a couple of dangling links to core-api/namespaces.rst by turning them
    into proper references. Enable the autosection extension (available since
    Sphinx 1.4) to make this work.

    Co-developed-by: Federico Vaga
    Fixes: fcfacb9f8374 ("doc: move namespaces.rst from kbuild/ to core-api/")
    Signed-off-by: Jonathan Corbet

    Jonathan Corbet
     

03 Oct, 2019

1 commit

  • In order to have the MAINTAINERS file visible in the rendered ReST
    output, this makes some small changes to the existing MAINTAINERS file
    to allow for better machine processing, and adds a new Sphinx directive
    "maintainers-include" to perform the rendering.

    Features include:
    - Per-subsystem reference links: subsystem maintainer entries can be
    trivially linked to both internally and external. For example:
    https://www.kernel.org/doc/html/latest/process/maintainers.html#secure-computing

    - Internally referenced .rst files are linked so they can be followed
    when browsing the resulting rendering. This allows, for example, the
    future addition of maintainer profiles to be automatically linked.

    - Field name expansion: instead of the short fields (e.g. "M", "F",
    "K"), use the indicated inline "full names" for the fields (which are
    marked with "*"s in MAINTAINERS) so that a rendered subsystem entry
    is more human readable. Email lists are additionally comma-separated.
    For example:

    SECURE COMPUTING
    Mail: Kees Cook
    Reviewer: Andy Lutomirski ,
    Will Drewry
    SCM: git git://git.kernel.org/pub/scm/linux/kernel/git/kees/linux.git seccomp
    Status: Supported
    Files: kernel/seccomp.c include/uapi/linux/seccomp.h
    include/linux/seccomp.h tools/testing/selftests/seccomp/*
    tools/testing/selftests/kselftest_harness.h
    userspace-api/seccomp_filter
    Content regex: \bsecure_computing \bTIF_SECCOMP\b

    Signed-off-by: Kees Cook
    Signed-off-by: Jonathan Corbet

    Kees Cook
     

17 Jul, 2019

3 commits


01 Jul, 2019

1 commit

  • The handling of dashes in particular results in confusing
    documentation in a number of instances, since "--" becomes an
    en-dash. This disables SmartyPants wholesale, losing smart quotes
    along with smart dashes.

    With Sphinx 1.6 we could fine-tune the conversion, using the new
    smartquotes and smartquotes_action settings.

    Signed-off-by: Stephen Kitt
    Signed-off-by: Jonathan Corbet

    Stephen Kitt
     

27 Jun, 2019

1 commit


24 May, 2019

1 commit

  • Our version check in Documentation/conf.py never envisioned a world where
    Sphinx moved beyond 1.x. Now that the unthinkable has happened, fix our
    version check to handle higher version numbers correctly.

    Cc: stable@vger.kernel.org
    Signed-off-by: Jonathan Corbet

    Jonathan Corbet
     

25 Oct, 2018

1 commit

  • Pull documentation updates from Jonathan Corbet:
    "This is a fairly typical cycle for documentation. There's some welcome
    readability improvements for the formatted output, some LICENSES
    updates including the addition of the ISC license, the removal of the
    unloved and unmaintained 00-INDEX files, the deprecated APIs document
    from Kees, more MM docs from Mike Rapoport, and the usual pile of typo
    fixes and corrections"

    * tag 'docs-4.20' of git://git.lwn.net/linux: (41 commits)
    docs: Fix typos in histogram.rst
    docs: Introduce deprecated APIs list
    kernel-doc: fix declaration type determination
    doc: fix a typo in adding-syscalls.rst
    docs/admin-guide: memory-hotplug: remove table of contents
    doc: printk-formats: Remove bogus kobject references for device nodes
    Documentation: preempt-locking: Use better example
    dm flakey: Document "error_writes" feature
    docs/completion.txt: Fix a couple of punctuation nits
    LICENSES: Add ISC license text
    LICENSES: Add note to CDDL-1.0 license that it should not be used
    docs/core-api: memory-hotplug: add some details about locking internals
    docs/core-api: rename memory-hotplug-notifier to memory-hotplug
    docs: improve readability for people with poorer eyesight
    yama: clarify ptrace_scope=2 in Yama documentation
    docs/vm: split memory hotplug notifier description to Documentation/core-api
    docs: move memory hotplug description into admin-guide/mm
    doc: Fix acronym "FEKEK" in ecryptfs
    docs: fix some broken documentation references
    iommu: Fix passthrough option documentation
    ...

    Linus Torvalds
     

07 Oct, 2018

1 commit

  • My eyesight is not in good shape, which means that I have difficulty
    reading the online Linux documentation. Specifically, body text is
    oddly small compared to list items and the contrast of various text
    elements is too low for me to be able to see easily.

    Therefore, alter the HTML theme overrides to make the text larger and
    increase the contrast for better visibility, and trust the typeface
    choices of the reader's browser.

    For the PDF output, increase the text size, use a sans-serif typeface
    for sans-serif text, and use a serif typeface for "roman" serif text.

    Signed-off-by: Darrick J. Wong
    Acked-by: Dave Chinner
    Signed-off-by: Jonathan Corbet

    Darrick J. Wong
     

06 Oct, 2018

2 commits


03 Oct, 2018

1 commit


30 Jul, 2018

1 commit


12 Dec, 2017

1 commit


09 Sep, 2017

3 commits

  • Only the media PDF book was requiring adjustbox, in order to
    scale big tables. That worked pretty good with Sphinx versions
    1.4 and 1.5, but Spinx 1.6 changed the way tables are produced,
    by introducing some weird macros before tabulary.
    That causes adjustbox to fail. So, it can't be used anymore,
    and its usage was removed from the media book.

    So, let's remove it from conf.py and sphinx-pre-install.

    Signed-off-by: Mauro Carvalho Chehab
    Signed-off-by: Jonathan Corbet

    Mauro Carvalho Chehab
     
  • Sphinx 1.5 added a new way to change backward colors for note
    boxes, but kept backward compatibility with 1.4. On Sphinx 1.6,
    the old way stopped working, in favor of a new less hackish
    way.

    Unfortunately, this is currently too buggy to be used, and
    the old way doesn't work anymore. So, we have no option but
    to stick with boring notice boxes.

    One example of such bug is the notice that it is inside
    struct v4l2_plane, at the "bytesused" field.

    At least, add a notice about how to use, as maybe some day
    the bug will vanish.

    Signed-off-by: Mauro Carvalho Chehab
    Signed-off-by: Jonathan Corbet

    Mauro Carvalho Chehab
     
  • Only the media book used this extension in the past, but
    it is not required anymore.

    Cleanup patch only.

    Signed-off-by: Mauro Carvalho Chehab
    Signed-off-by: Jonathan Corbet

    Mauro Carvalho Chehab
     

27 Aug, 2017

1 commit


25 Aug, 2017

2 commits

  • according to what Documentation/doc-guide/sphinx.rst says::

    The ReST markups currently used by the Documentation/ files
    are meant to be built with ``Sphinx`` version 1.3 or upper.

    Signed-off-by: Markus Heiser
    Signed-off-by: Jonathan Corbet

    Markus Heiser
     
  • Currently, on Sphinx up to version 1.4, pdf output uses a vertical
    margin of 1 inch. For upper versions, it uses a margin of 0.5 inches.

    That causes both page headers and footers to be very close to the margin
    of the sheet. Not all printers support writing like that.

    Also, there's no reason why the layout for newer versions would be
    different than for previous ones.

    So, standardize it, by always setting to 1 inch.

    Signed-off-by: Mauro Carvalho Chehab
    Signed-off-by: Jonathan Corbet

    Mauro Carvalho Chehab
     

24 Jun, 2017

2 commits

  • Commit 85c21e5c3ee7 (docs-rst: better adjust margins and font size) added a
    \usepackage{geometry} that conflicts with another inclusion deep within the
    dependencies with newer versions of Sphinx, causing the the PDF build to fail
    with a "conflicting parameters" error.

    Detect the Sphinx version, using sphinxsetup for Sphinx versions 1.5 and
    upper.

    Fixes: 85c21e5c3ee74fb75d690c57f7066bae7e2dca55
    [jc: Tweaked logic to exclude 1.5.x for x < 3 ]
    Signed-off-by: Mauro Carvalho Chehab

    Mauro Carvalho Chehab
     
  • Otherwise we get PDF build failures when LaTeX refused to acknowledge the
    existence of \ifthenelse

    Fixes: 41cff161fe99d1c6a773becc2250a1dc3ac035ff
    Cc: Mauro Carvalho Chehab
    Signed-off-by: Jonathan Corbet

    Jonathan Corbet
     

16 May, 2017

11 commits


04 May, 2017

1 commit

  • Pull input subsystem updates from Dmitry Torokhov:

    - a big update from Mauro converting input documentation to ReST format

    - Synaptics PS/2 is now aware of SMBus companion devices, which means
    that we can now use native RMI4 protocol to handle touchpads, instead
    of relying on legacy PS/2 mode.

    - we removed support from BMA180 accelerometer from input devices as it
    is now handled properly by IIO

    - update to TSC2007 to corretcly report pressure

    - other miscellaneous driver fixes.

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: (152 commits)
    Input: ar1021_i2c - use BIT to check for a bit
    Input: twl4030-pwrbutton - use input_set_capability() helper
    Input: twl4030-pwrbutton - use correct device for irq request
    Input: ar1021_i2c - enable touch mode during open
    Input: add uinput documentation
    dt-bindings: input: add bindings document for ar1021_i2c driver
    dt-bindings: input: rotary-encoder: fix typo
    Input: xen-kbdfront - add module parameter for setting resolution
    ARM: pxa/raumfeld: fix compile error in rotary controller resources
    Input: xpad - do not suggest writing to Dominic
    Input: xpad - don't use literal blocks inside footnotes
    Input: xpad - note that usb/devices is now at /sys/kernel/debug/
    Input: docs - freshen up introduction
    Input: docs - split input docs into kernel- and user-facing
    Input: docs - note that MT-A protocol is obsolete
    Input: docs - update joystick documentation a bit
    Input: docs - remove disclaimer/GPL notice
    Input: fix "Game console" heading level in joystick documentation
    Input: rotary-encoder - remove references to platform data from docs
    Input: move documentation for Amiga CD32
    ...

    Linus Torvalds
     

06 Apr, 2017

1 commit


31 Mar, 2017

1 commit