staging: greybus: Alignment warning
PATCH 1/1 staging: greybus: Alignment warning
Correct the alignment of the parameters to match the open parenthesis.
Reported by checkpatch:
CHECK: Alignment should match open parenthesis
--- drivers/staging/greybus/camera.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/greybus/camera.c +2 -2
@@ -1165,8 +1165,8 @@ static int gb_camera_debugfs_init(struct gb_camera *gcam) gcam->debugfs.buffers[i].length =0 ;debugfs_create_file_aux (entry->name, entry->mask, - gcam->debugfs.root, gcam, entry, - &gb_camera_debugfs_ops); + gcam->debugfs.root, gcam, entry, + &gb_camera_debugfs_ops); }return 0 ;
Signature · 1 line
2.43.0
Quoted 5 lines · Erick Karanja
Correct the alignment of the parameters to match the open parenthesis.
Reported by checkpatch:
CHECK: Alignment should match open parenthesis
I think this change is OK. However you'll notice that checkpatch.pl has three categories of issues that get reported: errors, warnings, and checks. These are in decreasing order of severity.
Alignment issues like this are just "checks", which means they are minor nits that are often not considered a "real" problem. In many cases, white space variances like this are done intentionally, to make the code more readable, or sometimes simply because the code that surrounds it used a different convention for alignment (some people simply align to an even number of tabs, for example).
In this case, the change doesn't make the "look" of the code any worse, and doesn't reduce readability. It furthermore gets rid of spaces after a tab that do *not* lead to the suggested alignment. It probably isn't a necessary change, but I think it's reasonable.
I write all this to explain that these sorts of changes are in many cases rejected.
I'll leave it to Greg to accept this, or offer a second opinion.
Quoted 21 lines
Signed-off-by Erick Karanja <[email protected]>--- drivers/staging/greybus/camera.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)drivers/staging/greybus/camera.c +2
-2@@ -1165,8 +1165,8 @@ static int gb_camera_debugfs_init(struct gb_camera *gcam) gcam->debugfs.buffers[i].length =0 ;debugfs_create_file_aux (entry->name, entry->mask, - gcam->debugfs.root, gcam, entry, - &gb_camera_debugfs_ops); + gcam->debugfs.root, gcam, entry, + &gb_camera_debugfs_ops); }return 0 ;