All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Staging: octeon-hcd: removed unwanted return from void functions
@ 2014-09-08 17:13 Nitin Kuppelur
  2014-09-08 18:59 ` Aaro Koskinen
  0 siblings, 1 reply; 7+ messages in thread
From: Nitin Kuppelur @ 2014-09-08 17:13 UTC (permalink / raw)
  To: gregkh; +Cc: devel, linux-kernel, Nitin Kuppelur

This is a patch to the octeon-hcd.c file that fixes checkpatch.pl warning by removing return statement from void functions.

Signed-off-by: Nitin Kuppelur <nitinkuppelur@gmail.com>
---
 drivers/staging/octeon-usb/octeon-hcd.c | 9 ---------
 1 file changed, 9 deletions(-)

diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c
index 3a5feb4..8a80982 100644
--- a/drivers/staging/octeon-usb/octeon-hcd.c
+++ b/drivers/staging/octeon-usb/octeon-hcd.c
@@ -1332,8 +1332,6 @@ static void __cvmx_usb_poll_rx_fifo(struct cvmx_usb_state *usb)
 		bytes -= 4;
 	}
 	CVMX_SYNCW;
-
-	return;
 }
 
 
@@ -1437,8 +1435,6 @@ static void __cvmx_usb_poll_tx_fifo(struct cvmx_usb_state *usb)
 					union cvmx_usbcx_gintmsk,
 					nptxfempmsk, 0);
 	}
-
-	return;
 }
 
 
@@ -1490,8 +1486,6 @@ static void __cvmx_usb_fill_tx_fifo(struct cvmx_usb_state *usb, int channel)
 		fifo->head = 0;
 
 	__cvmx_usb_poll_tx_fifo(usb);
-
-	return;
 }
 
 /**
@@ -1640,7 +1634,6 @@ static void __cvmx_usb_start_channel_control(struct cvmx_usb_state *usb,
 
 	__cvmx_usb_write_csr32(usb, CVMX_USBCX_HCTSIZX(channel, usb->index),
 			       usbc_hctsiz.u32);
-	return;
 }
 
 
@@ -1987,7 +1980,6 @@ static void __cvmx_usb_start_channel(struct cvmx_usb_state *usb,
 			union cvmx_usbcx_hccharx, chena, 1);
 	if (usb->init_flags & CVMX_USB_INITIALIZE_FLAGS_NO_DMA)
 		__cvmx_usb_fill_tx_fifo(usb, channel);
-	return;
 }
 
 
@@ -2116,7 +2108,6 @@ done:
 	}
 	USB_SET_FIELD32(CVMX_USBCX_GINTMSK(usb->index),
 			union cvmx_usbcx_gintmsk, sofmsk, need_sof);
-	return;
 }
 
 static inline struct octeon_hcd *cvmx_usb_to_octeon(struct cvmx_usb_state *p)
-- 
1.9.1


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

* Re: [PATCH] Staging: octeon-hcd: removed unwanted return from void functions
  2014-09-08 17:13 [PATCH] Staging: octeon-hcd: removed unwanted return from void functions Nitin Kuppelur
@ 2014-09-08 18:59 ` Aaro Koskinen
  2014-09-08 19:09   ` Nitin Kuppelur
  2014-09-08 19:33   ` Greg KH
  0 siblings, 2 replies; 7+ messages in thread
From: Aaro Koskinen @ 2014-09-08 18:59 UTC (permalink / raw)
  To: Nitin Kuppelur; +Cc: gregkh, devel, linux-kernel

On Mon, Sep 08, 2014 at 07:13:15PM +0200, Nitin Kuppelur wrote:
> This is a patch to the octeon-hcd.c file that fixes checkpatch.pl warning by removing return statement from void functions.

Please format line length to <= 76 characters in the commit log.

Maybe you could fix __cvmx_usb_perform_complete() as well?

A.

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

* Re: [PATCH] Staging: octeon-hcd: removed unwanted return from void functions
  2014-09-08 18:59 ` Aaro Koskinen
@ 2014-09-08 19:09   ` Nitin Kuppelur
  2014-09-08 19:28     ` [PATCH V2] Staging: octeon-hcd: removed unwanted return from void Nitin Kuppelur
  2014-09-09  7:14     ` [PATCH] Staging: octeon-hcd: removed unwanted return from void functions Dan Carpenter
  2014-09-08 19:33   ` Greg KH
  1 sibling, 2 replies; 7+ messages in thread
From: Nitin Kuppelur @ 2014-09-08 19:09 UTC (permalink / raw)
  To: Aaro Koskinen; +Cc: gregkh, devel, linux-kernel

Hi Aaro,

Thanks for review. I will correct the commit log length and resend the patch.

About the __cvmx_usb_perform_complete():
Here return statement has associated label. Due to which it will add
compilation warning. So I am not handling this.

Note:
Also checkpatch.pl does not complain about this.

Regards,
Nitin

> Please format line length to <= 76 characters in the commit log.
> 
> Maybe you could fix __cvmx_usb_perform_complete() as well?
> 
> A.
> 

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

* [PATCH V2] Staging: octeon-hcd: removed unwanted return from void
  2014-09-08 19:09   ` Nitin Kuppelur
@ 2014-09-08 19:28     ` Nitin Kuppelur
  2014-09-09  7:14     ` [PATCH] Staging: octeon-hcd: removed unwanted return from void functions Dan Carpenter
  1 sibling, 0 replies; 7+ messages in thread
From: Nitin Kuppelur @ 2014-09-08 19:28 UTC (permalink / raw)
  To: gregkh; +Cc: devel, linux-kernel, Nitin Kuppelur

This is a patch to the octeon-hcd.c file that fixes
checkpatch.pl warning by removing return statement from
void functions.

Signed-off-by: Nitin Kuppelur <nitinkuppelur@gmail.com>
---
 drivers/staging/octeon-usb/octeon-hcd.c | 9 ---------
 1 file changed, 9 deletions(-)

diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c
index 3a5feb4..8a80982 100644
--- a/drivers/staging/octeon-usb/octeon-hcd.c
+++ b/drivers/staging/octeon-usb/octeon-hcd.c
@@ -1332,8 +1332,6 @@ static void __cvmx_usb_poll_rx_fifo(struct cvmx_usb_state *usb)
 		bytes -= 4;
 	}
 	CVMX_SYNCW;
-
-	return;
 }
 
 
@@ -1437,8 +1435,6 @@ static void __cvmx_usb_poll_tx_fifo(struct cvmx_usb_state *usb)
 					union cvmx_usbcx_gintmsk,
 					nptxfempmsk, 0);
 	}
-
-	return;
 }
 
 
@@ -1490,8 +1486,6 @@ static void __cvmx_usb_fill_tx_fifo(struct cvmx_usb_state *usb, int channel)
 		fifo->head = 0;
 
 	__cvmx_usb_poll_tx_fifo(usb);
-
-	return;
 }
 
 /**
@@ -1640,7 +1634,6 @@ static void __cvmx_usb_start_channel_control(struct cvmx_usb_state *usb,
 
 	__cvmx_usb_write_csr32(usb, CVMX_USBCX_HCTSIZX(channel, usb->index),
 			       usbc_hctsiz.u32);
-	return;
 }
 
 
@@ -1987,7 +1980,6 @@ static void __cvmx_usb_start_channel(struct cvmx_usb_state *usb,
 			union cvmx_usbcx_hccharx, chena, 1);
 	if (usb->init_flags & CVMX_USB_INITIALIZE_FLAGS_NO_DMA)
 		__cvmx_usb_fill_tx_fifo(usb, channel);
-	return;
 }
 
 
@@ -2116,7 +2108,6 @@ done:
 	}
 	USB_SET_FIELD32(CVMX_USBCX_GINTMSK(usb->index),
 			union cvmx_usbcx_gintmsk, sofmsk, need_sof);
-	return;
 }
 
 static inline struct octeon_hcd *cvmx_usb_to_octeon(struct cvmx_usb_state *p)
-- 
1.9.1


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

* Re: [PATCH] Staging: octeon-hcd: removed unwanted return from void functions
  2014-09-08 18:59 ` Aaro Koskinen
  2014-09-08 19:09   ` Nitin Kuppelur
@ 2014-09-08 19:33   ` Greg KH
  2014-09-08 21:26     ` Aaro Koskinen
  1 sibling, 1 reply; 7+ messages in thread
From: Greg KH @ 2014-09-08 19:33 UTC (permalink / raw)
  To: Aaro Koskinen; +Cc: Nitin Kuppelur, devel, linux-kernel

On Mon, Sep 08, 2014 at 09:59:23PM +0300, Aaro Koskinen wrote:
> On Mon, Sep 08, 2014 at 07:13:15PM +0200, Nitin Kuppelur wrote:
> > This is a patch to the octeon-hcd.c file that fixes checkpatch.pl warning by removing return statement from void functions.
> 
> Please format line length to <= 76 characters in the commit log.
> 
> Maybe you could fix __cvmx_usb_perform_complete() as well?

What is wrong with it?  That should be in a separate patch...

thanks,

greg k-h

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

* Re: [PATCH] Staging: octeon-hcd: removed unwanted return from void functions
  2014-09-08 19:33   ` Greg KH
@ 2014-09-08 21:26     ` Aaro Koskinen
  0 siblings, 0 replies; 7+ messages in thread
From: Aaro Koskinen @ 2014-09-08 21:26 UTC (permalink / raw)
  To: Greg KH; +Cc: Nitin Kuppelur, devel, linux-kernel

Hi,

On Mon, Sep 08, 2014 at 12:33:47PM -0700, Greg KH wrote:
> On Mon, Sep 08, 2014 at 09:59:23PM +0300, Aaro Koskinen wrote:
> > On Mon, Sep 08, 2014 at 07:13:15PM +0200, Nitin Kuppelur wrote:
> > > This is a patch to the octeon-hcd.c file that fixes checkpatch.pl warning by removing return statement from void functions.
> > 
> > Please format line length to <= 76 characters in the commit log.
> > 
> > Maybe you could fix __cvmx_usb_perform_complete() as well?
> 
> What is wrong with it?  That should be in a separate patch...

There's "return;" at the end of void function. I thought the patch
was about that, however it seems checkpatch.pl does not seem
complain about that.

A.

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

* Re: [PATCH] Staging: octeon-hcd: removed unwanted return from void functions
  2014-09-08 19:09   ` Nitin Kuppelur
  2014-09-08 19:28     ` [PATCH V2] Staging: octeon-hcd: removed unwanted return from void Nitin Kuppelur
@ 2014-09-09  7:14     ` Dan Carpenter
  1 sibling, 0 replies; 7+ messages in thread
From: Dan Carpenter @ 2014-09-09  7:14 UTC (permalink / raw)
  To: Nitin Kuppelur; +Cc: Aaro Koskinen, devel, gregkh, linux-kernel

On Mon, Sep 08, 2014 at 09:09:14PM +0200, Nitin Kuppelur wrote:
> Hi Aaro,
> 
> Thanks for review. I will correct the commit log length and resend the patch.
> 
> About the __cvmx_usb_perform_complete():
> Here return statement has associated label. Due to which it will add
> compilation warning. So I am not handling this.

Just remove the label as well.  Do-nothing labels are a plague.

regards,
dan carpenter


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

end of thread, other threads:[~2014-09-09  7:15 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-08 17:13 [PATCH] Staging: octeon-hcd: removed unwanted return from void functions Nitin Kuppelur
2014-09-08 18:59 ` Aaro Koskinen
2014-09-08 19:09   ` Nitin Kuppelur
2014-09-08 19:28     ` [PATCH V2] Staging: octeon-hcd: removed unwanted return from void Nitin Kuppelur
2014-09-09  7:14     ` [PATCH] Staging: octeon-hcd: removed unwanted return from void functions Dan Carpenter
2014-09-08 19:33   ` Greg KH
2014-09-08 21:26     ` Aaro Koskinen

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.