Skip to content

Commit

Permalink
scripts/find-unused-docs: Fix massive false positives
Browse files Browse the repository at this point in the history
scripts/find-unused-docs.sh invokes scripts/kernel-doc to find out if a
source file contains kerneldoc or not.

However, as it passes the no longer supported "-text" option to
scripts/kernel-doc, the latter prints out its help text, causing all
files to be considered containing kerneldoc.

Get rid of these false positives by removing the no longer supported
"-text" option from the scripts/kernel-doc invocation.

Cc: [email protected]  # 4.16+
Fixes: b051426 ("scripts: kernel-doc: get rid of unused output formats")
Signed-off-by: Geert Uytterhoeven <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Jonathan Corbet <[email protected]>
  • Loading branch information
geertu authored and Jonathan Corbet committed Jan 27, 2020
1 parent 06b9c26 commit 1630146
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/find-unused-docs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ for file in `find $1 -name '*.c'`; do
if [[ ${FILES_INCLUDED[$file]+_} ]]; then
continue;
fi
str=$(scripts/kernel-doc -text -export "$file" 2>/dev/null)
str=$(scripts/kernel-doc -export "$file" 2>/dev/null)
if [[ -n "$str" ]]; then
echo "$file"
fi
Expand Down

0 comments on commit 1630146

Please sign in to comment.