staging: mt7621-mmc: Fix line size exceeding 80 columns.
Subsystems (2)
PATCH 1/1 staging: mt7621-mmc: Fix line size exceeding 80 columns.
This patch fixes the checkpatch.pl warning:
WARNING: line over 80 characters
--- drivers/staging/mt7621-mmc/dbg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/mt7621-mmc/dbg.c +1 -1
@@ -229,7 +229,7 @@ static int msdc_debug_proc_read(struct seq_file *s, void *p) }static ssize_t msdc_debug_proc_write (struct file *file, -const char __user *buf,size_t count,loff_t *data) +const char __user *buf,size_t count,loff_t *data) {int ret;
Signature · 1 line
2.11.0
Quoted 14 lines · Sankalp Negi
This patch fixes the checkpatch.pl warning:
WARNING: line over 80 characters
Signed-off-by Sankalp Negi <[email protected]>--- drivers/staging/mt7621-mmc/dbg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/staging/mt7621-mmc/dbg.c +0
-0
drivers/staging/mt7621-mmc/dbg.c static int msdc_debug_proc_read(struct seq_file *s, void *p) · line 232
Quoted 5 lines
drivers/staging/mt7621-mmc/dbg.c +1
-1@@ -229,7 +229,7 @@ static int msdc_debug_proc_read(struct seq_file *s, void *p) }static ssize_t msdc_debug_proc_write (struct file *file, -const char __user *buf,size_t count,loff_t *data) +const char __user *buf,size_t count,loff_t *data)
Thanks, but .... not like this please.
The code inside () should never be indented before the '(' unless the '(' is at the end of a line.
So you could make it
static ssize_t msdc_debug_proc_write(struct file *file, const char __user *buf,
size_t count, loff_t *data)
or
static ssize_t
msdc_debug_proc_write(struct file *file, const char __user *buf, size_t count,
loff_t *data)
or even
static ssize_t msdc_debug_proc_write(
struct file *file, const char __user *buf, size_t count, loff_t *data)
(though I don't think checkpatch will like that).
But neither the original or your new version are indented properly. Try to do more than just remove the warnings - try to make the code beautiful!
Thanks,
NeilBrown
Quoted 5 lines
drivers/staging/mt7621-mmc/dbg.c +0
-0{int ret;Signature · 1 line
2.11.0
PATCH v2 1/1 staging: mt7621-mmc: Fix line size exceeding 80 columns
This patch fixes checkpatch.pl warning and check:
WARNING: line over 80 characters
CHECK: Alignment should match open parenthesis
---
Changes in v2:
- Made alignments to match open parenthesis.
--- drivers/staging/mt7621-mmc/dbg.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/staging/mt7621-mmc/dbg.c +2 -1
@@ -229,7 +229,8 @@ static int msdc_debug_proc_read(struct seq_file *s, void *p) }static ssize_t msdc_debug_proc_write (struct file *file, -const char __user *buf,size_t count,loff_t *data) +const char __user *buf, +size_t count,loff_t *data) {int ret;
Signature · 1 line
2.11.0
Re: [PATCH v2] staging: mt7621-mmc: Fix line size exceeding 80 columns
Quoted 5 lines · Sankalp Negi
This patch fixes checkpatch.pl warning and check:
WARNING: line over 80 characters
CHECK: Alignment should match open parenthesisSigned-off-by Sankalp Negi <[email protected]>
Thanks,
NeilBrown
Quoted 23 lines
---
Changes in v2:
- Made alignments to match open parenthesis.--- drivers/staging/mt7621-mmc/dbg.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)drivers/staging/mt7621-mmc/dbg.c +2
-1@@ -229,7 +229,8 @@ static int msdc_debug_proc_read(struct seq_file *s, void *p) }static ssize_t msdc_debug_proc_write (struct file *file, -const char __user *buf,size_t count,loff_t *data) +const char __user *buf, +size_t count,loff_t *data) {int ret;Signature · 1 line
2.11.0