Skip to content

Commit 0407f37

Browse files
mchehabJonathan Corbet
authored andcommitted
docs: conf.py: get rid of the now unused kerneldoc_bin env var
In the past, this contained the location of the binary file to parse kernel-doc. Nowadays, it is used only for debugging purposes, inside kerneldoc.py extension. Move it to sphinx/kerneldoc.py, to avoid needing to handle with it on several places. Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Message-ID: <c0fa9f561c1dd4370f9096de4195a9214763c51c.1768823489.git.mchehab+huawei@kernel.org>
1 parent 35c0f97 commit 0407f37

2 files changed

Lines changed: 5 additions & 6 deletions

File tree

Documentation/conf.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -582,10 +582,6 @@ def get_cline_version():
582582
("kernel-documentation", "Kernel", "Kernel", "J. Random Bozo"),
583583
]
584584

585-
# kernel-doc extension configuration for running Sphinx directly (e.g. by Read
586-
# the Docs). In a normal build, these are supplied from the Makefile via command
587-
# line arguments.
588-
kerneldoc_bin = "../tools/docs/kernel-doc" # Not used now
589585
kerneldoc_srctree = ".."
590586

591587
def setup(app):

Documentation/sphinx/kerneldoc.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,10 @@
4747
from kdoc.kdoc_files import KernelFiles
4848
from kdoc.kdoc_output import RestFormat
4949

50+
# Used when verbose is active to show how to reproduce kernel-doc
51+
# issues via command line
52+
kerneldoc_bin = "tools/docs/kernel-doc"
53+
5054
__version__ = '1.0'
5155
kfiles = None
5256
logger = logging.getLogger(__name__)
@@ -95,7 +99,7 @@ class KernelDocDirective(Directive):
9599
def handle_args(self):
96100

97101
env = self.state.document.settings.env
98-
cmd = [env.config.kerneldoc_bin, '-rst', '-enable-lineno']
102+
cmd = [kerneldoc_bin, '-rst', '-enable-lineno']
99103

100104
filename = env.config.kerneldoc_srctree + '/' + self.arguments[0]
101105

@@ -257,7 +261,6 @@ def setup_kfiles(app):
257261

258262

259263
def setup(app):
260-
app.add_config_value('kerneldoc_bin', None, 'env')
261264
app.add_config_value('kerneldoc_srctree', None, 'env')
262265
app.add_config_value('kerneldoc_verbosity', 1, 'env')
263266

0 commit comments

Comments
 (0)