From ecb2df0444f10bd21dbdd1220cbe353655cab5cc Mon Sep 17 00:00:00 2001 From: Yong Cong Sin Date: Fri, 24 Nov 2023 11:15:53 +0800 Subject: [PATCH] scripts/checkpatch: add `__unused` to the `$Attribute` list Add `__unused` to the `$Attribute` family along with its `__maybe_unused`, `__always_unused` & `__used` brothers, so that: ```c __unused int ret; ``` is recognized as variable declaration, and doesn't raise `LINE_SPACING` warning in CI. Signed-off-by: Yong Cong Sin --- scripts/checkpatch.pl | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 544fc4ea0e4..fd82a880c1f 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -389,6 +389,7 @@ our $Attribute = qr{ __always_unused| __noreturn| __used| + __unused| __cold| __pure| __noclone|