diff options
| author | Greg Kroah-Hartman <gregkh@suse.de> | 2009-05-12 10:09:25 -0700 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@suse.de> | 2009-05-12 10:09:25 -0700 |
| commit | 894319db8a46b4a7f3c7c03ec5ff0b345ede7644 (patch) | |
| tree | 8f37aa45436c676b30bae1d5e13a4bb64340a1c5 /usb.current | |
| parent | 989ea217bcff6b13ee5208555628f57ec9e3c64e (diff) | |
| download | patches-894319db8a46b4a7f3c7c03ec5ff0b345ede7644.tar.gz | |
lots of patches
Diffstat (limited to 'usb.current')
4 files changed, 195 insertions, 0 deletions
diff --git a/usb.current/usb-atmel-usba-udc-fix-control-out-requests.patch b/usb.current/usb-atmel-usba-udc-fix-control-out-requests.patch new file mode 100644 index 00000000000000..2497d1ad3d2c55 --- /dev/null +++ b/usb.current/usb-atmel-usba-udc-fix-control-out-requests.patch @@ -0,0 +1,33 @@ +From mfuzzey@gmail.com Tue May 12 08:58:02 2009 +From: Martin Fuzzey <mfuzzey@gmail.com> +Date: Fri, 01 May 2009 17:21:11 +0200 +Subject: USB: atmel-usba-udc : fix control out requests. +To: haavard.skinnemoen@atmel.com +Cc: linux-usb@vger.kernel.org +Message-ID: <20090501152111.29222.37730.stgit@srv002.fuzzey.net> + + +usbtest #14 was failing with "udc: ep0: TXCOMP: Invalid endpoint state 2, halting endpoint..." +This occured since ep0 is bidirectional and ep->is_in is not valid (must always use ep->state) + +Signed-off-by: Martin Fuzzey <mfuzzey@gmail.com> +Acked-by: David Brownell <dbrownell@users.sourceforge.net> +Acked-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com> +Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> + +--- + drivers/usb/gadget/atmel_usba_udc.c | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +--- a/drivers/usb/gadget/atmel_usba_udc.c ++++ b/drivers/usb/gadget/atmel_usba_udc.c +@@ -794,7 +794,8 @@ usba_ep_queue(struct usb_ep *_ep, struct + if (ep->desc) { + list_add_tail(&req->queue, &ep->queue); + +- if (ep->is_in || (ep_is_control(ep) ++ if ((!ep_is_control(ep) && ep->is_in) || ++ (ep_is_control(ep) + && (ep->state == DATA_STAGE_IN + || ep->state == STATUS_STAGE_IN))) + usba_ep_writel(ep, CTL_ENB, USBA_TX_PK_RDY); diff --git a/usb.current/usb-atmel_usb_udc-use-kzalloc-to-allocate-ep-structures.patch b/usb.current/usb-atmel_usb_udc-use-kzalloc-to-allocate-ep-structures.patch new file mode 100644 index 00000000000000..07ee022e933186 --- /dev/null +++ b/usb.current/usb-atmel_usb_udc-use-kzalloc-to-allocate-ep-structures.patch @@ -0,0 +1,30 @@ +From david-b@pacbell.net Tue May 12 08:59:43 2009 +From: Haavard Skinnemoen <haavard.skinnemoen@atmel.com> +Date: Mon, 4 May 2009 17:22:43 -0700 +Subject: USB: atmel_usb_udc: Use kzalloc() to allocate ep structures +To: Haavard Skinnemoen <haavard.skinnemoen@atmel.com> +Cc: Martin Fuzzey <mfuzzey@gmail.com> +Message-ID: <200905041722.43690.david-b@pacbell.net> + + +This ensures that all fields are properly initialized. + +Signed-off-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com> +Acked-by: David Brownell <dbrownell@users.sourceforge.net> +Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> + +--- + drivers/usb/gadget/atmel_usba_udc.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/drivers/usb/gadget/atmel_usba_udc.c ++++ b/drivers/usb/gadget/atmel_usba_udc.c +@@ -1941,7 +1941,7 @@ static int __init usba_udc_probe(struct + usba_writel(udc, CTRL, USBA_DISABLE_MASK); + clk_disable(pclk); + +- usba_ep = kmalloc(sizeof(struct usba_ep) * pdata->num_ep, ++ usba_ep = kzalloc(sizeof(struct usba_ep) * pdata->num_ep, + GFP_KERNEL); + if (!usba_ep) + goto err_alloc_ep; diff --git a/usb.current/usb-isp1760-urb_dequeue-doesn-t-always-find-the-urbs.patch b/usb.current/usb-isp1760-urb_dequeue-doesn-t-always-find-the-urbs.patch new file mode 100644 index 00000000000000..5c8cb70193d360 --- /dev/null +++ b/usb.current/usb-isp1760-urb_dequeue-doesn-t-always-find-the-urbs.patch @@ -0,0 +1,102 @@ +From sebastian@breakpoint.cc Tue May 12 09:23:09 2009 +From: Warren Free <wfree@ipmn.com> +Date: Fri, 8 May 2009 10:27:08 +0200 +Subject: USB: isp1760: urb_dequeue doesn't always find the urbs +Cc: Warren Free <wfree@ipmn.com>, stable@kernel.org, Sebastian Andrzej Siewior <bigeasy@linutronix.de> +Message-ID: <20090508082708.GA31915@Chamillionaire.breakpoint.cc> +Content-Disposition: inline + + +From: Warren Free <wfree@ipmn.com> + +The option driver (and presumably others) allocates several URBs when it +opens and tries to free them when it closes. The isp1760_urb_dequeue +function gets called, but the packet being dequeued is not necessarily at +the +front of one of the 32 queues. If not, the isp1760_urb_done function doesn't +get called for the URB and the process trying to free it hangs forever on a +wait_queue. This patch does two things. If the URB being dequeued has others +queued behind it, it re-queues them. And it searches the queues looking for +the URB being dequeued rather than just looking at the one at the front of +the queue. + +[bigeasy@linutronix] whitespace fixes, reformating + +Cc: stable <stable@kernel.org> +Signed-off-by: Warren Free <wfree@ipmn.com> +Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> +Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> + +--- + drivers/usb/host/isp1760-hcd.c | 24 ++++++++++++++++++++++-- + 1 file changed, 22 insertions(+), 2 deletions(-) + +--- a/drivers/usb/host/isp1760-hcd.c ++++ b/drivers/usb/host/isp1760-hcd.c +@@ -1658,6 +1658,7 @@ static int isp1760_urb_dequeue(struct us + u32 reg_base, or_reg, skip_reg; + unsigned long flags; + struct ptd ptd; ++ packet_enqueue *pe; + + switch (usb_pipetype(urb->pipe)) { + case PIPE_ISOCHRONOUS: +@@ -1669,6 +1670,7 @@ static int isp1760_urb_dequeue(struct us + reg_base = INT_REGS_OFFSET; + or_reg = HC_INT_IRQ_MASK_OR_REG; + skip_reg = HC_INT_PTD_SKIPMAP_REG; ++ pe = enqueue_an_INT_packet; + break; + + default: +@@ -1676,6 +1678,7 @@ static int isp1760_urb_dequeue(struct us + reg_base = ATL_REGS_OFFSET; + or_reg = HC_ATL_IRQ_MASK_OR_REG; + skip_reg = HC_ATL_PTD_SKIPMAP_REG; ++ pe = enqueue_an_ATL_packet; + break; + } + +@@ -1687,6 +1690,7 @@ static int isp1760_urb_dequeue(struct us + u32 skip_map; + u32 or_map; + struct isp1760_qtd *qtd; ++ struct isp1760_qh *qh = ints->qh; + + skip_map = isp1760_readl(hcd->regs + skip_reg); + skip_map |= 1 << i; +@@ -1699,8 +1703,7 @@ static int isp1760_urb_dequeue(struct us + priv_write_copy(priv, (u32 *)&ptd, hcd->regs + reg_base + + i * sizeof(ptd), sizeof(ptd)); + qtd = ints->qtd; +- +- clean_up_qtdlist(qtd); ++ qtd = clean_up_qtdlist(qtd); + + free_mem(priv, ints->payload); + +@@ -1711,7 +1714,24 @@ static int isp1760_urb_dequeue(struct us + ints->payload = 0; + + isp1760_urb_done(priv, urb, status); ++ if (qtd) ++ pe(hcd, qh, qtd); + break; ++ ++ } else if (ints->qtd) { ++ struct isp1760_qtd *qtd, *prev_qtd = ints->qtd; ++ ++ for (qtd = ints->qtd->hw_next; qtd; qtd = qtd->hw_next) { ++ if (qtd->urb == urb) { ++ prev_qtd->hw_next = clean_up_qtdlist(qtd); ++ isp1760_urb_done(priv, urb, status); ++ break; ++ } ++ prev_qtd = qtd; ++ } ++ /* we found the urb before the end of the list */ ++ if (qtd) ++ break; + } + ints++; + } diff --git a/usb.current/usb-yet-another-conexant-clone-to-add-to-cdc-acm.c.patch b/usb.current/usb-yet-another-conexant-clone-to-add-to-cdc-acm.c.patch new file mode 100644 index 00000000000000..51b9feeb02dc1d --- /dev/null +++ b/usb.current/usb-yet-another-conexant-clone-to-add-to-cdc-acm.c.patch @@ -0,0 +1,30 @@ +From xiaokj@gmail.com Tue May 12 09:03:33 2009 +From: Xiao Kaijian <xiaokj@gmail.com> +Date: Fri, 8 May 2009 00:48:23 +0800 +Subject: USB: Yet another Conexant Clone to add to cdc-acm.c +To: Greg KH <gregkh@suse.de> +Cc: Oliver Neukum <oliver@neukum.name> +Message-ID: <2e609cef0905070948x5bd5dbd0i2dbe7b4fb02c18b7@mail.gmail.com> + + +This patch adds another quirky Conexant USB Modem Clone to usb cdc-acm.c + +Signed-off-by: Xiao Kaijian <xiaokj@gmail.com> +Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> + +--- + drivers/usb/class/cdc-acm.c | 3 +++ + 1 file changed, 3 insertions(+) + +--- a/drivers/usb/class/cdc-acm.c ++++ b/drivers/usb/class/cdc-acm.c +@@ -1375,6 +1375,9 @@ static struct usb_device_id acm_ids[] = + { USB_DEVICE(0x0572, 0x1324), /* Conexant USB MODEM RD02-D400 */ + .driver_info = NO_UNION_NORMAL, /* has no union descriptor */ + }, ++ { USB_DEVICE(0x0572, 0x1328), /* Shiro / Aztech USB MODEM UM-3100 */ ++ .driver_info = NO_UNION_NORMAL, /* has no union descriptor */ ++ }, + { USB_DEVICE(0x22b8, 0x6425), /* Motorola MOTOMAGX phones */ + }, + { USB_DEVICE(0x0572, 0x1329), /* Hummingbird huc56s (Conexant) */ |
