* [PATCH] staging: fwserial: Fix alignment of function parameters
@ 2021-02-18 10:28 Prakash Dubey
2021-02-19 8:13 ` Greg KH
0 siblings, 1 reply; 5+ messages in thread
From: Prakash Dubey @ 2021-02-18 10:28 UTC (permalink / raw)
To: gregkh; +Cc: devel, linux-kernel
This patch fixes the following checkpatch.pl check:
CHECK: Alignment should match open parenthesis
Signed-off-by: Prakash Dubey <prakashdubey1999@gmail.com>
---
drivers/staging/fwserial/fwserial.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/fwserial/fwserial.c b/drivers/staging/fwserial/fwserial.c
index c368082aae1a..a92741b8b6c6 100644
--- a/drivers/staging/fwserial/fwserial.c
+++ b/drivers/staging/fwserial/fwserial.c
@@ -1318,8 +1318,8 @@ static int fwtty_break_ctl(struct tty_struct *tty, int state)
if (state == -1) {
set_bit(STOP_TX, &port->flags);
ret = wait_event_interruptible_timeout(port->wait_tx,
- !test_bit(IN_TX, &port->flags),
- 10);
+ !test_bit(IN_TX, &port->flags),
+ 10);
if (ret == 0 || ret == -ERESTARTSYS) {
clear_bit(STOP_TX, &port->flags);
fwtty_restart_tx(port);
--
2.25.1
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] staging: fwserial: Fix alignment of function parameters
2021-02-18 10:28 [PATCH] staging: fwserial: Fix alignment of function parameters Prakash Dubey
@ 2021-02-19 8:13 ` Greg KH
[not found] ` <CALVjNJP=iXH+u2zUB93UZo+1+Ly0g23k5JtPXFbx=vaO+5-0Gw@mail.gmail.com>
0 siblings, 1 reply; 5+ messages in thread
From: Greg KH @ 2021-02-19 8:13 UTC (permalink / raw)
To: Prakash Dubey; +Cc: devel, linux-kernel
On Thu, Feb 18, 2021 at 03:58:51PM +0530, Prakash Dubey wrote:
> This patch fixes the following checkpatch.pl check:
>
> CHECK: Alignment should match open parenthesis
>
> Signed-off-by: Prakash Dubey <prakashdubey1999@gmail.com>
> ---
> drivers/staging/fwserial/fwserial.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/staging/fwserial/fwserial.c b/drivers/staging/fwserial/fwserial.c
> index c368082aae1a..a92741b8b6c6 100644
> --- a/drivers/staging/fwserial/fwserial.c
> +++ b/drivers/staging/fwserial/fwserial.c
> @@ -1318,8 +1318,8 @@ static int fwtty_break_ctl(struct tty_struct *tty, int state)
> if (state == -1) {
> set_bit(STOP_TX, &port->flags);
> ret = wait_event_interruptible_timeout(port->wait_tx,
> - !test_bit(IN_TX, &port->flags),
> - 10);
> + !test_bit(IN_TX, &port->flags),
> + 10);
Shouldn't you make this line up with the ( above? This indents it a bit
further :(
thanks,
greg k-h
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] staging: fwserial: Fix alignment of function parameters
[not found] ` <CALVjNJP=iXH+u2zUB93UZo+1+Ly0g23k5JtPXFbx=vaO+5-0Gw@mail.gmail.com>
@ 2021-02-19 10:39 ` Greg KH
2021-02-19 11:52 ` Dan Carpenter
0 siblings, 1 reply; 5+ messages in thread
From: Greg KH @ 2021-02-19 10:39 UTC (permalink / raw)
To: 17UCS047_Prakash Dubey; +Cc: devel, linux-kernel
On Fri, Feb 19, 2021 at 03:25:38PM +0530, 17UCS047_Prakash Dubey wrote:
> I was unable to align it right below the opening parenthesis, just by using
> tabs. And when I did that with spaces, the checkpatch yelled at me for
> using spaces. Any suggestions how to do this without using spaces? I am
> using vim, I will try to find a workaround meanwhile.
I have no context here for what you are asking about at all, sorry.
greg k-h
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] staging: fwserial: Fix alignment of function parameters
2021-02-19 10:39 ` Greg KH
@ 2021-02-19 11:52 ` Dan Carpenter
2021-02-19 12:12 ` Prakash Dubey
0 siblings, 1 reply; 5+ messages in thread
From: Dan Carpenter @ 2021-02-19 11:52 UTC (permalink / raw)
To: 17UCS047_Prakash Dubey; +Cc: Greg KH, devel, linux-kernel
On Fri, Feb 19, 2021 at 11:39:27AM +0100, Greg KH wrote:
> On Fri, Feb 19, 2021 at 03:25:38PM +0530, 17UCS047_Prakash Dubey wrote:
> > I was unable to align it right below the opening parenthesis, just by using
> > tabs. And when I did that with spaces, the checkpatch yelled at me for
> > using spaces. Any suggestions how to do this without using spaces? I am
> > using vim, I will try to find a workaround meanwhile.
>
Your comment hasn't made it to the list yet. Sometimes there is a delay
or maybe it was blocked for some reason (html email?).
You are allowed to use spaces but you can't have 8 consecutive spaces
and spaces are not allowed before a tab character. The way to align it
is:
ret = wait_event_interruptible_timeout(port->wait_tx,
!test_bit(IN_TX, &port->flags),
10);
[tab x6][space x7]!test_bit(IN_TX, &port->flags)
regards,
dan carpenter
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] staging: fwserial: Fix alignment of function parameters
2021-02-19 11:52 ` Dan Carpenter
@ 2021-02-19 12:12 ` Prakash Dubey
0 siblings, 0 replies; 5+ messages in thread
From: Prakash Dubey @ 2021-02-19 12:12 UTC (permalink / raw)
To: Dan Carpenter; +Cc: gregkh, devel, linux-kernel
On Fri, Feb 19, 2021 at 02:52:21PM +0300, Dan Carpenter wrote:
> On Fri, Feb 19, 2021 at 11:39:27AM +0100, Greg KH wrote:
> > On Fri, Feb 19, 2021 at 03:25:38PM +0530, 17UCS047_Prakash Dubey wrote:
> > > I was unable to align it right below the opening parenthesis, just by using
> > > tabs. And when I did that with spaces, the checkpatch yelled at me for
> > > using spaces. Any suggestions how to do this without using spaces? I am
> > > using vim, I will try to find a workaround meanwhile.
> >
>
> Your comment hasn't made it to the list yet. Sometimes there is a delay
> or maybe it was blocked for some reason (html email?).
>
> You are allowed to use spaces but you can't have 8 consecutive spaces
> and spaces are not allowed before a tab character. The way to align it
> is:
>
> ret = wait_event_interruptible_timeout(port->wait_tx,
> !test_bit(IN_TX, &port->flags),
> 10);
>
> [tab x6][space x7]!test_bit(IN_TX, &port->flags)
>
> regards,
> dan carpenter
Thank you Dan, I figured that out after a few failed attempts to align properly.
I was replying through Gmail web client, as I am new to mutt. I am getting the hang of it.
--
Regards,
Prakash
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2021-02-19 12:13 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-18 10:28 [PATCH] staging: fwserial: Fix alignment of function parameters Prakash Dubey
2021-02-19 8:13 ` Greg KH
[not found] ` <CALVjNJP=iXH+u2zUB93UZo+1+Ly0g23k5JtPXFbx=vaO+5-0Gw@mail.gmail.com>
2021-02-19 10:39 ` Greg KH
2021-02-19 11:52 ` Dan Carpenter
2021-02-19 12:12 ` Prakash Dubey
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).