docs: cdomain.py: add support for a new Sphinx 3.1+ tag
authorMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Thu, 24 Sep 2020 09:32:38 +0000 (11:32 +0200)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Thu, 15 Oct 2020 05:49:37 +0000 (07:49 +0200)
commit71e552aebf260239463d348ecb75b972bee0804b
treecb1b2ddf622a87b5cf9517249bef46b76cb59921
parent6e9e415854c15dbf920481eb1d245988e405bbc0
docs: cdomain.py: add support for a new Sphinx 3.1+ tag

Since Sphinx 3.0, the C domain code was rewritten, but only
after version 3.1 it got support for setting namespaces on
C domains, with is something that it is required, in order to
document system calls, like ioctl() and others.

As part of changing the documentation subsystem to properly
build with Sphinx 3.1+, add support for such new tag:

.. c:namespace::"

Such tag optionally replaces the optional "name" tag for functions,
setting a single namespace domain for all C references found
at the file.

With that, it should be possible to convert existing
documentation to be compatible with both Sphinx 1.x/2.x and
3.1+.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Documentation/sphinx/cdomain.py