linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1] kernel: usb: Adds space, removes trailing whitespace and fixes pointer declaration.
@ 2023-08-15 20:48 Atul Kumar Pant
  2023-08-15 21:04 ` Greg KH
  0 siblings, 1 reply; 3+ messages in thread
From: Atul Kumar Pant @ 2023-08-15 20:48 UTC (permalink / raw)
  To: oneukum, gregkh; +Cc: Atul Kumar Pant, linux-usb, linux-kernel, shuah

This patch fixes following checkpatch.pl issue:
ERROR: space required before the open parenthesis '('
ERROR: trailing whitespace
ERROR: space required after that ','
ERROR: "foo * bar" should be "foo *bar"

Signed-off-by: Atul Kumar Pant <atulpant.linux@gmail.com>
---
 drivers/usb/class/cdc-acm.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/usb/class/cdc-acm.c b/drivers/usb/class/cdc-acm.c
index 11da5fb284d0..638c9cdaa041 100644
--- a/drivers/usb/class/cdc-acm.c
+++ b/drivers/usb/class/cdc-acm.c
@@ -203,7 +203,7 @@ static int acm_wb_is_avail(struct acm *acm)
 	n = ACM_NW;
 	spin_lock_irqsave(&acm->write_lock, flags);
 	for (i = 0; i < ACM_NW; i++)
-		if(acm->wb[i].use)
+		if (acm->wb[i].use)
 			n--;
 	spin_unlock_irqrestore(&acm->write_lock, flags);
 	return n;
@@ -1006,7 +1006,7 @@ static int wait_serial_change(struct acm *acm, unsigned long arg)
 		}
 	} while (!rv);
 
-	
+
 
 	return rv;
 }
@@ -1257,7 +1257,7 @@ static int acm_probe(struct usb_interface *intf,
 
 	if (control_interface == data_interface) {
 		/* some broken devices designed for windows work this way */
-		dev_warn(&intf->dev,"Control and data interfaces are not separated!\n");
+		dev_warn(&intf->dev, "Control and data interfaces are not separated!\n");
 		combined_interfaces = 1;
 		/* a popular other OS doesn't use it */
 		quirks |= NO_CAP_LINE;
@@ -1428,7 +1428,7 @@ static int acm_probe(struct usb_interface *intf,
 		goto err_free_write_urbs;
 
 	if (h.usb_cdc_country_functional_desc) { /* export the country data */
-		struct usb_cdc_country_functional_desc * cfd =
+		struct usb_cdc_country_functional_desc *cfd =
 					h.usb_cdc_country_functional_desc;
 
 		acm->country_codes = kmalloc(cfd->bLength - 4, GFP_KERNEL);
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH v1] kernel: usb: Adds space, removes trailing whitespace and fixes pointer declaration.
  2023-08-15 20:48 [PATCH v1] kernel: usb: Adds space, removes trailing whitespace and fixes pointer declaration Atul Kumar Pant
@ 2023-08-15 21:04 ` Greg KH
  2023-08-16  2:48   ` Atul Kumar Pant
  0 siblings, 1 reply; 3+ messages in thread
From: Greg KH @ 2023-08-15 21:04 UTC (permalink / raw)
  To: Atul Kumar Pant; +Cc: oneukum, linux-usb, linux-kernel, shuah

On Wed, Aug 16, 2023 at 02:18:41AM +0530, Atul Kumar Pant wrote:
> This patch fixes following checkpatch.pl issue:
> ERROR: space required before the open parenthesis '('
> ERROR: trailing whitespace
> ERROR: space required after that ','
> ERROR: "foo * bar" should be "foo *bar"
> 
> Signed-off-by: Atul Kumar Pant <atulpant.linux@gmail.com>
> ---
>  drivers/usb/class/cdc-acm.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/usb/class/cdc-acm.c b/drivers/usb/class/cdc-acm.c
> index 11da5fb284d0..638c9cdaa041 100644
> --- a/drivers/usb/class/cdc-acm.c
> +++ b/drivers/usb/class/cdc-acm.c
> @@ -203,7 +203,7 @@ static int acm_wb_is_avail(struct acm *acm)
>  	n = ACM_NW;
>  	spin_lock_irqsave(&acm->write_lock, flags);
>  	for (i = 0; i < ACM_NW; i++)
> -		if(acm->wb[i].use)
> +		if (acm->wb[i].use)
>  			n--;
>  	spin_unlock_irqrestore(&acm->write_lock, flags);
>  	return n;
> @@ -1006,7 +1006,7 @@ static int wait_serial_change(struct acm *acm, unsigned long arg)
>  		}
>  	} while (!rv);
>  
> -	
> +
>  
>  	return rv;
>  }
> @@ -1257,7 +1257,7 @@ static int acm_probe(struct usb_interface *intf,
>  
>  	if (control_interface == data_interface) {
>  		/* some broken devices designed for windows work this way */
> -		dev_warn(&intf->dev,"Control and data interfaces are not separated!\n");
> +		dev_warn(&intf->dev, "Control and data interfaces are not separated!\n");
>  		combined_interfaces = 1;
>  		/* a popular other OS doesn't use it */
>  		quirks |= NO_CAP_LINE;
> @@ -1428,7 +1428,7 @@ static int acm_probe(struct usb_interface *intf,
>  		goto err_free_write_urbs;
>  
>  	if (h.usb_cdc_country_functional_desc) { /* export the country data */
> -		struct usb_cdc_country_functional_desc * cfd =
> +		struct usb_cdc_country_functional_desc *cfd =
>  					h.usb_cdc_country_functional_desc;
>  
>  		acm->country_codes = kmalloc(cfd->bLength - 4, GFP_KERNEL);
> -- 
> 2.25.1
> 

Hi,

This is the friendly patch-bot of Greg Kroah-Hartman.  You have sent him
a patch that has triggered this response.  He used to manually respond
to these common problems, but in order to save his sanity (he kept
writing the same thing over and over, yet to different people), I was
created.  Hopefully you will not take offence and will fix the problem
in your patch and resubmit it so that it can be accepted into the Linux
kernel tree.

You are receiving this message because of the following common error(s)
as indicated below:

- Your patch did many different things all at once, making it difficult
  to review.  All Linux kernel patches need to only do one thing at a
  time.  If you need to do multiple things (such as clean up all coding
  style issues in a file/driver), do it in a sequence of patches, each
  one doing only one thing.  This will make it easier to review the
  patches to ensure that they are correct, and to help alleviate any
  merge issues that larger patches can cause.

If you wish to discuss this problem further, or you have questions about
how to resolve this issue, please feel free to respond to this email and
Greg will reply once he has dug out from the pending patches received
from other developers.

thanks,

greg k-h's patch email bot

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH v1] kernel: usb: Adds space, removes trailing whitespace and fixes pointer declaration.
  2023-08-15 21:04 ` Greg KH
@ 2023-08-16  2:48   ` Atul Kumar Pant
  0 siblings, 0 replies; 3+ messages in thread
From: Atul Kumar Pant @ 2023-08-16  2:48 UTC (permalink / raw)
  To: Greg KH; +Cc: oneukum, linux-usb, linux-kernel, shuah

On Tue, Aug 15, 2023 at 11:04:52PM +0200, Greg KH wrote:
> On Wed, Aug 16, 2023 at 02:18:41AM +0530, Atul Kumar Pant wrote:
> > This patch fixes following checkpatch.pl issue:
> > ERROR: space required before the open parenthesis '('
> > ERROR: trailing whitespace
> > ERROR: space required after that ','
> > ERROR: "foo * bar" should be "foo *bar"
> > 
> > Signed-off-by: Atul Kumar Pant <atulpant.linux@gmail.com>
> > ---
> >  drivers/usb/class/cdc-acm.c | 8 ++++----
> >  1 file changed, 4 insertions(+), 4 deletions(-)
> > 
> > diff --git a/drivers/usb/class/cdc-acm.c b/drivers/usb/class/cdc-acm.c
> > index 11da5fb284d0..638c9cdaa041 100644
> > --- a/drivers/usb/class/cdc-acm.c
> > +++ b/drivers/usb/class/cdc-acm.c
> > @@ -203,7 +203,7 @@ static int acm_wb_is_avail(struct acm *acm)
> >  	n = ACM_NW;
> >  	spin_lock_irqsave(&acm->write_lock, flags);
> >  	for (i = 0; i < ACM_NW; i++)
> > -		if(acm->wb[i].use)
> > +		if (acm->wb[i].use)
> >  			n--;
> >  	spin_unlock_irqrestore(&acm->write_lock, flags);
> >  	return n;
> > @@ -1006,7 +1006,7 @@ static int wait_serial_change(struct acm *acm, unsigned long arg)
> >  		}
> >  	} while (!rv);
> >  
> > -	
> > +
> >  
> >  	return rv;
> >  }
> > @@ -1257,7 +1257,7 @@ static int acm_probe(struct usb_interface *intf,
> >  
> >  	if (control_interface == data_interface) {
> >  		/* some broken devices designed for windows work this way */
> > -		dev_warn(&intf->dev,"Control and data interfaces are not separated!\n");
> > +		dev_warn(&intf->dev, "Control and data interfaces are not separated!\n");
> >  		combined_interfaces = 1;
> >  		/* a popular other OS doesn't use it */
> >  		quirks |= NO_CAP_LINE;
> > @@ -1428,7 +1428,7 @@ static int acm_probe(struct usb_interface *intf,
> >  		goto err_free_write_urbs;
> >  
> >  	if (h.usb_cdc_country_functional_desc) { /* export the country data */
> > -		struct usb_cdc_country_functional_desc * cfd =
> > +		struct usb_cdc_country_functional_desc *cfd =
> >  					h.usb_cdc_country_functional_desc;
> >  
> >  		acm->country_codes = kmalloc(cfd->bLength - 4, GFP_KERNEL);
> > -- 
> > 2.25.1
> > 
> 
> Hi,
> 
> This is the friendly patch-bot of Greg Kroah-Hartman.  You have sent him
> a patch that has triggered this response.  He used to manually respond
> to these common problems, but in order to save his sanity (he kept
> writing the same thing over and over, yet to different people), I was
> created.  Hopefully you will not take offence and will fix the problem
> in your patch and resubmit it so that it can be accepted into the Linux
> kernel tree.
> 
> You are receiving this message because of the following common error(s)
> as indicated below:
> 
> - Your patch did many different things all at once, making it difficult
>   to review.  All Linux kernel patches need to only do one thing at a
>   time.  If you need to do multiple things (such as clean up all coding
>   style issues in a file/driver), do it in a sequence of patches, each
>   one doing only one thing.  This will make it easier to review the
>   patches to ensure that they are correct, and to help alleviate any
>   merge issues that larger patches can cause.
> 
> If you wish to discuss this problem further, or you have questions about
> how to resolve this issue, please feel free to respond to this email and
> Greg will reply once he has dug out from the pending patches received
> from other developers.
> 
> thanks,

	Sure, I'll do these cleanup in seperate patches.

> 
> greg k-h's patch email bot

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2023-08-16  2:49 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-08-15 20:48 [PATCH v1] kernel: usb: Adds space, removes trailing whitespace and fixes pointer declaration Atul Kumar Pant
2023-08-15 21:04 ` Greg KH
2023-08-16  2:48   ` Atul Kumar Pant

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).