]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commit - scripts/kernel-doc
kernel-doc: support printing exported and non-exported symbols
authorJani Nikula <jani.nikula@intel.com>
Thu, 21 Jan 2016 11:05:22 +0000 (13:05 +0200)
committerJani Nikula <jani.nikula@intel.com>
Mon, 30 May 2016 10:38:50 +0000 (13:38 +0300)
commit86ae2e38d40ed6bf7c907d126053e6f4b1dc5b6e
tree190122e6829a2de86b5bffcf9515887ced329fb3
parent5e64fa9c441ff273f39527f4014d3c3e724d321a
kernel-doc: support printing exported and non-exported symbols

Currently we use docproc to figure out which symbols are exported, and
then docproc calls kernel-doc on specific functions, to get
documentation on exported functions. According to git blame and docproc
comments, this is due to historical reasons, as functions and their
corresponding EXPORT_SYMBOL* may have been in different files. However
for more than ten years the recommendation in CodingStyle has been to
place the EXPORT_SYMBOL* immediately after the closing function brace
line.

Additionally, the kernel-doc comments for functions are generally placed
above the function definition in the .c files (i.e. where the
EXPORT_SYMBOL* is) rather than above the declaration in the .h
files. There are some exceptions to this, but AFAICT none of these are
included in DocBook documentation using the "!E" docproc directive.

Therefore, assuming the EXPORT_SYMBOL* and kernel-doc are with the
function definition, kernel-doc can extract the exported vs. not
information by making two passes on the input file. Add support for that
via the new -export and -internal parameters.

Signed-off-by: Jani Nikula <jani.nikula@intel.com>
scripts/kernel-doc