aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Documentation/sphinx
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab+huawei@kernel.org>2020-09-29 11:32:18 +0200
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>2020-10-15 07:49:38 +0200
commit2791f47d26d1e49a747a0a1aa2d694e6aab447ab (patch)
tree9e9b648665bf469c216666bfdafbf27997836c4f /Documentation/sphinx
parentdocs: kerneldoc.py: append the name of the parsed doc file (diff)
downloadwireguard-linux-2791f47d26d1e49a747a0a1aa2d694e6aab447ab.tar.xz
wireguard-linux-2791f47d26d1e49a747a0a1aa2d694e6aab447ab.zip
docs: kerneldoc.py: add support for kerneldoc -nosymbol
Currently, there's no way to exclude identifiers from a kernel-doc markup. Add support for it. Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Diffstat (limited to 'Documentation/sphinx')
-rw-r--r--Documentation/sphinx/kerneldoc.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/Documentation/sphinx/kerneldoc.py b/Documentation/sphinx/kerneldoc.py
index a3a5427130da..e9857ab904f1 100644
--- a/Documentation/sphinx/kerneldoc.py
+++ b/Documentation/sphinx/kerneldoc.py
@@ -62,6 +62,7 @@ class KernelDocDirective(Directive):
'export': directives.unchanged,
'internal': directives.unchanged,
'identifiers': directives.unchanged,
+ 'no-identifiers': directives.unchanged,
'functions': directives.unchanged,
}
has_content = False
@@ -104,6 +105,12 @@ class KernelDocDirective(Directive):
else:
cmd += ['-no-doc-sections']
+ if 'no-identifiers' in self.options:
+ no_identifiers = self.options.get('no-identifiers').split()
+ if no_identifiers:
+ for i in no_identifiers:
+ cmd += ['-nosymbol', i]
+
for pattern in export_file_patterns:
for f in glob.glob(env.config.kerneldoc_srctree + '/' + pattern):
env.note_dependency(os.path.abspath(f))