diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-12-01 10:58:49 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-12-01 10:58:49 -0500 |
commit | b4dcfbee3b536c9125762e8f6681ac6be0e9256b (patch) | |
tree | 9beab6548a25710d1d8f950cadc0abbea754fa56 | |
parent | ecf318cc3daee6f41354cc781e2d4b766f7eec3e (diff) | |
parent | 5bb4bd9895df508ed2bd8b3280252d8a8170e4ac (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6:
USB: serial: add more Onda device ids to option driver
USB: usb-storage: unusual_devs entry for Nikon D2H
USB: storage: unusual_devs entry for Mio C520-GPS
USB: fsl_usb2_udc: Report disconnect before unbinding
USB: fsl_qe_udc: Report disconnect before unbinding
USB: fix SB600 USB subsystem hang bug
Revert "USB: improve ehci_watchdog's side effect in CPU power management"
-rw-r--r-- | drivers/usb/gadget/fsl_qe_udc.c | 3 | ||||
-rw-r--r-- | drivers/usb/gadget/fsl_usb2_udc.c | 3 | ||||
-rw-r--r-- | drivers/usb/host/ehci-pci.c | 9 | ||||
-rw-r--r-- | drivers/usb/host/ehci.h | 12 | ||||
-rw-r--r-- | drivers/usb/serial/option.c | 35 | ||||
-rw-r--r-- | drivers/usb/storage/unusual_devs.h | 19 |
6 files changed, 71 insertions, 10 deletions
diff --git a/drivers/usb/gadget/fsl_qe_udc.c b/drivers/usb/gadget/fsl_qe_udc.c index 1fe8b44787b3..b3408ff39fba 100644 --- a/drivers/usb/gadget/fsl_qe_udc.c +++ b/drivers/usb/gadget/fsl_qe_udc.c | |||
@@ -2363,6 +2363,9 @@ int usb_gadget_unregister_driver(struct usb_gadget_driver *driver) | |||
2363 | nuke(loop_ep, -ESHUTDOWN); | 2363 | nuke(loop_ep, -ESHUTDOWN); |
2364 | spin_unlock_irqrestore(&udc_controller->lock, flags); | 2364 | spin_unlock_irqrestore(&udc_controller->lock, flags); |
2365 | 2365 | ||
2366 | /* report disconnect; the controller is already quiesced */ | ||
2367 | driver->disconnect(&udc_controller->gadget); | ||
2368 | |||
2366 | /* unbind gadget and unhook driver. */ | 2369 | /* unbind gadget and unhook driver. */ |
2367 | driver->unbind(&udc_controller->gadget); | 2370 | driver->unbind(&udc_controller->gadget); |
2368 | udc_controller->gadget.dev.driver = NULL; | 2371 | udc_controller->gadget.dev.driver = NULL; |
diff --git a/drivers/usb/gadget/fsl_usb2_udc.c b/drivers/usb/gadget/fsl_usb2_udc.c index 091bb55c9aa7..f3c6703cffda 100644 --- a/drivers/usb/gadget/fsl_usb2_udc.c +++ b/drivers/usb/gadget/fsl_usb2_udc.c | |||
@@ -1836,6 +1836,9 @@ int usb_gadget_unregister_driver(struct usb_gadget_driver *driver) | |||
1836 | nuke(loop_ep, -ESHUTDOWN); | 1836 | nuke(loop_ep, -ESHUTDOWN); |
1837 | spin_unlock_irqrestore(&udc_controller->lock, flags); | 1837 | spin_unlock_irqrestore(&udc_controller->lock, flags); |
1838 | 1838 | ||
1839 | /* report disconnect; the controller is already quiesced */ | ||
1840 | driver->disconnect(&udc_controller->gadget); | ||
1841 | |||
1839 | /* unbind gadget and unhook driver. */ | 1842 | /* unbind gadget and unhook driver. */ |
1840 | driver->unbind(&udc_controller->gadget); | 1843 | driver->unbind(&udc_controller->gadget); |
1841 | udc_controller->gadget.dev.driver = NULL; | 1844 | udc_controller->gadget.dev.driver = NULL; |
diff --git a/drivers/usb/host/ehci-pci.c b/drivers/usb/host/ehci-pci.c index 9d0ea573aef6..36864f958444 100644 --- a/drivers/usb/host/ehci-pci.c +++ b/drivers/usb/host/ehci-pci.c | |||
@@ -169,18 +169,21 @@ static int ehci_pci_setup(struct usb_hcd *hcd) | |||
169 | } | 169 | } |
170 | break; | 170 | break; |
171 | case PCI_VENDOR_ID_ATI: | 171 | case PCI_VENDOR_ID_ATI: |
172 | /* SB700 old version has a bug in EHCI controller, | 172 | /* SB600 and old version of SB700 have a bug in EHCI controller, |
173 | * which causes usb devices lose response in some cases. | 173 | * which causes usb devices lose response in some cases. |
174 | */ | 174 | */ |
175 | if (pdev->device == 0x4396) { | 175 | if ((pdev->device == 0x4386) || (pdev->device == 0x4396)) { |
176 | p_smbus = pci_get_device(PCI_VENDOR_ID_ATI, | 176 | p_smbus = pci_get_device(PCI_VENDOR_ID_ATI, |
177 | PCI_DEVICE_ID_ATI_SBX00_SMBUS, | 177 | PCI_DEVICE_ID_ATI_SBX00_SMBUS, |
178 | NULL); | 178 | NULL); |
179 | if (!p_smbus) | 179 | if (!p_smbus) |
180 | break; | 180 | break; |
181 | rev = p_smbus->revision; | 181 | rev = p_smbus->revision; |
182 | if ((rev == 0x3a) || (rev == 0x3b)) { | 182 | if ((pdev->device == 0x4386) || (rev == 0x3a) |
183 | || (rev == 0x3b)) { | ||
183 | u8 tmp; | 184 | u8 tmp; |
185 | ehci_info(ehci, "applying AMD SB600/SB700 USB " | ||
186 | "freeze workaround\n"); | ||
184 | pci_read_config_byte(pdev, 0x53, &tmp); | 187 | pci_read_config_byte(pdev, 0x53, &tmp); |
185 | pci_write_config_byte(pdev, 0x53, tmp | (1<<3)); | 188 | pci_write_config_byte(pdev, 0x53, tmp | (1<<3)); |
186 | } | 189 | } |
diff --git a/drivers/usb/host/ehci.h b/drivers/usb/host/ehci.h index b11798d17ae5..c7d4b5a06bdb 100644 --- a/drivers/usb/host/ehci.h +++ b/drivers/usb/host/ehci.h | |||
@@ -183,16 +183,14 @@ timer_action (struct ehci_hcd *ehci, enum ehci_timer_action action) | |||
183 | * the async ring; just the I/O watchdog. Note that if a | 183 | * the async ring; just the I/O watchdog. Note that if a |
184 | * SHRINK were pending, OFF would never be requested. | 184 | * SHRINK were pending, OFF would never be requested. |
185 | */ | 185 | */ |
186 | enum ehci_timer_action oldactions = ehci->actions; | 186 | if (timer_pending(&ehci->watchdog) |
187 | && ((BIT(TIMER_ASYNC_SHRINK) | BIT(TIMER_ASYNC_OFF)) | ||
188 | & ehci->actions)) | ||
189 | return; | ||
187 | 190 | ||
188 | if (!test_and_set_bit (action, &ehci->actions)) { | 191 | if (!test_and_set_bit (action, &ehci->actions)) { |
189 | unsigned long t; | 192 | unsigned long t; |
190 | 193 | ||
191 | if (timer_pending(&ehci->watchdog) | ||
192 | && ((BIT(TIMER_ASYNC_SHRINK) | BIT(TIMER_ASYNC_OFF)) | ||
193 | & oldactions)) | ||
194 | return; | ||
195 | |||
196 | switch (action) { | 194 | switch (action) { |
197 | case TIMER_IO_WATCHDOG: | 195 | case TIMER_IO_WATCHDOG: |
198 | t = EHCI_IO_JIFFIES; | 196 | t = EHCI_IO_JIFFIES; |
@@ -208,7 +206,7 @@ timer_action (struct ehci_hcd *ehci, enum ehci_timer_action action) | |||
208 | t = DIV_ROUND_UP(EHCI_SHRINK_FRAMES * HZ, 1000) + 1; | 206 | t = DIV_ROUND_UP(EHCI_SHRINK_FRAMES * HZ, 1000) + 1; |
209 | break; | 207 | break; |
210 | } | 208 | } |
211 | mod_timer(&ehci->watchdog, round_jiffies(t + jiffies)); | 209 | mod_timer(&ehci->watchdog, t + jiffies); |
212 | } | 210 | } |
213 | } | 211 | } |
214 | 212 | ||
diff --git a/drivers/usb/serial/option.c b/drivers/usb/serial/option.c index 6fa1ec441b61..809697b3c7fc 100644 --- a/drivers/usb/serial/option.c +++ b/drivers/usb/serial/option.c | |||
@@ -224,6 +224,7 @@ static int option_send_setup(struct tty_struct *tty, struct usb_serial_port *po | |||
224 | #define ONDA_VENDOR_ID 0x19d2 | 224 | #define ONDA_VENDOR_ID 0x19d2 |
225 | #define ONDA_PRODUCT_MSA501HS 0x0001 | 225 | #define ONDA_PRODUCT_MSA501HS 0x0001 |
226 | #define ONDA_PRODUCT_ET502HS 0x0002 | 226 | #define ONDA_PRODUCT_ET502HS 0x0002 |
227 | #define ONDA_PRODUCT_MT503HS 0x0200 | ||
227 | 228 | ||
228 | #define BANDRICH_VENDOR_ID 0x1A8D | 229 | #define BANDRICH_VENDOR_ID 0x1A8D |
229 | #define BANDRICH_PRODUCT_C100_1 0x1002 | 230 | #define BANDRICH_PRODUCT_C100_1 0x1002 |
@@ -413,6 +414,40 @@ static struct usb_device_id option_ids[] = { | |||
413 | { USB_DEVICE(AXESSTEL_VENDOR_ID, AXESSTEL_PRODUCT_MV110H) }, | 414 | { USB_DEVICE(AXESSTEL_VENDOR_ID, AXESSTEL_PRODUCT_MV110H) }, |
414 | { USB_DEVICE(ONDA_VENDOR_ID, ONDA_PRODUCT_MSA501HS) }, | 415 | { USB_DEVICE(ONDA_VENDOR_ID, ONDA_PRODUCT_MSA501HS) }, |
415 | { USB_DEVICE(ONDA_VENDOR_ID, ONDA_PRODUCT_ET502HS) }, | 416 | { USB_DEVICE(ONDA_VENDOR_ID, ONDA_PRODUCT_ET502HS) }, |
417 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0003) }, | ||
418 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0004) }, | ||
419 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0005) }, | ||
420 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0006) }, | ||
421 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0007) }, | ||
422 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0008) }, | ||
423 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0009) }, | ||
424 | { USB_DEVICE(ONDA_VENDOR_ID, 0x000a) }, | ||
425 | { USB_DEVICE(ONDA_VENDOR_ID, 0x000b) }, | ||
426 | { USB_DEVICE(ONDA_VENDOR_ID, 0x000c) }, | ||
427 | { USB_DEVICE(ONDA_VENDOR_ID, 0x000d) }, | ||
428 | { USB_DEVICE(ONDA_VENDOR_ID, 0x000e) }, | ||
429 | { USB_DEVICE(ONDA_VENDOR_ID, 0x000f) }, | ||
430 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0010) }, | ||
431 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0011) }, | ||
432 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0012) }, | ||
433 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0013) }, | ||
434 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0014) }, | ||
435 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0015) }, | ||
436 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0016) }, | ||
437 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0017) }, | ||
438 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0018) }, | ||
439 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0019) }, | ||
440 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0020) }, | ||
441 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0021) }, | ||
442 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0022) }, | ||
443 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0023) }, | ||
444 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0024) }, | ||
445 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0025) }, | ||
446 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0026) }, | ||
447 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0027) }, | ||
448 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0028) }, | ||
449 | { USB_DEVICE(ONDA_VENDOR_ID, 0x0029) }, | ||
450 | { USB_DEVICE(ONDA_VENDOR_ID, ONDA_PRODUCT_MT503HS) }, | ||
416 | { USB_DEVICE(YISO_VENDOR_ID, YISO_PRODUCT_U893) }, | 451 | { USB_DEVICE(YISO_VENDOR_ID, YISO_PRODUCT_U893) }, |
417 | { USB_DEVICE(BANDRICH_VENDOR_ID, BANDRICH_PRODUCT_C100_1) }, | 452 | { USB_DEVICE(BANDRICH_VENDOR_ID, BANDRICH_PRODUCT_C100_1) }, |
418 | { USB_DEVICE(BANDRICH_VENDOR_ID, BANDRICH_PRODUCT_C100_2) }, | 453 | { USB_DEVICE(BANDRICH_VENDOR_ID, BANDRICH_PRODUCT_C100_2) }, |
diff --git a/drivers/usb/storage/unusual_devs.h b/drivers/usb/storage/unusual_devs.h index 6da9a7a962a8..e61f2bfc64ad 100644 --- a/drivers/usb/storage/unusual_devs.h +++ b/drivers/usb/storage/unusual_devs.h | |||
@@ -318,6 +318,18 @@ UNUSUAL_DEV( 0x045a, 0x5210, 0x0101, 0x0101, | |||
318 | US_SC_SCSI, US_PR_KARMA, rio_karma_init, 0), | 318 | US_SC_SCSI, US_PR_KARMA, rio_karma_init, 0), |
319 | #endif | 319 | #endif |
320 | 320 | ||
321 | /* Reported by Tamas Kerecsen <kerecsen@bigfoot.com> | ||
322 | * Obviously the PROM has not been customized by the VAR; | ||
323 | * the Vendor and Product string descriptors are: | ||
324 | * Generic Mass Storage (PROTOTYPE--Remember to change idVendor) | ||
325 | * Generic Manufacturer (PROTOTYPE--Remember to change idVendor) | ||
326 | */ | ||
327 | UNUSUAL_DEV( 0x045e, 0xffff, 0x0000, 0x0000, | ||
328 | "Mitac", | ||
329 | "GPS", | ||
330 | US_SC_DEVICE, US_PR_DEVICE, NULL, | ||
331 | US_FL_MAX_SECTORS_64 ), | ||
332 | |||
321 | /* | 333 | /* |
322 | * This virtual floppy is found in Sun equipment (x4600, x4200m2, etc.) | 334 | * This virtual floppy is found in Sun equipment (x4600, x4200m2, etc.) |
323 | * Reported by Pete Zaitcev <zaitcev@redhat.com> | 335 | * Reported by Pete Zaitcev <zaitcev@redhat.com> |
@@ -377,6 +389,13 @@ UNUSUAL_DEV( 0x04b0, 0x0401, 0x0200, 0x0200, | |||
377 | US_SC_DEVICE, US_PR_DEVICE, NULL, | 389 | US_SC_DEVICE, US_PR_DEVICE, NULL, |
378 | US_FL_FIX_CAPACITY), | 390 | US_FL_FIX_CAPACITY), |
379 | 391 | ||
392 | /* Reported by Tobias Kunze Briseno <t-linux@fictive.com> */ | ||
393 | UNUSUAL_DEV( 0x04b0, 0x0403, 0x0200, 0x0200, | ||
394 | "NIKON", | ||
395 | "NIKON DSC D2H", | ||
396 | US_SC_DEVICE, US_PR_DEVICE, NULL, | ||
397 | US_FL_FIX_CAPACITY), | ||
398 | |||
380 | /* Reported by Milinevsky Dmitry <niam.niam@gmail.com> */ | 399 | /* Reported by Milinevsky Dmitry <niam.niam@gmail.com> */ |
381 | UNUSUAL_DEV( 0x04b0, 0x0409, 0x0100, 0x0100, | 400 | UNUSUAL_DEV( 0x04b0, 0x0409, 0x0100, 0x0100, |
382 | "NIKON", | 401 | "NIKON", |