diff options
-rwxr-xr-x | scripts/checkpatch.pl | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index d1fd466043ef..7a2f54a0bd35 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl | |||
@@ -3348,18 +3348,20 @@ sub process { | |||
3348 | if ($line =~ /^.\s*sema_init.+,\W?0\W?\)/) { | 3348 | if ($line =~ /^.\s*sema_init.+,\W?0\W?\)/) { |
3349 | WARN("CONSIDER_COMPLETION", | 3349 | WARN("CONSIDER_COMPLETION", |
3350 | "consider using a completion\n" . $herecurr); | 3350 | "consider using a completion\n" . $herecurr); |
3351 | |||
3352 | } | 3351 | } |
3352 | |||
3353 | # recommend kstrto* over simple_strto* and strict_strto* | 3353 | # recommend kstrto* over simple_strto* and strict_strto* |
3354 | if ($line =~ /\b((simple|strict)_(strto(l|ll|ul|ull)))\s*\(/) { | 3354 | if ($line =~ /\b((simple|strict)_(strto(l|ll|ul|ull)))\s*\(/) { |
3355 | WARN("CONSIDER_KSTRTO", | 3355 | WARN("CONSIDER_KSTRTO", |
3356 | "$1 is obsolete, use k$3 instead\n" . $herecurr); | 3356 | "$1 is obsolete, use k$3 instead\n" . $herecurr); |
3357 | } | 3357 | } |
3358 | |||
3358 | # check for __initcall(), use device_initcall() explicitly please | 3359 | # check for __initcall(), use device_initcall() explicitly please |
3359 | if ($line =~ /^.\s*__initcall\s*\(/) { | 3360 | if ($line =~ /^.\s*__initcall\s*\(/) { |
3360 | WARN("USE_DEVICE_INITCALL", | 3361 | WARN("USE_DEVICE_INITCALL", |
3361 | "please use device_initcall() instead of __initcall()\n" . $herecurr); | 3362 | "please use device_initcall() instead of __initcall()\n" . $herecurr); |
3362 | } | 3363 | } |
3364 | |||
3363 | # check for various ops structs, ensure they are const. | 3365 | # check for various ops structs, ensure they are const. |
3364 | my $struct_ops = qr{acpi_dock_ops| | 3366 | my $struct_ops = qr{acpi_dock_ops| |
3365 | address_space_operations| | 3367 | address_space_operations| |