aboutsummaryrefslogtreecommitdiffstats
path: root/usb.current
diff options
authorGreg Kroah-Hartman <gregkh@suse.de>2009-10-09 11:27:55 -0700
committerGreg Kroah-Hartman <gregkh@suse.de>2009-10-09 11:27:55 -0700
commit18ae79f72ba0aee00036ac3b579dd5a1e753ab98 (patch)
tree4880842cfa3eed60471f38514115ce7aa8749201 /usb.current
parent39803ce38476b33a7dc4d04f0f00da2c9bdaa363 (diff)
downloadpatches-18ae79f72ba0aee00036ac3b579dd5a1e753ab98.tar.gz
usb patches
Diffstat (limited to 'usb.current')
-rw-r--r--usb.current/usb-gadget-imx_udc-use-resource-size.patch50
-rw-r--r--usb.current/usb-isp1362-fix-build-warnings-on-64-bit-systems.patch114
-rw-r--r--usb.current/usb-musb-make-have_clk-support-optional.patch79
-rw-r--r--usb.current/usb-option-patch-for-huawei-mobile-broadband-e270-modem.patch34
-rw-r--r--usb.current/usb-option-toshiba-g450-device-id.patch35
-rw-r--r--usb.current/usb-serial-don-t-call-release-without-attach.patch65
-rw-r--r--usb.current/usb-serial-sierra-driver-version-change-to-1.3.8.patch33
-rw-r--r--usb.current/usb-storage-iriver-p7-unusual_dev-patch.patch33
-rw-r--r--usb.current/usb-usblcd-fix-memory-leak.patch33
-rw-r--r--usb.current/usb-usbtmc-fix-timeout-increase.patch32
-rw-r--r--usb.current/usb-xhci-don-t-wait-for-a-disable-slot-cmd-when-hc-dies.patch47
-rw-r--r--usb.current/usb-xhci-fix-dropping-endpoints-from-the-xhc-schedule.patch31
-rw-r--r--usb.current/usb-xhci-handle-canceled-urbs-when-hc-dies.patch55
-rw-r--r--usb.current/usb-xhci-stop-debugging-polling-loop-when-hc-dies.patch35
14 files changed, 676 insertions, 0 deletions
diff --git a/usb.current/usb-gadget-imx_udc-use-resource-size.patch b/usb.current/usb-gadget-imx_udc-use-resource-size.patch
new file mode 100644
index 00000000000000..aa8d43daead98f
--- /dev/null
+++ b/usb.current/usb-gadget-imx_udc-use-resource-size.patch
@@ -0,0 +1,50 @@
+From tklauser@distanz.ch Fri Oct 9 11:01:57 2009
+From: Tobias Klauser <tklauser@distanz.ch>
+Date: Fri, 18 Sep 2009 09:14:46 +0200
+Subject: USB: gadget: imx_udc: Use resource size
+To: David Brownell <dbrownell@users.sourceforge.net>, Greg Kroah-Hartman <gregkh@suse.de>
+Cc: linux-usb@vger.kernel.org, Tobias Klauser <tklauser@distanz.ch>
+Message-ID: <1253258086-7953-1-git-send-email-tklauser@distanz.ch>
+
+
+Use the resource_size function instead of manually calculating the
+resource size. This reduces the chance of introducing off-by-one errors.
+
+Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/usb/gadget/imx_udc.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+--- a/drivers/usb/gadget/imx_udc.c
++++ b/drivers/usb/gadget/imx_udc.c
+@@ -1402,7 +1402,8 @@ static int __init imx_udc_probe(struct p
+ struct clk *clk;
+ void __iomem *base;
+ int ret = 0;
+- int i, res_size;
++ int i;
++ resource_size_t res_size;
+
+ res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
+ if (!res) {
+@@ -1416,7 +1417,7 @@ static int __init imx_udc_probe(struct p
+ return -ENODEV;
+ }
+
+- res_size = res->end - res->start + 1;
++ res_size = resource_size(res);
+ if (!request_mem_region(res->start, res_size, res->name)) {
+ dev_err(&pdev->dev, "can't allocate %d bytes at %d address\n",
+ res_size, res->start);
+@@ -1527,8 +1528,7 @@ static int __exit imx_udc_remove(struct
+ clk_disable(imx_usb->clk);
+ iounmap(imx_usb->base);
+
+- release_mem_region(imx_usb->res->start,
+- imx_usb->res->end - imx_usb->res->start + 1);
++ release_mem_region(imx_usb->res->start, resource_size(imx_usb->res));
+
+ if (pdata->exit)
+ pdata->exit(&pdev->dev);
diff --git a/usb.current/usb-isp1362-fix-build-warnings-on-64-bit-systems.patch b/usb.current/usb-isp1362-fix-build-warnings-on-64-bit-systems.patch
new file mode 100644
index 00000000000000..1ebf1b9b56923e
--- /dev/null
+++ b/usb.current/usb-isp1362-fix-build-warnings-on-64-bit-systems.patch
@@ -0,0 +1,114 @@
+From vapier@gentoo.org Fri Oct 9 11:23:19 2009
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Wed, 7 Oct 2009 04:29:31 -0400
+Subject: USB: isp1362: fix build warnings on 64-bit systems
+To: linux-usb@vger.kernel.org, Greg Kroah-Hartman <gregkh@suse.de>
+Cc: linux-next@vger.kernel.org, linux-kernel@vger.kernel.org, Lothar Wassmann <LW@karo-electronics.de>, Stephen Rothwell <sfr@canb.auug.org.au>
+Message-ID: <1254904171-5093-1-git-send-email-vapier@gentoo.org>
+
+
+A bunch of places assumed pointers were 32-bits in size (bit checking and
+debug output), but none of these affected runtime functionality.
+
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/usb/host/isp1362-hcd.c | 18 +++++++++---------
+ drivers/usb/host/isp1362.h | 12 ++++++------
+ 2 files changed, 15 insertions(+), 15 deletions(-)
+
+--- a/drivers/usb/host/isp1362.h
++++ b/drivers/usb/host/isp1362.h
+@@ -580,7 +580,7 @@ static inline const char *ISP1362_INT_NA
+
+ static inline void ALIGNSTAT(struct isp1362_hcd *isp1362_hcd, void *ptr)
+ {
+- unsigned p = (unsigned)ptr;
++ unsigned long p = (unsigned long)ptr;
+ if (!(p & 0xf))
+ isp1362_hcd->stat16++;
+ else if (!(p & 0x7))
+@@ -770,7 +770,7 @@ static void isp1362_write_fifo(struct is
+ if (!len)
+ return;
+
+- if ((unsigned)dp & 0x1) {
++ if ((unsigned long)dp & 0x1) {
+ /* not aligned */
+ for (; len > 1; len -= 2) {
+ data = *dp++;
+@@ -962,8 +962,8 @@ static void isp1362_read_buffer(struct i
+
+ isp1362_write_diraddr(isp1362_hcd, offset, len);
+
+- DBG(3, "%s: Reading %d byte from buffer @%04x to memory @ %08x\n", __func__,
+- len, offset, (u32)buf);
++ DBG(3, "%s: Reading %d byte from buffer @%04x to memory @ %p\n",
++ __func__, len, offset, buf);
+
+ isp1362_write_reg16(isp1362_hcd, HCuPINT, HCuPINT_EOT);
+ _WARN_ON((isp1362_read_reg16(isp1362_hcd, HCuPINT) & HCuPINT_EOT));
+@@ -982,8 +982,8 @@ static void isp1362_write_buffer(struct
+
+ isp1362_write_diraddr(isp1362_hcd, offset, len);
+
+- DBG(3, "%s: Writing %d byte to buffer @%04x from memory @ %08x\n", __func__,
+- len, offset, (u32)buf);
++ DBG(3, "%s: Writing %d byte to buffer @%04x from memory @ %p\n",
++ __func__, len, offset, buf);
+
+ isp1362_write_reg16(isp1362_hcd, HCuPINT, HCuPINT_EOT);
+ _WARN_ON((isp1362_read_reg16(isp1362_hcd, HCuPINT) & HCuPINT_EOT));
+--- a/drivers/usb/host/isp1362-hcd.c
++++ b/drivers/usb/host/isp1362-hcd.c
+@@ -2284,10 +2284,10 @@ static int isp1362_mem_config(struct usb
+ dev_info(hcd->self.controller, "ISP1362 Memory usage:\n");
+ dev_info(hcd->self.controller, " ISTL: 2 * %4d: %4d @ $%04x:$%04x\n",
+ istl_size / 2, istl_size, 0, istl_size / 2);
+- dev_info(hcd->self.controller, " INTL: %4d * (%3u+8): %4d @ $%04x\n",
++ dev_info(hcd->self.controller, " INTL: %4d * (%3lu+8): %4d @ $%04x\n",
+ ISP1362_INTL_BUFFERS, intl_blksize - PTD_HEADER_SIZE,
+ intl_size, istl_size);
+- dev_info(hcd->self.controller, " ATL : %4d * (%3u+8): %4d @ $%04x\n",
++ dev_info(hcd->self.controller, " ATL : %4d * (%3lu+8): %4d @ $%04x\n",
+ atl_buffers, atl_blksize - PTD_HEADER_SIZE,
+ atl_size, istl_size + intl_size);
+ dev_info(hcd->self.controller, " USED/FREE: %4d %4d\n", total,
+@@ -2677,12 +2677,12 @@ static int __devexit isp1362_remove(stru
+ DBG(0, "%s: Removing HCD\n", __func__);
+ usb_remove_hcd(hcd);
+
+- DBG(0, "%s: Unmapping data_reg @ %08x\n", __func__,
+- (u32)isp1362_hcd->data_reg);
++ DBG(0, "%s: Unmapping data_reg @ %p\n", __func__,
++ isp1362_hcd->data_reg);
+ iounmap(isp1362_hcd->data_reg);
+
+- DBG(0, "%s: Unmapping addr_reg @ %08x\n", __func__,
+- (u32)isp1362_hcd->addr_reg);
++ DBG(0, "%s: Unmapping addr_reg @ %p\n", __func__,
++ isp1362_hcd->addr_reg);
+ iounmap(isp1362_hcd->addr_reg);
+
+ res = platform_get_resource(pdev, IORESOURCE_MEM, 1);
+@@ -2810,16 +2810,16 @@ static int __init isp1362_probe(struct p
+ return 0;
+
+ err6:
+- DBG(0, "%s: Freeing dev %08x\n", __func__, (u32)isp1362_hcd);
++ DBG(0, "%s: Freeing dev %p\n", __func__, isp1362_hcd);
+ usb_put_hcd(hcd);
+ err5:
+- DBG(0, "%s: Unmapping data_reg @ %08x\n", __func__, (u32)data_reg);
++ DBG(0, "%s: Unmapping data_reg @ %p\n", __func__, data_reg);
+ iounmap(data_reg);
+ err4:
+ DBG(0, "%s: Releasing mem region %08lx\n", __func__, (long unsigned int)data->start);
+ release_mem_region(data->start, resource_len(data));
+ err3:
+- DBG(0, "%s: Unmapping addr_reg @ %08x\n", __func__, (u32)addr_reg);
++ DBG(0, "%s: Unmapping addr_reg @ %p\n", __func__, addr_reg);
+ iounmap(addr_reg);
+ err2:
+ DBG(0, "%s: Releasing mem region %08lx\n", __func__, (long unsigned int)addr->start);
diff --git a/usb.current/usb-musb-make-have_clk-support-optional.patch b/usb.current/usb-musb-make-have_clk-support-optional.patch
new file mode 100644
index 00000000000000..2ffa823ef6068f
--- /dev/null
+++ b/usb.current/usb-musb-make-have_clk-support-optional.patch
@@ -0,0 +1,79 @@
+From vapier@gentoo.org Fri Oct 9 10:44:44 2009
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Wed, 16 Sep 2009 21:10:53 -0400
+Subject: USB: musb: make HAVE_CLK support optional
+To: linux-usb@vger.kernel.org, Felipe Balbi <felipe.balbi@nokia.com>
+Cc: uclinux-dist-devel@blackfin.uclinux.org, linux-kernel@vger.kernel.org, Bryan Wu <cooloney@kernel.org>
+Message-ID: <1253149853-11395-1-git-send-email-vapier@gentoo.org>
+
+
+The Blackfin port doesn't support HAVE_CLK and the musb driver works fine
+with support stubbed out, so take the existing Blackfin clk stubs and move
+them to common musb code so we can drop the Kconfig dependency.
+
+Signed-off-by: Bryan Wu <cooloney@kernel.org>
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/usb/musb/Kconfig | 2 +-
+ drivers/usb/musb/blackfin.c | 1 -
+ drivers/usb/musb/musb_core.h | 7 +++++++
+ drivers/usb/musb/musb_regs.h | 9 ---------
+ 4 files changed, 8 insertions(+), 11 deletions(-)
+
+--- a/drivers/usb/musb/blackfin.c
++++ b/drivers/usb/musb/blackfin.c
+@@ -14,7 +14,6 @@
+ #include <linux/slab.h>
+ #include <linux/init.h>
+ #include <linux/list.h>
+-#include <linux/clk.h>
+ #include <linux/gpio.h>
+ #include <linux/io.h>
+
+--- a/drivers/usb/musb/Kconfig
++++ b/drivers/usb/musb/Kconfig
+@@ -8,7 +8,7 @@ comment "Enable Host or Gadget support t
+
+ # (M)HDRC = (Multipoint) Highspeed Dual-Role Controller
+ config USB_MUSB_HDRC
+- depends on (USB || USB_GADGET) && HAVE_CLK
++ depends on (USB || USB_GADGET)
+ depends on !SUPERH
+ select NOP_USB_XCEIV if ARCH_DAVINCI
+ select TWL4030_USB if MACH_OMAP_3430SDP
+--- a/drivers/usb/musb/musb_core.h
++++ b/drivers/usb/musb/musb_core.h
+@@ -95,6 +95,13 @@ struct musb_ep;
+ #endif
+ #endif /* need MUSB gadget selection */
+
++#ifndef CONFIG_HAVE_CLK
++/* Dummy stub for clk framework */
++#define clk_get(dev, id) NULL
++#define clk_put(clock) do {} while (0)
++#define clk_enable(clock) do {} while (0)
++#define clk_disable(clock) do {} while (0)
++#endif
+
+ #ifdef CONFIG_PROC_FS
+ #include <linux/fs.h>
+--- a/drivers/usb/musb/musb_regs.h
++++ b/drivers/usb/musb/musb_regs.h
+@@ -439,15 +439,6 @@ static inline void musb_write_txhubport
+ /* Not implemented - HW has seperate Tx/Rx FIFO */
+ #define MUSB_TXCSR_MODE 0x0000
+
+-/*
+- * Dummy stub for clk framework, it will be removed
+- * until Blackfin supports clk framework
+- */
+-#define clk_get(dev, id) NULL
+-#define clk_put(clock) do {} while (0)
+-#define clk_enable(clock) do {} while (0)
+-#define clk_disable(clock) do {} while (0)
+-
+ static inline void musb_write_txfifosz(void __iomem *mbase, u8 c_size)
+ {
+ }
diff --git a/usb.current/usb-option-patch-for-huawei-mobile-broadband-e270-modem.patch b/usb.current/usb-option-patch-for-huawei-mobile-broadband-e270-modem.patch
new file mode 100644
index 00000000000000..568ed61f819629
--- /dev/null
+++ b/usb.current/usb-option-patch-for-huawei-mobile-broadband-e270-modem.patch
@@ -0,0 +1,34 @@
+From rofu7@hotmail.com Fri Oct 9 10:59:05 2009
+From: Ronnie Furuskog <rofu7@hotmail.com>
+Date: Mon, 21 Sep 2009 21:20:55 +0200
+Subject: USB: option: Patch for Huawei Mobile Broadband E270+ Modem
+To: <greg@kroah.com>
+Message-ID: <BAY131-W11E86978BB7AC1D49B271CF6DD0@phx.gbl>
+
+
+From: Ronnie Furuskog <rofu7@hotmail.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+
+---
+ drivers/usb/serial/option.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+--- a/drivers/usb/serial/option.c
++++ b/drivers/usb/serial/option.c
+@@ -165,6 +165,7 @@ static int option_resume(struct usb_ser
+ #define HUAWEI_PRODUCT_E143D 0x143D
+ #define HUAWEI_PRODUCT_E143E 0x143E
+ #define HUAWEI_PRODUCT_E143F 0x143F
++#define HUAWEI_PRODUCT_E14AC 0x14AC
+
+ #define QUANTA_VENDOR_ID 0x0408
+ #define QUANTA_PRODUCT_Q101 0xEA02
+@@ -425,6 +426,7 @@ static struct usb_device_id option_ids[]
+ { USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, HUAWEI_PRODUCT_E143D, 0xff, 0xff, 0xff) },
+ { USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, HUAWEI_PRODUCT_E143E, 0xff, 0xff, 0xff) },
+ { USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, HUAWEI_PRODUCT_E143F, 0xff, 0xff, 0xff) },
++ { USB_DEVICE(HUAWEI_VENDOR_ID, HUAWEI_PRODUCT_E14AC) },
+ { USB_DEVICE(AMOI_VENDOR_ID, AMOI_PRODUCT_9508) },
+ { USB_DEVICE(NOVATELWIRELESS_VENDOR_ID, NOVATELWIRELESS_PRODUCT_V640) }, /* Novatel Merlin V640/XV620 */
+ { USB_DEVICE(NOVATELWIRELESS_VENDOR_ID, NOVATELWIRELESS_PRODUCT_V620) }, /* Novatel Merlin V620/S620 */
diff --git a/usb.current/usb-option-toshiba-g450-device-id.patch b/usb.current/usb-option-toshiba-g450-device-id.patch
new file mode 100644
index 00000000000000..ba8fccdf25d52f
--- /dev/null
+++ b/usb.current/usb-option-toshiba-g450-device-id.patch
@@ -0,0 +1,35 @@
+From peter@magdina.sk Fri Oct 9 10:26:04 2009
+From: Peter Magdina <peter@magdina.sk>
+Date: Wed, 7 Oct 2009 16:22:17 +0200
+Subject: USB: option: Toshiba G450 device id
+To: Alan Stern <stern@rowland.harvard.edu>
+Cc: Josua Dietze <digidietze@draisberghof.de>, Greg KH <greg@kroah.com>, Phil Dibowitz <phil@ipom.com>, Matthew Dharm <mdharm-usb@one-eyed-alien.net>
+Message-ID: <200910071622.17336.peter@magdina.sk>
+
+
+Signed-off-by: Peter Magdina <peter@magdina.sk>
+Cc: stable <stable@kernel.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/usb/serial/option.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+--- a/drivers/usb/serial/option.c
++++ b/drivers/usb/serial/option.c
+@@ -318,6 +318,7 @@ static int option_resume(struct usb_ser
+ /* TOSHIBA PRODUCTS */
+ #define TOSHIBA_VENDOR_ID 0x0930
+ #define TOSHIBA_PRODUCT_HSDPA_MINICARD 0x1302
++#define TOSHIBA_PRODUCT_G450 0x0d45
+
+ #define ALINK_VENDOR_ID 0x1e0e
+ #define ALINK_PRODUCT_3GU 0x9200
+@@ -581,6 +582,7 @@ static struct usb_device_id option_ids[]
+ { USB_DEVICE(QISDA_VENDOR_ID, QISDA_PRODUCT_H21_4523) },
+ { USB_DEVICE(QISDA_VENDOR_ID, QISDA_PRODUCT_H20_4515) },
+ { USB_DEVICE(QISDA_VENDOR_ID, QISDA_PRODUCT_H20_4519) },
++ { USB_DEVICE(TOSHIBA_VENDOR_ID, TOSHIBA_PRODUCT_G450) },
+ { USB_DEVICE(TOSHIBA_VENDOR_ID, TOSHIBA_PRODUCT_HSDPA_MINICARD ) }, /* Toshiba 3G HSDPA == Novatel Expedite EU870D MiniCard */
+ { USB_DEVICE(ALINK_VENDOR_ID, 0x9000) },
+ { USB_DEVICE_AND_INTERFACE_INFO(ALINK_VENDOR_ID, ALINK_PRODUCT_3GU, 0xff, 0xff, 0xff) },
diff --git a/usb.current/usb-serial-don-t-call-release-without-attach.patch b/usb.current/usb-serial-don-t-call-release-without-attach.patch
new file mode 100644
index 00000000000000..719d0e35a0276b
--- /dev/null
+++ b/usb.current/usb-serial-don-t-call-release-without-attach.patch
@@ -0,0 +1,65 @@
+From stern@rowland.harvard.edu Fri Oct 9 10:24:31 2009
+From: Alan Stern <stern@rowland.harvard.edu>
+Date: Fri, 9 Oct 2009 12:43:12 -0400 (EDT)
+Subject: USB: serial: don't call release without attach
+To: Greg KH <greg@kroah.com>
+Message-ID: <Pine.LNX.4.44L0.0910091242120.3007-100000@iolanthe.rowland.org>
+
+
+This patch (as1295) fixes a recently-added bug in the USB serial core.
+If certain kinds of errors occur during probing, the core may call a
+serial driver's release method without previously calling the attach
+method. This causes some drivers (io_ti in particular) to perform an
+invalid memory access.
+
+The patch adds a new flag to keep track of whether or not attach has
+been called.
+
+Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
+Tested-by: Jean-Denis Girard <jd.girard@sysnux.pf>
+CC: stable <stable@kernel.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/usb/serial/usb-serial.c | 6 +++++-
+ include/linux/usb/serial.h | 1 +
+ 2 files changed, 6 insertions(+), 1 deletion(-)
+
+--- a/drivers/usb/serial/usb-serial.c
++++ b/drivers/usb/serial/usb-serial.c
+@@ -156,7 +156,8 @@ static void destroy_serial(struct kref *
+ if (serial->minor != SERIAL_TTY_NO_MINOR)
+ return_serial(serial);
+
+- serial->type->release(serial);
++ if (serial->attached)
++ serial->type->release(serial);
+
+ /* Now that nothing is using the ports, they can be freed */
+ for (i = 0; i < serial->num_port_pointers; ++i) {
+@@ -1059,12 +1060,15 @@ int usb_serial_probe(struct usb_interfac
+ module_put(type->driver.owner);
+ if (retval < 0)
+ goto probe_error;
++ serial->attached = 1;
+ if (retval > 0) {
+ /* quietly accept this device, but don't bind to a
+ serial port as it's about to disappear */
+ serial->num_ports = 0;
+ goto exit;
+ }
++ } else {
++ serial->attached = 1;
+ }
+
+ if (get_free_serial(serial, num_ports, &minor) == NULL) {
+--- a/include/linux/usb/serial.h
++++ b/include/linux/usb/serial.h
+@@ -150,6 +150,7 @@ struct usb_serial {
+ struct usb_interface *interface;
+ unsigned char disconnected:1;
+ unsigned char suspending:1;
++ unsigned char attached:1;
+ unsigned char minor;
+ unsigned char num_ports;
+ unsigned char num_port_pointers;
diff --git a/usb.current/usb-serial-sierra-driver-version-change-to-1.3.8.patch b/usb.current/usb-serial-sierra-driver-version-change-to-1.3.8.patch
new file mode 100644
index 00000000000000..353bcfe0d04fc1
--- /dev/null
+++ b/usb.current/usb-serial-sierra-driver-version-change-to-1.3.8.patch
@@ -0,0 +1,33 @@
+From epasheva@sierrawireless.com Fri Oct 9 11:01:26 2009
+From: Elina Pasheva <epasheva@sierrawireless.com>
+Date: Thu, 17 Sep 2009 15:26:20 -0700
+Subject: USB: serial: sierra driver version change to 1.3.8
+To: "gregkh@suse.de" <gregkh@suse.de>
+Cc: <epasheva@sierrawireless.com>, <rfiler@sierrawireless.com>, Oliver Neukum <oliver@neukum.org>
+Message-ID: <1253226380.23934.4.camel@Linuxdev3>
+
+
+Subject: [PATCH 001/001] USB: serial: sierra driver version change to 1.3.8
+From: Elina Pasheva <epasheva@sierrawireless.com>
+
+Updated sierra driver version from 1.3.7 to 1.3.8 now that the autosuspend
+capabilities were added to the driver.
+
+Signed-off-by: Elina Pasheva <epasheva@sierrawireless.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/usb/serial/sierra.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/drivers/usb/serial/sierra.c
++++ b/drivers/usb/serial/sierra.c
+@@ -17,7 +17,7 @@
+ Whom based his on the Keyspan driver by Hugh Blemings <hugh@blemings.org>
+ */
+
+-#define DRIVER_VERSION "v.1.3.7"
++#define DRIVER_VERSION "v.1.3.8"
+ #define DRIVER_AUTHOR "Kevin Lloyd, Elina Pasheva, Matthew Safar, Rory Filer"
+ #define DRIVER_DESC "USB Driver for Sierra Wireless USB modems"
+
diff --git a/usb.current/usb-storage-iriver-p7-unusual_dev-patch.patch b/usb.current/usb-storage-iriver-p7-unusual_dev-patch.patch
new file mode 100644
index 00000000000000..75b51340002146
--- /dev/null
+++ b/usb.current/usb-storage-iriver-p7-unusual_dev-patch.patch
@@ -0,0 +1,33 @@
+From dfo@antex.ru Fri Oct 9 11:00:36 2009
+From: Sergey Pinaev <dfo@antex.ru>
+Date: Thu, 17 Sep 2009 17:26:50 +0400
+Subject: USB: storage: iRiver P7 UNUSUAL_DEV patch
+To: Phil Dibowitz <phil@ipom.com>
+Cc: linux-usb@vger.kernel.org, usb-storage@lists.one-eyed-alien.net
+Message-ID: <20090917172650.125b356f.dfo@antex.ru>
+
+
+From: Sergey Pinaev <dfo@antex.ru>
+Signed-off-by: Phil Dibowitz <phil@ipom.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/usb/storage/unusual_devs.h | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+--- a/drivers/usb/storage/unusual_devs.h
++++ b/drivers/usb/storage/unusual_devs.h
+@@ -1823,6 +1823,13 @@ UNUSUAL_DEV( 0x4102, 0x1020, 0x0100, 0
+ US_SC_DEVICE, US_PR_DEVICE, NULL,
+ US_FL_IGNORE_RESIDUE ),
+
++/* Reported by Sergey Pinaev <dfo@antex.ru> */
++UNUSUAL_DEV( 0x4102, 0x1059, 0x0000, 0x0000,
++ "iRiver",
++ "P7K",
++ US_SC_DEVICE, US_PR_DEVICE, NULL,
++ US_FL_MAX_SECTORS_64 ),
++
+ /*
+ * David Härdeman <david@2gen.com>
+ * The key makes the SCSI stack print confusing (but harmless) messages
diff --git a/usb.current/usb-usblcd-fix-memory-leak.patch b/usb.current/usb-usblcd-fix-memory-leak.patch
new file mode 100644
index 00000000000000..564117394d2328
--- /dev/null
+++ b/usb.current/usb-usblcd-fix-memory-leak.patch
@@ -0,0 +1,33 @@
+From jirislaby@gmail.com Fri Oct 9 10:25:05 2009
+From: Jiri Slaby <jirislaby@gmail.com>
+Date: Wed, 23 Sep 2009 16:09:56 +0200
+Subject: USB: usblcd, fix memory leak
+To: gregkh@suse.de
+Cc: linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, Jiri Slaby <jirislaby@gmail.com>
+Message-ID: <1253714996-6495-1-git-send-email-jirislaby@gmail.com>
+
+
+Stanse found a memory leak in lcd_probe. Instead of returning without
+releasing the memory, jump to the error label which frees it.
+
+http://stanse.fi.muni.cz/
+
+Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/usb/misc/usblcd.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+--- a/drivers/usb/misc/usblcd.c
++++ b/drivers/usb/misc/usblcd.c
+@@ -313,7 +313,8 @@ static int lcd_probe(struct usb_interfac
+
+ if (le16_to_cpu(dev->udev->descriptor.idProduct) != 0x0001) {
+ dev_warn(&interface->dev, "USBLCD model not supported.\n");
+- return -ENODEV;
++ retval = -ENODEV;
++ goto error;
+ }
+
+ /* set up the endpoint information */
diff --git a/usb.current/usb-usbtmc-fix-timeout-increase.patch b/usb.current/usb-usbtmc-fix-timeout-increase.patch
new file mode 100644
index 00000000000000..f4db4a21a2a320
--- /dev/null
+++ b/usb.current/usb-usbtmc-fix-timeout-increase.patch
@@ -0,0 +1,32 @@
+From imrehg@gmail.com Fri Oct 9 10:32:19 2009
+From: Gergely Imreh <imrehg@gmail.com>
+Date: Tue, 15 Sep 2009 16:03:31 +0800
+Subject: USB: usbtmc: fix timeout increase
+To: Greg KH <greg@kroah.com>
+Cc: "linux-usb@vger.kernel.org" <linux-usb@vger.kernel.org>
+Message-ID: <371b60070909150103t2e2058f5ua819ab3300d47144@mail.gmail.com>
+
+From: Gergely Imreh <imrehg@gmail.com>
+
+The current 10ms timeout is too short for some normal USBTMC device
+operation, increase it to a value which was tested with previously
+affected Tektronix oscilloscopes.
+
+Signed-off-by: Gergely Imreh <imrehg@gmail.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/usb/class/usbtmc.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/drivers/usb/class/usbtmc.c
++++ b/drivers/usb/class/usbtmc.c
+@@ -39,7 +39,7 @@
+ #define USBTMC_SIZE_IOBUFFER 2048
+
+ /* Default USB timeout (in milliseconds) */
+-#define USBTMC_TIMEOUT 10
++#define USBTMC_TIMEOUT 5000
+
+ /*
+ * Maximum number of read cycles to empty bulk in endpoint during CLEAR and
diff --git a/usb.current/usb-xhci-don-t-wait-for-a-disable-slot-cmd-when-hc-dies.patch b/usb.current/usb-xhci-don-t-wait-for-a-disable-slot-cmd-when-hc-dies.patch
new file mode 100644
index 00000000000000..2300ea4238cace
--- /dev/null
+++ b/usb.current/usb-xhci-don-t-wait-for-a-disable-slot-cmd-when-hc-dies.patch
@@ -0,0 +1,47 @@
+From sarah.a.sharp@linux.intel.com Fri Oct 9 10:38:51 2009
+From: Sarah Sharp <sarah.a.sharp@linux.intel.com>
+Date: Wed, 16 Sep 2009 16:42:39 -0700
+Subject: USB: xhci: Don't wait for a disable slot cmd when HC dies.
+To: Greg KH <gregkh@suse.de>
+Cc: linux-usb@vger.kernel.org
+Message-ID: <20090916234239.GA16810@xanatos>
+Content-Disposition: inline
+
+
+When the host controller dies or is removed while a device is plugged in,
+the USB core will attempt to deallocate the struct usb_device. That will
+call into xhci_free_dev(). This function used to attempt to submit a
+disable slot command to the host controller and clean up the device
+structures when that command returned. Change xhci_free_dev() to skip the
+command submission and just free the memory if the host controller died.
+
+Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/usb/host/xhci-hcd.c | 9 +++++++++
+ 1 file changed, 9 insertions(+)
+
+--- a/drivers/usb/host/xhci-hcd.c
++++ b/drivers/usb/host/xhci-hcd.c
+@@ -1428,11 +1428,20 @@ void xhci_free_dev(struct usb_hcd *hcd,
+ {
+ struct xhci_hcd *xhci = hcd_to_xhci(hcd);
+ unsigned long flags;
++ u32 state;
+
+ if (udev->slot_id == 0)
+ return;
+
+ spin_lock_irqsave(&xhci->lock, flags);
++ /* Don't disable the slot if the host controller is dead. */
++ state = xhci_readl(xhci, &xhci->op_regs->status);
++ if (state == 0xffffffff) {
++ xhci_free_virt_device(xhci, udev->slot_id);
++ spin_unlock_irqrestore(&xhci->lock, flags);
++ return;
++ }
++
+ if (xhci_queue_slot_control(xhci, TRB_DISABLE_SLOT, udev->slot_id)) {
+ spin_unlock_irqrestore(&xhci->lock, flags);
+ xhci_dbg(xhci, "FIXME: allocate a command ring segment\n");
diff --git a/usb.current/usb-xhci-fix-dropping-endpoints-from-the-xhc-schedule.patch b/usb.current/usb-xhci-fix-dropping-endpoints-from-the-xhc-schedule.patch
new file mode 100644
index 00000000000000..f58d1b7b2419b5
--- /dev/null
+++ b/usb.current/usb-xhci-fix-dropping-endpoints-from-the-xhc-schedule.patch
@@ -0,0 +1,31 @@
+From sarah.a.sharp@linux.intel.com Fri Oct 9 10:39:12 2009
+From: Sarah Sharp <sarah.a.sharp@linux.intel.com>
+Date: Fri, 18 Sep 2009 08:55:12 -0700
+Subject: USB: xhci: Fix dropping endpoints from the xHC schedule.
+To: Greg KH <gregkh@suse.de>
+Cc: linux-usb@vger.kernel.org
+Message-ID: <20090918155512.GA3876@xanatos>
+Content-Disposition: inline
+
+
+When an endpoint is to be dropped from the hardware bandwidth schedule, we
+want to clear its add flag.
+
+Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/usb/host/xhci-hcd.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/drivers/usb/host/xhci-hcd.c
++++ b/drivers/usb/host/xhci-hcd.c
+@@ -895,7 +895,7 @@ int xhci_drop_endpoint(struct usb_hcd *h
+ ctrl_ctx->drop_flags |= drop_flag;
+ new_drop_flags = ctrl_ctx->drop_flags;
+
+- ctrl_ctx->add_flags = ~drop_flag;
++ ctrl_ctx->add_flags &= ~drop_flag;
+ new_add_flags = ctrl_ctx->add_flags;
+
+ last_ctx = xhci_last_valid_endpoint(ctrl_ctx->add_flags);
diff --git a/usb.current/usb-xhci-handle-canceled-urbs-when-hc-dies.patch b/usb.current/usb-xhci-handle-canceled-urbs-when-hc-dies.patch
new file mode 100644
index 00000000000000..5c5dc35ca58453
--- /dev/null
+++ b/usb.current/usb-xhci-handle-canceled-urbs-when-hc-dies.patch
@@ -0,0 +1,55 @@
+From sarah.a.sharp@linux.intel.com Fri Oct 9 10:38:36 2009
+From: Sarah Sharp <sarah.a.sharp@linux.intel.com>
+Date: Mon, 28 Sep 2009 17:21:37 -0700
+Subject: USB: xhci: Handle canceled URBs when HC dies.
+To: Greg KH <gregkh@suse.de>
+Cc: Oliver Neukum <oliver@neukum.org>, linux-usb@vger.kernel.org
+Message-ID: <20090929002137.GA7755@gamba.jf.intel.com>
+Content-Disposition: inline
+
+
+When the host controller dies (e.g. it is removed from a PCI card slot),
+the xHCI driver cannot expect commands to complete. The buggy code this
+patch fixes would mark an URB as canceled and then expect the URB to be
+completed when the stop endpoint command completed. That would never
+happen if the host controller was dead, so the USB core would just hang in
+the disconnect code.
+
+If the host controller died, and the driver asks to cancel an URB, free
+any structures associated with that URB and immediately give it back.
+
+Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/usb/host/xhci-hcd.c | 12 ++++++++++++
+ 1 file changed, 12 insertions(+)
+
+--- a/drivers/usb/host/xhci-hcd.c
++++ b/drivers/usb/host/xhci-hcd.c
+@@ -782,6 +782,7 @@ int xhci_urb_dequeue(struct usb_hcd *hcd
+ {
+ unsigned long flags;
+ int ret;
++ u32 temp;
+ struct xhci_hcd *xhci;
+ struct xhci_td *td;
+ unsigned int ep_index;
+@@ -794,6 +795,17 @@ int xhci_urb_dequeue(struct usb_hcd *hcd
+ ret = usb_hcd_check_unlink_urb(hcd, urb, status);
+ if (ret || !urb->hcpriv)
+ goto done;
++ temp = xhci_readl(xhci, &xhci->op_regs->status);
++ if (temp == 0xffffffff) {
++ xhci_dbg(xhci, "HW died, freeing TD.\n");
++ td = (struct xhci_td *) urb->hcpriv;
++
++ usb_hcd_unlink_urb_from_ep(hcd, urb);
++ spin_unlock_irqrestore(&xhci->lock, flags);
++ usb_hcd_giveback_urb(xhci_to_hcd(xhci), urb, -ESHUTDOWN);
++ kfree(td);
++ return ret;
++ }
+
+ xhci_dbg(xhci, "Cancel URB %p\n", urb);
+ xhci_dbg(xhci, "Event ring:\n");
diff --git a/usb.current/usb-xhci-stop-debugging-polling-loop-when-hc-dies.patch b/usb.current/usb-xhci-stop-debugging-polling-loop-when-hc-dies.patch
new file mode 100644
index 00000000000000..1de437043a8856
--- /dev/null
+++ b/usb.current/usb-xhci-stop-debugging-polling-loop-when-hc-dies.patch
@@ -0,0 +1,35 @@
+From sarah.a.sharp@linux.intel.com Fri Oct 9 10:38:18 2009
+From: Sarah Sharp <sarah.a.sharp@linux.intel.com>
+Date: Wed, 16 Sep 2009 16:42:30 -0700
+Subject: USB: xhci: Stop debugging polling loop when HC dies.
+To: Greg KH <gregkh@suse.de>
+Cc: linux-usb@vger.kernel.org
+Message-ID: <20090916234230.GA16784@xanatos>
+Content-Disposition: inline
+
+
+If the host controller card is removed from the system, stop the timer
+function to debug the xHCI rings.
+
+Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/usb/host/xhci-hcd.c | 6 ++++++
+ 1 file changed, 6 insertions(+)
+
+--- a/drivers/usb/host/xhci-hcd.c
++++ b/drivers/usb/host/xhci-hcd.c
+@@ -335,6 +335,12 @@ void xhci_event_ring_work(unsigned long
+ spin_lock_irqsave(&xhci->lock, flags);
+ temp = xhci_readl(xhci, &xhci->op_regs->status);
+ xhci_dbg(xhci, "op reg status = 0x%x\n", temp);
++ if (temp == 0xffffffff) {
++ xhci_dbg(xhci, "HW died, polling stopped.\n");
++ spin_unlock_irqrestore(&xhci->lock, flags);
++ return;
++ }
++
+ temp = xhci_readl(xhci, &xhci->ir_set->irq_pending);
+ xhci_dbg(xhci, "ir_set 0 pending = 0x%x\n", temp);
+ xhci_dbg(xhci, "No-op commands handled = %d\n", xhci->noops_handled);