public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return
@ 2014-07-24  8:18 Fabian Frederick
  2014-07-24  8:18 ` [PATCH 01/10 linux-next] USB: iowarrior: remove unnecessary break after goto Fabian Frederick
                   ` (10 more replies)
  0 siblings, 11 replies; 15+ messages in thread
From: Fabian Frederick @ 2014-07-24  8:18 UTC (permalink / raw)
  To: linux-kernel
  Cc: joe, gregkh, Fabian Frederick, linux-usb, linux-omap, usb-storage

Small patchset addressing break redundancy on drivers/usb branch
(suggested by Joe Perches).

Fabian Frederick (10):
  USB: iowarrior: remove unnecessary break after goto
  USB: usblcd: remove unnecessary break after return
  usb: dcw3: remove unnecessary break after return
  usb: gadget: remove unnecessary break after return
  usb: gadget: remove unnecessary break after goto
  xhci: remove unnecessary break after return
  usb: storage: remove unnecessary break after return
  USB: serial: remove unnecessary break after return
  USB: ftdi_sio: remove unnecessary break after return
  USB: microtek: remove unnecessary break after goto

 drivers/usb/dwc3/ep0.c                     | 2 --
 drivers/usb/gadget/function/f_hid.c        | 8 --------
 drivers/usb/gadget/legacy/tcm_usb_gadget.c | 2 --
 drivers/usb/host/xhci-mem.c                | 1 -
 drivers/usb/image/microtek.c               | 1 -
 drivers/usb/misc/iowarrior.c               | 3 ---
 drivers/usb/misc/usblcd.c                  | 1 -
 drivers/usb/serial/ftdi_sio.c              | 1 -
 drivers/usb/serial/iuu_phoenix.c           | 2 --
 drivers/usb/storage/freecom.c              | 1 -
 10 files changed, 22 deletions(-)

-- 
1.8.4.5


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

* [PATCH 01/10 linux-next] USB: iowarrior: remove unnecessary break after goto
  2014-07-24  8:18 [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return Fabian Frederick
@ 2014-07-24  8:18 ` Fabian Frederick
  2014-07-24  8:18 ` [PATCH 02/10 linux-next] USB: usblcd: remove unnecessary break after return Fabian Frederick
                   ` (9 subsequent siblings)
  10 siblings, 0 replies; 15+ messages in thread
From: Fabian Frederick @ 2014-07-24  8:18 UTC (permalink / raw)
  To: linux-kernel; +Cc: joe, gregkh, Fabian Frederick, linux-usb

Signed-off-by: Fabian Frederick <fabf@skynet.be>
---
 drivers/usb/misc/iowarrior.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/drivers/usb/misc/iowarrior.c b/drivers/usb/misc/iowarrior.c
index c6bfd13..17ce9a4 100644
--- a/drivers/usb/misc/iowarrior.c
+++ b/drivers/usb/misc/iowarrior.c
@@ -381,7 +381,6 @@ static ssize_t iowarrior_write(struct file *file,
 		retval = usb_set_report(dev->interface, 2, 0, buf, count);
 		kfree(buf);
 		goto exit;
-		break;
 	case USB_DEVICE_ID_CODEMERCS_IOW56:
 		/* The IOW56 uses asynchronous IO and more urbs */
 		if (atomic_read(&dev->write_busy) == MAX_WRITES_IN_FLIGHT) {
@@ -447,14 +446,12 @@ static ssize_t iowarrior_write(struct file *file,
 		retval = count;
 		usb_free_urb(int_out_urb);
 		goto exit;
-		break;
 	default:
 		/* what do we have here ? An unsupported Product-ID ? */
 		dev_err(&dev->interface->dev, "%s - not supported for product=0x%x\n",
 			__func__, dev->product_id);
 		retval = -EFAULT;
 		goto exit;
-		break;
 	}
 error:
 	usb_free_coherent(dev->udev, dev->report_size, buf,
-- 
1.8.4.5


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

* [PATCH 02/10 linux-next] USB: usblcd: remove unnecessary break after return
  2014-07-24  8:18 [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return Fabian Frederick
  2014-07-24  8:18 ` [PATCH 01/10 linux-next] USB: iowarrior: remove unnecessary break after goto Fabian Frederick
@ 2014-07-24  8:18 ` Fabian Frederick
  2014-07-24  8:18 ` [PATCH 03/10 linux-next] usb: dcw3: " Fabian Frederick
                   ` (8 subsequent siblings)
  10 siblings, 0 replies; 15+ messages in thread
From: Fabian Frederick @ 2014-07-24  8:18 UTC (permalink / raw)
  To: linux-kernel; +Cc: joe, gregkh, Fabian Frederick, linux-usb

Signed-off-by: Fabian Frederick <fabf@skynet.be>
---
 drivers/usb/misc/usblcd.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/usb/misc/usblcd.c b/drivers/usb/misc/usblcd.c
index 1184390..5085d69 100644
--- a/drivers/usb/misc/usblcd.c
+++ b/drivers/usb/misc/usblcd.c
@@ -190,7 +190,6 @@ static long lcd_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
 		break;
 	default:
 		return -ENOTTY;
-		break;
 	}
 
 	return 0;
-- 
1.8.4.5


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

* [PATCH 03/10 linux-next] usb: dcw3: remove unnecessary break after return
  2014-07-24  8:18 [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return Fabian Frederick
  2014-07-24  8:18 ` [PATCH 01/10 linux-next] USB: iowarrior: remove unnecessary break after goto Fabian Frederick
  2014-07-24  8:18 ` [PATCH 02/10 linux-next] USB: usblcd: remove unnecessary break after return Fabian Frederick
@ 2014-07-24  8:18 ` Fabian Frederick
  2014-07-24  8:18 ` [PATCH 04/10 linux-next] usb: gadget: " Fabian Frederick
                   ` (7 subsequent siblings)
  10 siblings, 0 replies; 15+ messages in thread
From: Fabian Frederick @ 2014-07-24  8:18 UTC (permalink / raw)
  To: linux-kernel
  Cc: joe, gregkh, Fabian Frederick, Felipe Balbi, linux-usb,
	linux-omap

Signed-off-by: Fabian Frederick <fabf@skynet.be>
---
 drivers/usb/dwc3/ep0.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/usb/dwc3/ep0.c b/drivers/usb/dwc3/ep0.c
index 21a3520..927dad3 100644
--- a/drivers/usb/dwc3/ep0.c
+++ b/drivers/usb/dwc3/ep0.c
@@ -422,7 +422,6 @@ static int dwc3_ep0_handle_feature(struct dwc3 *dwc,
 
 		case USB_DEVICE_LTM_ENABLE:
 			return -EINVAL;
-			break;
 
 		case USB_DEVICE_TEST_MODE:
 			if ((wIndex & 0xff) != 0)
@@ -530,7 +529,6 @@ static int dwc3_ep0_set_config(struct dwc3 *dwc, struct usb_ctrlrequest *ctrl)
 	switch (state) {
 	case USB_STATE_DEFAULT:
 		return -EINVAL;
-		break;
 
 	case USB_STATE_ADDRESS:
 		ret = dwc3_ep0_delegate_req(dwc, ctrl);
-- 
1.8.4.5


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

* [PATCH 04/10 linux-next] usb: gadget: remove unnecessary break after return
  2014-07-24  8:18 [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return Fabian Frederick
                   ` (2 preceding siblings ...)
  2014-07-24  8:18 ` [PATCH 03/10 linux-next] usb: dcw3: " Fabian Frederick
@ 2014-07-24  8:18 ` Fabian Frederick
  2014-07-24  8:18 ` [PATCH 05/10 linux-next] usb: gadget: remove unnecessary break after goto Fabian Frederick
                   ` (6 subsequent siblings)
  10 siblings, 0 replies; 15+ messages in thread
From: Fabian Frederick @ 2014-07-24  8:18 UTC (permalink / raw)
  To: linux-kernel; +Cc: joe, gregkh, Fabian Frederick, Felipe Balbi, linux-usb

Signed-off-by: Fabian Frederick <fabf@skynet.be>
---
 drivers/usb/gadget/legacy/tcm_usb_gadget.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/usb/gadget/legacy/tcm_usb_gadget.c b/drivers/usb/gadget/legacy/tcm_usb_gadget.c
index 6cdb7a5..fb7cbb4 100644
--- a/drivers/usb/gadget/legacy/tcm_usb_gadget.c
+++ b/drivers/usb/gadget/legacy/tcm_usb_gadget.c
@@ -465,13 +465,11 @@ static int usbg_bot_setup(struct usb_function *f,
 		*ret_lun = luns;
 		cdev->req->length = 1;
 		return usb_ep_queue(cdev->gadget->ep0, cdev->req, GFP_ATOMIC);
-		break;
 
 	case US_BULK_RESET_REQUEST:
 		/* XXX maybe we should remove previous requests for IN + OUT */
 		bot_enqueue_cmd_cbw(fu);
 		return 0;
-		break;
 	}
 	return -ENOTSUPP;
 }
-- 
1.8.4.5


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

* [PATCH 05/10 linux-next] usb: gadget: remove unnecessary break after goto
  2014-07-24  8:18 [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return Fabian Frederick
                   ` (3 preceding siblings ...)
  2014-07-24  8:18 ` [PATCH 04/10 linux-next] usb: gadget: " Fabian Frederick
@ 2014-07-24  8:18 ` Fabian Frederick
  2014-07-24  8:18 ` [PATCH 06/10 linux-next] xhci: remove unnecessary break after return Fabian Frederick
                   ` (5 subsequent siblings)
  10 siblings, 0 replies; 15+ messages in thread
From: Fabian Frederick @ 2014-07-24  8:18 UTC (permalink / raw)
  To: linux-kernel; +Cc: joe, gregkh, Fabian Frederick, Felipe Balbi, linux-usb

Signed-off-by: Fabian Frederick <fabf@skynet.be>
---
 drivers/usb/gadget/function/f_hid.c | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/drivers/usb/gadget/function/f_hid.c b/drivers/usb/gadget/function/f_hid.c
index a95290a..21c4b9c 100644
--- a/drivers/usb/gadget/function/f_hid.c
+++ b/drivers/usb/gadget/function/f_hid.c
@@ -386,25 +386,21 @@ static int hidg_setup(struct usb_function *f,
 		memset(req->buf, 0x0, length);
 
 		goto respond;
-		break;
 
 	case ((USB_DIR_IN | USB_TYPE_CLASS | USB_RECIP_INTERFACE) << 8
 		  | HID_REQ_GET_PROTOCOL):
 		VDBG(cdev, "get_protocol\n");
 		goto stall;
-		break;
 
 	case ((USB_DIR_OUT | USB_TYPE_CLASS | USB_RECIP_INTERFACE) << 8
 		  | HID_REQ_SET_REPORT):
 		VDBG(cdev, "set_report | wLenght=%d\n", ctrl->wLength);
 		goto stall;
-		break;
 
 	case ((USB_DIR_OUT | USB_TYPE_CLASS | USB_RECIP_INTERFACE) << 8
 		  | HID_REQ_SET_PROTOCOL):
 		VDBG(cdev, "set_protocol\n");
 		goto stall;
-		break;
 
 	case ((USB_DIR_IN | USB_TYPE_STANDARD | USB_RECIP_INTERFACE) << 8
 		  | USB_REQ_GET_DESCRIPTOR):
@@ -415,20 +411,17 @@ static int hidg_setup(struct usb_function *f,
 						   hidg_desc.bLength);
 			memcpy(req->buf, &hidg_desc, length);
 			goto respond;
-			break;
 		case HID_DT_REPORT:
 			VDBG(cdev, "USB_REQ_GET_DESCRIPTOR: REPORT\n");
 			length = min_t(unsigned short, length,
 						   hidg->report_desc_length);
 			memcpy(req->buf, hidg->report_desc, length);
 			goto respond;
-			break;
 
 		default:
 			VDBG(cdev, "Unknown descriptor request 0x%x\n",
 				 value >> 8);
 			goto stall;
-			break;
 		}
 		break;
 
@@ -436,7 +429,6 @@ static int hidg_setup(struct usb_function *f,
 		VDBG(cdev, "Unknown request 0x%x\n",
 			 ctrl->bRequest);
 		goto stall;
-		break;
 	}
 
 stall:
-- 
1.8.4.5


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

* [PATCH 06/10 linux-next] xhci: remove unnecessary break after return
  2014-07-24  8:18 [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return Fabian Frederick
                   ` (4 preceding siblings ...)
  2014-07-24  8:18 ` [PATCH 05/10 linux-next] usb: gadget: remove unnecessary break after goto Fabian Frederick
@ 2014-07-24  8:18 ` Fabian Frederick
  2014-07-24 11:43   ` Mathias Nyman
  2014-07-24  8:18 ` [PATCH 07/10 linux-next] usb: storage: " Fabian Frederick
                   ` (4 subsequent siblings)
  10 siblings, 1 reply; 15+ messages in thread
From: Fabian Frederick @ 2014-07-24  8:18 UTC (permalink / raw)
  To: linux-kernel; +Cc: joe, gregkh, Fabian Frederick, Mathias Nyman, linux-usb

Signed-off-by: Fabian Frederick <fabf@skynet.be>
---
 drivers/usb/host/xhci-mem.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/usb/host/xhci-mem.c b/drivers/usb/host/xhci-mem.c
index 8056d90..aa5eb64 100644
--- a/drivers/usb/host/xhci-mem.c
+++ b/drivers/usb/host/xhci-mem.c
@@ -1129,7 +1129,6 @@ int xhci_setup_addressable_virt_dev(struct xhci_hcd *xhci, struct usb_device *ud
 	case USB_SPEED_WIRELESS:
 		xhci_dbg(xhci, "FIXME xHCI doesn't support wireless speeds\n");
 		return -EINVAL;
-		break;
 	default:
 		/* Speed was set earlier, this shouldn't happen. */
 		return -EINVAL;
-- 
1.8.4.5


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

* [PATCH 07/10 linux-next] usb: storage: remove unnecessary break after return
  2014-07-24  8:18 [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return Fabian Frederick
                   ` (5 preceding siblings ...)
  2014-07-24  8:18 ` [PATCH 06/10 linux-next] xhci: remove unnecessary break after return Fabian Frederick
@ 2014-07-24  8:18 ` Fabian Frederick
  2014-07-24  8:18 ` [PATCH 08/10 linux-next] USB: serial: " Fabian Frederick
                   ` (3 subsequent siblings)
  10 siblings, 0 replies; 15+ messages in thread
From: Fabian Frederick @ 2014-07-24  8:18 UTC (permalink / raw)
  To: linux-kernel
  Cc: joe, gregkh, Fabian Frederick, Matthew Dharm, linux-usb,
	usb-storage

Signed-off-by: Fabian Frederick <fabf@skynet.be>
---
 drivers/usb/storage/freecom.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/usb/storage/freecom.c b/drivers/usb/storage/freecom.c
index ef16068..e6f8c1f 100644
--- a/drivers/usb/storage/freecom.c
+++ b/drivers/usb/storage/freecom.c
@@ -417,7 +417,6 @@ static int freecom_transport(struct scsi_cmnd *srb, struct us_data *us)
 			     us->srb->sc_data_direction);
 		/* Return fail, SCSI seems to handle this better. */
 		return USB_STOR_TRANSPORT_FAILED;
-		break;
 	}
 
 	return USB_STOR_TRANSPORT_GOOD;
-- 
1.8.4.5


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

* [PATCH 08/10 linux-next] USB: serial: remove unnecessary break after return
  2014-07-24  8:18 [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return Fabian Frederick
                   ` (6 preceding siblings ...)
  2014-07-24  8:18 ` [PATCH 07/10 linux-next] usb: storage: " Fabian Frederick
@ 2014-07-24  8:18 ` Fabian Frederick
  2014-07-24  8:18 ` [PATCH 09/10 linux-next] USB: ftdi_sio: " Fabian Frederick
                   ` (2 subsequent siblings)
  10 siblings, 0 replies; 15+ messages in thread
From: Fabian Frederick @ 2014-07-24  8:18 UTC (permalink / raw)
  To: linux-kernel; +Cc: joe, gregkh, Fabian Frederick, Johan Hovold, linux-usb

Signed-off-by: Fabian Frederick <fabf@skynet.be>
---
 drivers/usb/serial/iuu_phoenix.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/usb/serial/iuu_phoenix.c b/drivers/usb/serial/iuu_phoenix.c
index 5ad4a0f..705e9dd 100644
--- a/drivers/usb/serial/iuu_phoenix.c
+++ b/drivers/usb/serial/iuu_phoenix.c
@@ -860,7 +860,6 @@ static int iuu_uart_baud(struct usb_serial_port *port, u32 baud_base,
 	default:
 		kfree(dataout);
 		return IUU_INVALID_PARAMETER;
-		break;
 	}
 
 	switch (parity & 0xF0) {
@@ -874,7 +873,6 @@ static int iuu_uart_baud(struct usb_serial_port *port, u32 baud_base,
 	default:
 		kfree(dataout);
 		return IUU_INVALID_PARAMETER;
-		break;
 	}
 
 	status = bulk_immediate(port, dataout, DataCount);
-- 
1.8.4.5


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

* [PATCH 09/10 linux-next] USB: ftdi_sio: remove unnecessary break after return
  2014-07-24  8:18 [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return Fabian Frederick
                   ` (7 preceding siblings ...)
  2014-07-24  8:18 ` [PATCH 08/10 linux-next] USB: serial: " Fabian Frederick
@ 2014-07-24  8:18 ` Fabian Frederick
  2014-07-24  8:24 ` [PATCH 10/10 linux-next] USB: microtek: remove unnecessary break after goto Fabian Frederick
  2014-07-24 11:37 ` [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return Oliver Neukum
  10 siblings, 0 replies; 15+ messages in thread
From: Fabian Frederick @ 2014-07-24  8:18 UTC (permalink / raw)
  To: linux-kernel; +Cc: joe, gregkh, Fabian Frederick, Johan Hovold, linux-usb

Signed-off-by: Fabian Frederick <fabf@skynet.be>
---
 drivers/usb/serial/ftdi_sio.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/usb/serial/ftdi_sio.c b/drivers/usb/serial/ftdi_sio.c
index b9035c3..bb45c71 100644
--- a/drivers/usb/serial/ftdi_sio.c
+++ b/drivers/usb/serial/ftdi_sio.c
@@ -2414,7 +2414,6 @@ static int ftdi_ioctl(struct tty_struct *tty,
 					(struct serial_struct __user *) arg);
 	case TIOCSERGETLSR:
 		return get_lsr_info(port, (struct serial_struct __user *)arg);
-		break;
 	default:
 		break;
 	}
-- 
1.8.4.5


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

* [PATCH 10/10 linux-next] USB: microtek: remove unnecessary break after goto
  2014-07-24  8:18 [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return Fabian Frederick
                   ` (8 preceding siblings ...)
  2014-07-24  8:18 ` [PATCH 09/10 linux-next] USB: ftdi_sio: " Fabian Frederick
@ 2014-07-24  8:24 ` Fabian Frederick
  2014-07-24 11:37 ` [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return Oliver Neukum
  10 siblings, 0 replies; 15+ messages in thread
From: Fabian Frederick @ 2014-07-24  8:24 UTC (permalink / raw)
  To: linux-kernel; +Cc: joe, gregkh, Fabian Frederick, Oliver Neukum, linux-usb

Signed-off-by: Fabian Frederick <fabf@skynet.be>
---
 drivers/usb/image/microtek.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/usb/image/microtek.c b/drivers/usb/image/microtek.c
index 37b44b0..5cf2111 100644
--- a/drivers/usb/image/microtek.c
+++ b/drivers/usb/image/microtek.c
@@ -294,7 +294,6 @@ static inline void mts_show_command(struct scsi_cmnd *srb)
 	default:
 		MTS_DEBUG("can't decode command\n");
 		goto out;
-		break;
 	}
 	MTS_DEBUG( "Command %s (%d bytes)\n", what, srb->cmd_len);
 
-- 
1.8.4.5


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

* Re: [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return
  2014-07-24  8:18 [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return Fabian Frederick
                   ` (9 preceding siblings ...)
  2014-07-24  8:24 ` [PATCH 10/10 linux-next] USB: microtek: remove unnecessary break after goto Fabian Frederick
@ 2014-07-24 11:37 ` Oliver Neukum
  2014-07-24 15:46   ` Fabian Frederick
  10 siblings, 1 reply; 15+ messages in thread
From: Oliver Neukum @ 2014-07-24 11:37 UTC (permalink / raw)
  To: Fabian Frederick
  Cc: linux-kernel, joe, gregkh, linux-usb, linux-omap, usb-storage

On Thu, 2014-07-24 at 10:18 +0200, Fabian Frederick wrote:
> Small patchset addressing break redundancy on drivers/usb branch
> (suggested by Joe Perches).

Frankly, that is not a good idea. Somebody will remove a "goto"
and forget to readd the "break"

	Regards
		Oliver



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

* Re: [PATCH 06/10 linux-next] xhci: remove unnecessary break after return
  2014-07-24  8:18 ` [PATCH 06/10 linux-next] xhci: remove unnecessary break after return Fabian Frederick
@ 2014-07-24 11:43   ` Mathias Nyman
  0 siblings, 0 replies; 15+ messages in thread
From: Mathias Nyman @ 2014-07-24 11:43 UTC (permalink / raw)
  To: Fabian Frederick, linux-kernel; +Cc: joe, gregkh, Mathias Nyman, linux-usb

On 07/24/2014 11:18 AM, Fabian Frederick wrote:
> Signed-off-by: Fabian Frederick <fabf@skynet.be>
> ---

Acked-by: Mathias Nyman <mathias.nyman@linux.intel.com>



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

* Re: [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return
  2014-07-24 11:37 ` [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return Oliver Neukum
@ 2014-07-24 15:46   ` Fabian Frederick
  2014-07-24 15:52     ` Joe Perches
  0 siblings, 1 reply; 15+ messages in thread
From: Fabian Frederick @ 2014-07-24 15:46 UTC (permalink / raw)
  To: Oliver Neukum
  Cc: usb-storage, joe, gregkh, linux-kernel, linux-usb, linux-omap



> On 24 July 2014 at 13:37 Oliver Neukum <oneukum@suse.de> wrote:
>
>
> On Thu, 2014-07-24 at 10:18 +0200, Fabian Frederick wrote:
> > Small patchset addressing break redundancy on drivers/usb branch
> > (suggested by Joe Perches).
>
> Frankly, that is not a good idea. Somebody will remove a "goto"
> and forget to readd the "break"

No problem ; checkpatch would give a warning anyway. See "Possible switch
case/default not preceeded by break or fallthrough comment"

Regards,
Fabian
>
>       Regards
>               Oliver
>
>

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

* Re: [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return
  2014-07-24 15:46   ` Fabian Frederick
@ 2014-07-24 15:52     ` Joe Perches
  0 siblings, 0 replies; 15+ messages in thread
From: Joe Perches @ 2014-07-24 15:52 UTC (permalink / raw)
  To: Fabian Frederick
  Cc: Oliver Neukum, usb-storage, gregkh, linux-kernel, linux-usb,
	linux-omap

On Thu, 2014-07-24 at 17:46 +0200, Fabian Frederick wrote:
> 
> > On 24 July 2014 at 13:37 Oliver Neukum <oneukum@suse.de> wrote:
> >
> >
> > On Thu, 2014-07-24 at 10:18 +0200, Fabian Frederick wrote:
> > > Small patchset addressing break redundancy on drivers/usb branch
> > > (suggested by Joe Perches).
> >
> > Frankly, that is not a good idea. Somebody will remove a "goto"
> > and forget to readd the "break"
> 
> No problem ; checkpatch would give a warning anyway. See "Possible switch
> case/default not preceeded by break or fallthrough comment"

Generally true, but not everyone uses checkpatch.



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

end of thread, other threads:[~2014-07-24 15:52 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-07-24  8:18 [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return Fabian Frederick
2014-07-24  8:18 ` [PATCH 01/10 linux-next] USB: iowarrior: remove unnecessary break after goto Fabian Frederick
2014-07-24  8:18 ` [PATCH 02/10 linux-next] USB: usblcd: remove unnecessary break after return Fabian Frederick
2014-07-24  8:18 ` [PATCH 03/10 linux-next] usb: dcw3: " Fabian Frederick
2014-07-24  8:18 ` [PATCH 04/10 linux-next] usb: gadget: " Fabian Frederick
2014-07-24  8:18 ` [PATCH 05/10 linux-next] usb: gadget: remove unnecessary break after goto Fabian Frederick
2014-07-24  8:18 ` [PATCH 06/10 linux-next] xhci: remove unnecessary break after return Fabian Frederick
2014-07-24 11:43   ` Mathias Nyman
2014-07-24  8:18 ` [PATCH 07/10 linux-next] usb: storage: " Fabian Frederick
2014-07-24  8:18 ` [PATCH 08/10 linux-next] USB: serial: " Fabian Frederick
2014-07-24  8:18 ` [PATCH 09/10 linux-next] USB: ftdi_sio: " Fabian Frederick
2014-07-24  8:24 ` [PATCH 10/10 linux-next] USB: microtek: remove unnecessary break after goto Fabian Frederick
2014-07-24 11:37 ` [PATCH 00/10 linux-next] drivers/usb: remove unnecessary break after goto/return Oliver Neukum
2014-07-24 15:46   ` Fabian Frederick
2014-07-24 15:52     ` Joe Perches

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox