Commit ef5da59f authored by Randy Dunlap's avatar Randy Dunlap Committed by Linus Torvalds

scripts/kernel-doc: handle struct member __aligned

scripts/kernel-doc erroneously says:

Warning(include/linux/skbuff.h:410): Excess struct/union/enum/typedef member 'cb' description in 'sk_buff'

on this line in struct sk_buff:
	char			cb[48] __aligned(8);

due to treating the last field as the struct member name, so teach
kernel-doc to ignore __aligned(x) in structs.
Signed-off-by: default avatarRandy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 05731b97
...@@ -1424,6 +1424,8 @@ sub dump_struct($$) { ...@@ -1424,6 +1424,8 @@ sub dump_struct($$) {
$nested =~ s/\/\*.*?\*\///gos; $nested =~ s/\/\*.*?\*\///gos;
# strip kmemcheck_bitfield_{begin,end}.*; # strip kmemcheck_bitfield_{begin,end}.*;
$members =~ s/kmemcheck_bitfield_.*?;//gos; $members =~ s/kmemcheck_bitfield_.*?;//gos;
# strip attributes
$members =~ s/__aligned\s*\(\d+\)//gos;
create_parameterlist($members, ';', $file); create_parameterlist($members, ';', $file);
check_sections($file, $declaration_name, "struct", $sectcheck, $struct_actual, $nested); check_sections($file, $declaration_name, "struct", $sectcheck, $struct_actual, $nested);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment