aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSergei Shtylyov <sshtylyov@ru.mvista.com>2010-09-24 06:44:12 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2010-10-22 13:21:55 -0400
commit434678685407e045ffb246df059c486fc0a16e75 (patch)
treef7b76883c3dfe7ce564cd6bffd64d0d1dad27229
parent2f8d5cd6bcf814411ec356bcdbc666d07bbc6026 (diff)
usb: musb: gadget: kill unreachable code in musb_g_rx()
musb_g_rx() always returns if next_request() call yields NULL, so the DBG() near the function's end can never be invoked. Remove it along with unneeded 'return'; also remove the duplicate 'request' check... Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r--drivers/usb/musb/musb_gadget.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/drivers/usb/musb/musb_gadget.c b/drivers/usb/musb/musb_gadget.c
index f497586e36ec..6a8c061b66f1 100644
--- a/drivers/usb/musb/musb_gadget.c
+++ b/drivers/usb/musb/musb_gadget.c
@@ -775,7 +775,7 @@ void musb_g_rx(struct musb *musb, u8 epnum)
775 musb_writew(epio, MUSB_RXCSR, csr); 775 musb_writew(epio, MUSB_RXCSR, csr);
776 776
777 DBG(3, "%s iso overrun on %p\n", musb_ep->name, request); 777 DBG(3, "%s iso overrun on %p\n", musb_ep->name, request);
778 if (request && request->status == -EINPROGRESS) 778 if (request->status == -EINPROGRESS)
779 request->status = -EOVERFLOW; 779 request->status = -EOVERFLOW;
780 } 780 }
781 if (csr & MUSB_RXCSR_INCOMPRX) { 781 if (csr & MUSB_RXCSR_INCOMPRX) {
@@ -828,14 +828,8 @@ void musb_g_rx(struct musb *musb, u8 epnum)
828 return; 828 return;
829 } 829 }
830 830
831 /* analyze request if the ep is hot */ 831 /* Analyze request */
832 if (request) 832 rxstate(musb, to_musb_request(request));
833 rxstate(musb, to_musb_request(request));
834 else
835 DBG(3, "packet waiting for %s%s request\n",
836 musb_ep->desc ? "" : "inactive ",
837 musb_ep->end_point.name);
838 return;
839} 833}
840 834
841/* ------------------------------------------------------------ */ 835/* ------------------------------------------------------------ */