summaryrefslogtreecommitdiff
path: root/tools/lib/python/kdoc/kdoc_apispec.py
AgeCommit message (Collapse)Author
6 dayskernel/api: enable kerneldoc-based API specificationsSasha Levin
Add support for extracting API specifications from kernel-doc comments and generating C macro invocations for the kernel API specification framework. Changes include: - New kdoc_apispec.py module for generating API spec macros - Updates to tools/docs/kernel-doc to support the -apispec output format - Build system integration in Makefile.build - Support for API-specific sections in kernel-doc comments kernel-doc recognises the KAPI sections only in -apispec mode, so its other output formats are unchanged. With CONFIG_KAPI_SPEC=y, Kbuild generates <file>.apispec.h for each built source that has a contexts: or context-flags: line plus another KAPI section, and force-includes it when compiling that source. Assisted-by: LLM Signed-off-by: Sasha Levin <sashal@kernel.org>