mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] ehci-dbgp: drop dead code.
@ 2013-09-12 15:08 Tim Deegan
  0 siblings, 0 replies; only message in thread
From: Tim Deegan @ 2013-09-12 15:08 UTC (permalink / raw)
  To: Greg Kroah-Hartman; +Cc: linux-usb, linux-kernel

We can only reach this spot by breaking out of the scan loop,
so by construction ret > 0.

Found by Coverity, in a copy of this file in the Xen sources.

Signed-off-by: Tim Deegan <tim@xen.org>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: linux-usb@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
---
 drivers/usb/early/ehci-dbgp.c |    4 ----
 1 file changed, 4 deletions(-)

diff --git a/drivers/usb/early/ehci-dbgp.c b/drivers/usb/early/ehci-dbgp.c
index 5e29dde..8cfc319 100644
--- a/drivers/usb/early/ehci-dbgp.c
+++ b/drivers/usb/early/ehci-dbgp.c
@@ -568,10 +568,6 @@ try_again:
 		dbgp_printk("Could not find attached debug device\n");
 		goto err;
 	}
-	if (ret < 0) {
-		dbgp_printk("Attached device is not a debug device\n");
-		goto err;
-	}
 	dbgp_endpoint_out = dbgp_desc.bDebugOutEndpoint;
 	dbgp_endpoint_in = dbgp_desc.bDebugInEndpoint;
 
-- 
1.7.10.4


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2013-09-12 15:08 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-09-12 15:08 [PATCH] ehci-dbgp: drop dead code Tim Deegan

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

all inboxes | Powered by JetHome®