public inbox for linux-doc@vger.kernel.org
 help / color / mirror / Atom feed
From: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
To: Jonathan Corbet <corbet@lwn.net>,
	Mauro Carvalho Chehab <mchehab@kernel.org>
Cc: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>,
	linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org,
	Randy Dunlap <rdunlap@infradead.org>,
	Shuah Khan <skhan@linuxfoundation.org>
Subject: [PATCH 00/11] kernel-doc improvements
Date: Thu,  5 Mar 2026 16:16:07 +0100	[thread overview]
Message-ID: <cover.1772722474.git.mchehab+huawei@kernel.org> (raw)

Hi Jon,

This series contains some patches that were submitted originally
on this /41 patch series:

	https://patchew.org/linux/cover.1769867953.git.mchehab+huawei@kernel.org/fc6723d13b96db014eaf0f14354d8821ea2085b8.1769867954.git.mchehab+huawei@kernel.org/

It consists on two parts:

- the first two patches are meant to better allow using kernel-doc
  inside QEMU and to improve KernelFiles ABI, which will be used
  there. I'm placing it here just to avoid on extra PR with just
  two patches on it.

- the second part do some improvements on how man pages are produced.

The second part is related to man pages. It is focused mostly on
TH, but, as a side effect, it also change the name of man pages
generated from DOC kernel-doc annotations.

The rationale is that modern troff/man page specs say that .TH has
up to 5 arguments,, as defined at [1]:

       .TH topic section [footer-middle] [footer-inside] [header-middle]

[1] https://man7.org/linux/man-pages/man7/groff_man_style.7.html

Right now, Kernel uses 6 arguments, probably due to some legacy
man page definitions.

After double checking, this is typically used like this:

	.TH "{name}" {section} "{date}" "{modulename}" "{manual}"

Right now, man pages generation are messing up on how it encodes
each position at .TH, depending on the type of object it emits.

After this series, the definition is more consistent and file
output is better named.

It also fixes two issues at sphinx-build-wrapper related to how
it generate files names from the .TH header.

This series hould not affect HTML documentation. It only changes
man pages.

As the names are now better defined, it also prevents some
file name duplication.

Mauro Carvalho Chehab (11):
  docs: kdoc_files: allows the caller to use a different xforms class
  docs: kdoc_files: document KernelFiles() ABI
  docs: sphinx-build-wrapper: better handle troff .TH markups
  docs: sphinx-build-wrapper: don't allow "/" on file names
  docs: kdoc_output: use a method to emit the .TH header
  docs: kdoc_output: remove extra attribute on man .TH headers
  docs: kdoc_output: use a single manual for everything
  docs: kdoc_output: don't use a different modulename for functions
  docs: kdoc_output: use a more standard order for .TH on man pages
  docs: kdoc_output: describe the class init parameters
  docs: kdoc_output: pick a better default for modulename

 tools/docs/kernel-doc                |  1 -
 tools/docs/sphinx-build-wrapper      |  9 ++--
 tools/lib/python/kdoc/kdoc_files.py  | 53 ++++++++++++++++++--
 tools/lib/python/kdoc/kdoc_output.py | 73 +++++++++++++++++++++++-----
 4 files changed, 115 insertions(+), 21 deletions(-)

-- 
2.52.0


             reply	other threads:[~2026-03-05 15:16 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-05 15:16 Mauro Carvalho Chehab [this message]
2026-03-05 15:16 ` [PATCH 01/11] docs: kdoc_files: allows the caller to use a different xforms class Mauro Carvalho Chehab
2026-03-05 15:16 ` [PATCH 02/11] docs: kdoc_files: document KernelFiles() ABI Mauro Carvalho Chehab
2026-03-05 15:16 ` [PATCH 03/11] docs: sphinx-build-wrapper: better handle troff .TH markups Mauro Carvalho Chehab
2026-03-05 15:16 ` [PATCH 04/11] docs: sphinx-build-wrapper: don't allow "/" on file names Mauro Carvalho Chehab
2026-03-05 15:16 ` [PATCH 05/11] docs: kdoc_output: use a method to emit the .TH header Mauro Carvalho Chehab
2026-03-05 15:16 ` [PATCH 06/11] docs: kdoc_output: remove extra attribute on man .TH headers Mauro Carvalho Chehab
2026-03-05 15:16 ` [PATCH 07/11] docs: kdoc_output: use a single manual for everything Mauro Carvalho Chehab
2026-03-05 15:16 ` [PATCH 08/11] docs: kdoc_output: don't use a different modulename for functions Mauro Carvalho Chehab
2026-03-05 15:16 ` [PATCH 09/11] docs: kdoc_output: use a more standard order for .TH on man pages Mauro Carvalho Chehab
2026-03-05 15:16 ` [PATCH 10/11] docs: kdoc_output: describe the class init parameters Mauro Carvalho Chehab
2026-03-05 15:16 ` [PATCH 11/11] docs: kdoc_output: pick a better default for modulename Mauro Carvalho Chehab
2026-03-05 15:32 ` [PATCH 00/11] kernel-doc improvements Mauro Carvalho Chehab

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=cover.1772722474.git.mchehab+huawei@kernel.org \
    --to=mchehab+huawei@kernel.org \
    --cc=corbet@lwn.net \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mchehab@kernel.org \
    --cc=rdunlap@infradead.org \
    --cc=skhan@linuxfoundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox