Skip to content

Commit f600c77

Browse files
author
Jonathan Corbet
committed
docs: ignore __counted_by attribute in structure definitions
kernel-doc appeared to ignore __counted_by, but appearances can be deceiving; it caused member names to not be recognized, which manifested as a number of spurious "Excess struct member" warnings. Filter that attribute out and reduce the warning onslaught slightly. Signed-off-by: Jonathan Corbet <corbet@lwn.net>
1 parent 0c3ebff commit f600c77

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

scripts/kernel-doc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1143,6 +1143,7 @@ sub dump_struct($$) {
11431143
# strip attributes
11441144
$members =~ s/\s*$attribute/ /gi;
11451145
$members =~ s/\s*__aligned\s*\([^;]*\)/ /gos;
1146+
$members =~ s/\s*__counted_by\s*\([^;]*\)/ /gos;
11461147
$members =~ s/\s*__packed\s*/ /gos;
11471148
$members =~ s/\s*CRYPTO_MINALIGN_ATTR/ /gos;
11481149
$members =~ s/\s*____cacheline_aligned_in_smp/ /gos;

0 commit comments

Comments
 (0)