The patch titled Subject: checkpatch-update-__attribute__sectionname-quote-removal-v2 has been added to the -mm tree. Its filename is checkpatch-update-__attribute__sectionname-quote-removal-v2.patch This patch should soon appear at https://ozlabs.org/~akpm/mmots/broken-out/checkpatch-update-__attribute__sectionname-quote-removal-v2.patch and later at https://ozlabs.org/~akpm/mmotm/broken-out/checkpatch-update-__attribute__sectionname-quote-removal-v2.patch Before you just go and hit "reply", please: a) Consider who else should be cc'ed b) Prefer to cc a suitable mailing list as well c) Ideally: find the original patch on the mailing list and do a reply-to-all to that, adding suitable additional cc's *** Remember to use Documentation/process/submit-checklist.rst when testing your code *** The -mm tree is included into linux-next and is updated there every 3-4 working days ------------------------------------------------------ From: Joe Perches <joe@xxxxxxxxxxx> Subject: checkpatch-update-__attribute__sectionname-quote-removal-v2 This is a slightly shorter/better patch as it eliminates the separate test below the possible conversions loop. Link: https://lkml.kernel.org/r/58e9d55e933dc8fdc6af489f2ad797fa8eb13e44.camel@xxxxxxxxxxx Cc: Dwaipayan Ray <dwaipayanray1@xxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- scripts/checkpatch.pl | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) --- a/scripts/checkpatch.pl~checkpatch-update-__attribute__sectionname-quote-removal-v2 +++ a/scripts/checkpatch.pl @@ -6241,14 +6241,11 @@ sub process { $fixed[$fixlinenr] =~ s/$remove//; $fixed[$fixlinenr] =~ s/\b__attribute__/$new __attribute__/; $fixed[$fixlinenr] =~ s/\}\Q$new\E/} $new/; + $fixed[$fixlinenr] =~ s/ __attribute__\s*\(\s*\(\s*\)\s*\)//; } } } - if (show_type("PREFER_DEFINED_ATTRIBUTE_MACRO") && $fix) { - $fixed[$fixlinenr] =~ s/ __attribute__\s*\(\s*\(\s*\)\s*\)//; - } - # Check for __attribute__ unused, prefer __always_unused or __maybe_unused if ($attr =~ /^_*unused/) { WARN("PREFER_DEFINED_ATTRIBUTE_MACRO", _ Patches currently in -mm which might be from joe@xxxxxxxxxxx are mm-zswap-make-struct-kernel_param_ops-definitions-const.patch checkpatch-prefer-static-const-declarations.patch checkpatch-allow-fix-removal-of-unnecessary-break-statements.patch checkpatch-update-__attribute__sectionname-quote-removal.patch checkpatch-update-__attribute__sectionname-quote-removal-v2.patch