Find a file
Pierre-Louis Bossart 2c12c8103d scripts/kernel-doc: optionally treat warnings as errors
The kbuild bot recently added the W=1 option, which triggered
documentation cleanups to squelch hundreds of kernel-doc warnings.

To make sure new kernel contributions don't add regressions to
kernel-doc descriptors, this patch suggests an option to treat
warnings as errors in CI/automated tests.

A -Werror command-line option is added to the kernel-doc script. When
this option is set, the script will return the number of warnings
found. The caller can then treat this positive return value as an
error and stop the build.

Using this command line option is however not straightforward when the
kernel-doc script is called from other scripts. To align with typical
kernel compilation or documentation generation, the Werror option is
also set by checking the KCFLAGS environment variable, or if
KDOC_WERROR is defined, as in the following examples:

KCFLAGS="-Wall -Werror" make W=1 sound/
KCFLAGS="-Wall -Werror" make W=1 drivers/soundwire/
KDOC_WERROR=1 make htmldocs

Note that in the last example the documentation build does not stop,
only an additional log is provided.

Credits to Randy Dunlap for suggesting the use of environment variables.

Suggested-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20200728162040.92467-1-pierre-louis.bossart@linux.intel.com
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
2020-07-31 11:11:17 -06:00
arch docs: move other kAPI documents to core-api 2020-06-26 11:33:42 -06:00
block Kbuild updates for v5.8 (2nd) 2020-06-13 13:29:16 -07:00
certs
crypto docs: crypto: convert asymmetric-keys.txt to ReST 2020-06-19 14:03:46 -06:00
Documentation docs: ia64: correct typo 2020-07-31 11:09:09 -06:00
drivers Replace HTTP links with HTTPS ones: LVM 2020-07-05 14:28:27 -06:00
fs Replace HTTP links with HTTPS ones: CIFS 2020-07-05 14:23:38 -06:00
include docs: fix references for DMA*.txt files 2020-06-26 10:01:32 -06:00
init docs: move nommu-mmap.txt to admin-guide and rename to ReST 2020-06-26 11:33:35 -06:00
ipc mmap locking API: use coccinelle to convert mmap_sem rwsem call sites 2020-06-09 09:39:14 -07:00
kernel docs: fix references for DMA*.txt files 2020-06-26 10:01:32 -06:00
lib docs: move remaining stuff under Documentation/*.txt to Documentation/staging 2020-06-19 14:17:05 -06:00
LICENSES
mm docs: move nommu-mmap.txt to admin-guide and rename to ReST 2020-06-26 11:33:35 -06:00
net net: dev: add a missing kernel-doc annotation 2020-06-26 10:00:20 -06:00
samples docs: move remaining stuff under Documentation/*.txt to Documentation/staging 2020-06-19 14:17:05 -06:00
scripts scripts/kernel-doc: optionally treat warnings as errors 2020-07-31 11:11:17 -06:00
security Add additional LSM hooks for SafeSetID 2020-06-14 11:39:31 -07:00
sound Kbuild updates for v5.8 (2nd) 2020-06-13 13:29:16 -07:00
tools selftests/vm/keys: fix a broken reference at protection_keys.c 2020-06-26 10:01:12 -06:00
usr
virt MIPS: 2020-06-12 11:05:52 -07:00
.clang-format
.cocciconfig
.get_maintainer.ignore
.gitattributes
.gitignore
.mailmap mailmap: add entry for <alobakin@marvell.com> 2020-07-31 11:07:42 -06:00
COPYING
CREDITS CREDITS: Replace HTTP links with HTTPS ones 2020-07-23 14:53:58 -06:00
Kbuild
Kconfig
MAINTAINERS MAINTAINERS: adjust kprobes.rst entry to new location 2020-07-27 16:22:17 -06:00
Makefile Linux 5.8-rc1 2020-06-14 12:45:04 -07:00
README

Linux kernel
============

There are several guides for kernel developers and users. These guides can
be rendered in a number of formats, like HTML and PDF. Please read
Documentation/admin-guide/README.rst first.

In order to build the documentation, use ``make htmldocs`` or
``make pdfdocs``.  The formatted documentation can also be read online at:

    https://www.kernel.org/doc/html/latest/

There are various text files in the Documentation/ subdirectory,
several of them using the Restructured Text markup notation.

Please read the Documentation/process/changes.rst file, as it contains the
requirements for building and running the kernel, and information about
the problems which may result by upgrading your kernel.