提交 b8f96a31 编写于 作者: A Andy Whitcroft 提交者: Linus Torvalds

checkpatch: macro complexity checks are meaningless in linker scripts

Exclude vmlinux.lds.h from the macro complexity checks.  They will never
apply sanely here.
Signed-off-by: NAndy Whitcroft <apw@shadowen.org>
Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
上级 d2172eb5
......@@ -1860,7 +1860,8 @@ sub process {
# multi-statement macros should be enclosed in a do while loop, grab the
# first statement and ensure its the whole macro if its not enclosed
# in a known good container
if ($line =~ /^.\s*\#\s*define\s*$Ident(\()?/) {
if ($realfile !~ m@/vmlinux.lds.h$@ &&
$line =~ /^.\s*\#\s*define\s*$Ident(\()?/) {
my $ln = $linenr;
my $cnt = $realcnt;
my ($off, $dstat, $dcond, $rest);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册