From: David Brownell Date: Sun, 2 Apr 2006 18:18:53 +0000 (-0800) Subject: [PATCH] USB: net2280 short rx status fix X-Git-Tag: v2.6.17-rc2~49 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=68dcc688d1f042842a8fb523e4a584b3211181d1;p=linux-2.6 [PATCH] USB: net2280 short rx status fix Some patch broke short-OUT packet handling for net2280, making it report illegal status values. This updates the status code so it's correct. Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/usb/gadget/net2280.c b/drivers/usb/gadget/net2280.c index 7682c07035..6a4b93ad10 100644 --- a/drivers/usb/gadget/net2280.c +++ b/drivers/usb/gadget/net2280.c @@ -2241,7 +2241,8 @@ static void handle_ep_small (struct net2280_ep *ep) if (likely (req)) { req->td->dmacount = 0; t = readl (&ep->regs->ep_avail); - dma_done (ep, req, count, t); + dma_done (ep, req, count, + (ep->out_overflow || t) ? -EOVERFLOW : 0); } /* also flush to prevent erratum 0106 trouble */