diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-11-28 19:03:09 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-11-28 19:03:09 -0500 |
commit | bb0851ff9dc65dd9c9365fdb87895d98235ac463 (patch) | |
tree | d19b7440bb5b0dec31cef2c384cccdd473f314e7 | |
parent | 34f2c1c35ff014a5d145971e41caa940cd62d563 (diff) | |
parent | 5f629ad7e5f9b99c6d025bf199d402734bd72d0f (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: (25 commits)
USB: s3c2410 gadget: ensure vbus pin in input mode during read
USB: s3c2410 gadget: allow sharing of vbus irq
USB: s3c2410 gadget: Header move fixups
USB: usb-storage: unusual_devs entry for JetFlash TS1GJF2A
USB: fix up EHCI startup synchronization
USB: make the microtek driver and HAL cooperate
USB: uevent environment key fix
USB: keep track of whether interface sysfs files exist
USB: sierra: new product id
USB HCD: avoid duplicate local_irq_disable()
USB: mailing lists have changed
USB: remove USB HUB entry from MAINTAINERS
USB: fix directory references in usb/README
USB: add support for an older firmware revision for the Nikon D200
USB: FIx locks and urb->status in adutux (updated)
USB: power-management documenation update
USB: Fix signr comment in usbdevice_fs.h
usbserial: fix inconsistent lock state
USB: fix usbled disconnect read race #2
USB: free memory when writing fails in usb/serial/mos7840.c
...
-rw-r--r-- | Documentation/usb/power-management.txt | 8 | ||||
-rw-r--r-- | MAINTAINERS | 101 | ||||
-rw-r--r-- | drivers/usb/README | 6 | ||||
-rw-r--r-- | drivers/usb/core/driver.c | 11 | ||||
-rw-r--r-- | drivers/usb/core/hcd.c | 3 | ||||
-rw-r--r-- | drivers/usb/core/hub.c | 2 | ||||
-rw-r--r-- | drivers/usb/core/message.c | 36 | ||||
-rw-r--r-- | drivers/usb/core/sysfs.c | 6 | ||||
-rw-r--r-- | drivers/usb/core/usb.c | 25 | ||||
-rw-r--r-- | drivers/usb/gadget/omap_udc.c | 6 | ||||
-rw-r--r-- | drivers/usb/gadget/s3c2410_udc.c | 16 | ||||
-rw-r--r-- | drivers/usb/host/Kconfig | 2 | ||||
-rw-r--r-- | drivers/usb/host/ehci-hcd.c | 5 | ||||
-rw-r--r-- | drivers/usb/image/microtek.c | 2 | ||||
-rw-r--r-- | drivers/usb/misc/adutux.c | 262 | ||||
-rw-r--r-- | drivers/usb/misc/usbled.c | 4 | ||||
-rw-r--r-- | drivers/usb/serial/generic.c | 5 | ||||
-rw-r--r-- | drivers/usb/serial/mos7840.c | 2 | ||||
-rw-r--r-- | drivers/usb/serial/pl2303.c | 1 | ||||
-rw-r--r-- | drivers/usb/serial/pl2303.h | 3 | ||||
-rw-r--r-- | drivers/usb/serial/sierra.c | 2 | ||||
-rw-r--r-- | drivers/usb/storage/scsiglue.c | 4 | ||||
-rw-r--r-- | drivers/usb/storage/unusual_devs.h | 17 | ||||
-rw-r--r-- | include/linux/usb.h | 1 | ||||
-rw-r--r-- | include/linux/usbdevice_fs.h | 3 |
25 files changed, 272 insertions, 261 deletions
diff --git a/Documentation/usb/power-management.txt b/Documentation/usb/power-management.txt index 97842deec471..b2fc4d4a9917 100644 --- a/Documentation/usb/power-management.txt +++ b/Documentation/usb/power-management.txt | |||
@@ -278,6 +278,14 @@ optional. The methods' jobs are quite simple: | |||
278 | (although the interfaces will be in the same altsettings as | 278 | (although the interfaces will be in the same altsettings as |
279 | before the suspend). | 279 | before the suspend). |
280 | 280 | ||
281 | If the device is disconnected or powered down while it is suspended, | ||
282 | the disconnect method will be called instead of the resume or | ||
283 | reset_resume method. This is also quite likely to happen when | ||
284 | waking up from hibernation, as many systems do not maintain suspend | ||
285 | current to the USB host controllers during hibernation. (It's | ||
286 | possible to work around the hibernation-forces-disconnect problem by | ||
287 | using the USB Persist facility.) | ||
288 | |||
281 | The reset_resume method is used by the USB Persist facility (see | 289 | The reset_resume method is used by the USB Persist facility (see |
282 | Documentation/usb/persist.txt) and it can also be used under certain | 290 | Documentation/usb/persist.txt) and it can also be used under certain |
283 | circumstances when CONFIG_USB_PERSIST is not enabled. Currently, if a | 291 | circumstances when CONFIG_USB_PERSIST is not enabled. Currently, if a |
diff --git a/MAINTAINERS b/MAINTAINERS index f5bd9bab7ed6..6b30cb3eac78 100644 --- a/MAINTAINERS +++ b/MAINTAINERS | |||
@@ -323,8 +323,7 @@ S: Maintained | |||
323 | ALCATEL SPEEDTOUCH USB DRIVER | 323 | ALCATEL SPEEDTOUCH USB DRIVER |
324 | P: Duncan Sands | 324 | P: Duncan Sands |
325 | M: duncan.sands@free.fr | 325 | M: duncan.sands@free.fr |
326 | L: linux-usb-users@lists.sourceforge.net | 326 | L: linux-usb@vger.kernel.org |
327 | L: linux-usb-devel@lists.sourceforge.net | ||
328 | W: http://www.linux-usb.org/SpeedTouch/ | 327 | W: http://www.linux-usb.org/SpeedTouch/ |
329 | S: Maintained | 328 | S: Maintained |
330 | 329 | ||
@@ -1043,7 +1042,7 @@ S: Maintained | |||
1043 | CIRRUS LOGIC EP93XX OHCI USB HOST DRIVER | 1042 | CIRRUS LOGIC EP93XX OHCI USB HOST DRIVER |
1044 | P: Lennert Buytenhek | 1043 | P: Lennert Buytenhek |
1045 | M: kernel@wantstofly.org | 1044 | M: kernel@wantstofly.org |
1046 | L: linux-usb-devel@lists.sourceforge.net | 1045 | L: linux-usb@vger.kernel.org |
1047 | S: Maintained | 1046 | S: Maintained |
1048 | 1047 | ||
1049 | CIRRUS LOGIC CS4280/CS461x SOUNDDRIVER | 1048 | CIRRUS LOGIC CS4280/CS461x SOUNDDRIVER |
@@ -1552,7 +1551,7 @@ S: Maintained | |||
1552 | FREESCALE HIGHSPEED USB DEVICE DRIVER | 1551 | FREESCALE HIGHSPEED USB DEVICE DRIVER |
1553 | P: Li Yang | 1552 | P: Li Yang |
1554 | M: leoli@freescale.com | 1553 | M: leoli@freescale.com |
1555 | L: linux-usb-devel@lists.sourceforge.net | 1554 | L: linux-usb@vger.kernel.org |
1556 | L: linuxppc-dev@ozlabs.org | 1555 | L: linuxppc-dev@ozlabs.org |
1557 | S: Maintained | 1556 | S: Maintained |
1558 | 1557 | ||
@@ -3810,22 +3809,20 @@ S: Maintained | |||
3810 | USB ACM DRIVER | 3809 | USB ACM DRIVER |
3811 | P: Oliver Neukum | 3810 | P: Oliver Neukum |
3812 | M: oliver@neukum.name | 3811 | M: oliver@neukum.name |
3813 | L: linux-usb-users@lists.sourceforge.net | 3812 | L: linux-usb@vger.kernel.org |
3814 | L: linux-usb-devel@lists.sourceforge.net | ||
3815 | S: Maintained | 3813 | S: Maintained |
3816 | 3814 | ||
3817 | USB BLOCK DRIVER (UB ub) | 3815 | USB BLOCK DRIVER (UB ub) |
3818 | P: Pete Zaitcev | 3816 | P: Pete Zaitcev |
3819 | M: zaitcev@redhat.com | 3817 | M: zaitcev@redhat.com |
3820 | L: linux-kernel@vger.kernel.org | 3818 | L: linux-kernel@vger.kernel.org |
3821 | L: linux-usb-devel@lists.sourceforge.net | 3819 | L: linux-usb@vger.kernel.org |
3822 | S: Supported | 3820 | S: Supported |
3823 | 3821 | ||
3824 | USB CDC ETHERNET DRIVER | 3822 | USB CDC ETHERNET DRIVER |
3825 | P: Greg Kroah-Hartman | 3823 | P: Greg Kroah-Hartman |
3826 | M: greg@kroah.com | 3824 | M: greg@kroah.com |
3827 | L: linux-usb-users@lists.sourceforge.net | 3825 | L: linux-usb@vger.kernel.org |
3828 | L: linux-usb-devel@lists.sourceforge.net | ||
3829 | S: Maintained | 3826 | S: Maintained |
3830 | W: http://www.kroah.com/linux-usb/ | 3827 | W: http://www.kroah.com/linux-usb/ |
3831 | 3828 | ||
@@ -3839,13 +3836,13 @@ S: Maintained | |||
3839 | USB EHCI DRIVER | 3836 | USB EHCI DRIVER |
3840 | P: David Brownell | 3837 | P: David Brownell |
3841 | M: dbrownell@users.sourceforge.net | 3838 | M: dbrownell@users.sourceforge.net |
3842 | L: linux-usb-devel@lists.sourceforge.net | 3839 | L: linux-usb@vger.kernel.org |
3843 | S: Odd Fixes | 3840 | S: Odd Fixes |
3844 | 3841 | ||
3845 | USB ET61X[12]51 DRIVER | 3842 | USB ET61X[12]51 DRIVER |
3846 | P: Luca Risolia | 3843 | P: Luca Risolia |
3847 | M: luca.risolia@studio.unibo.it | 3844 | M: luca.risolia@studio.unibo.it |
3848 | L: linux-usb-devel@lists.sourceforge.net | 3845 | L: linux-usb@vger.kernel.org |
3849 | L: video4linux-list@redhat.com | 3846 | L: video4linux-list@redhat.com |
3850 | W: http://www.linux-projects.org | 3847 | W: http://www.linux-projects.org |
3851 | S: Maintained | 3848 | S: Maintained |
@@ -3853,41 +3850,33 @@ S: Maintained | |||
3853 | USB GADGET/PERIPHERAL SUBSYSTEM | 3850 | USB GADGET/PERIPHERAL SUBSYSTEM |
3854 | P: David Brownell | 3851 | P: David Brownell |
3855 | M: dbrownell@users.sourceforge.net | 3852 | M: dbrownell@users.sourceforge.net |
3856 | L: linux-usb-devel@lists.sourceforge.net | 3853 | L: linux-usb@vger.kernel.org |
3857 | W: http://www.linux-usb.org/gadget | 3854 | W: http://www.linux-usb.org/gadget |
3858 | S: Maintained | 3855 | S: Maintained |
3859 | 3856 | ||
3860 | USB HID/HIDBP DRIVERS (USB KEYBOARDS, MICE, REMOTE CONTROLS, ...) | 3857 | USB HID/HIDBP DRIVERS (USB KEYBOARDS, MICE, REMOTE CONTROLS, ...) |
3861 | P: Jiri Kosina | 3858 | P: Jiri Kosina |
3862 | M: jkosina@suse.cz | 3859 | M: jkosina@suse.cz |
3863 | L: linux-usb-devel@lists.sourceforge.net | 3860 | L: linux-usb@vger.kernel.org |
3864 | T: git kernel.org:/pub/scm/linux/kernel/git/jikos/hid.git | 3861 | T: git kernel.org:/pub/scm/linux/kernel/git/jikos/hid.git |
3865 | S: Maintained | 3862 | S: Maintained |
3866 | 3863 | ||
3867 | USB HUB DRIVER | ||
3868 | P: Johannes Erdfelt | ||
3869 | M: johannes@erdfelt.com | ||
3870 | L: linux-usb-users@lists.sourceforge.net | ||
3871 | L: linux-usb-devel@lists.sourceforge.net | ||
3872 | S: Maintained | ||
3873 | |||
3874 | USB ISP116X DRIVER | 3864 | USB ISP116X DRIVER |
3875 | P: Olav Kongas | 3865 | P: Olav Kongas |
3876 | M: ok@artecdesign.ee | 3866 | M: ok@artecdesign.ee |
3877 | L: linux-usb-devel@lists.sourceforge.net | 3867 | L: linux-usb@vger.kernel.org |
3878 | S: Maintained | 3868 | S: Maintained |
3879 | 3869 | ||
3880 | USB KAWASAKI LSI DRIVER | 3870 | USB KAWASAKI LSI DRIVER |
3881 | P: Oliver Neukum | 3871 | P: Oliver Neukum |
3882 | M: oliver@neukum.name | 3872 | M: oliver@neukum.name |
3883 | L: linux-usb-users@lists.sourceforge.net | 3873 | L: linux-usb@vger.kernel.org |
3884 | L: linux-usb-devel@lists.sourceforge.net | ||
3885 | S: Maintained | 3874 | S: Maintained |
3886 | 3875 | ||
3887 | USB MASS STORAGE DRIVER | 3876 | USB MASS STORAGE DRIVER |
3888 | P: Matthew Dharm | 3877 | P: Matthew Dharm |
3889 | M: mdharm-usb@one-eyed-alien.net | 3878 | M: mdharm-usb@one-eyed-alien.net |
3890 | L: linux-usb-users@lists.sourceforge.net | 3879 | L: linux-usb@vger.kernel.org |
3891 | L: usb-storage@lists.one-eyed-alien.net | 3880 | L: usb-storage@lists.one-eyed-alien.net |
3892 | S: Maintained | 3881 | S: Maintained |
3893 | W: http://www.one-eyed-alien.net/~mdharm/linux-usb/ | 3882 | W: http://www.one-eyed-alien.net/~mdharm/linux-usb/ |
@@ -3895,28 +3884,26 @@ W: http://www.one-eyed-alien.net/~mdharm/linux-usb/ | |||
3895 | USB OHCI DRIVER | 3884 | USB OHCI DRIVER |
3896 | P: David Brownell | 3885 | P: David Brownell |
3897 | M: dbrownell@users.sourceforge.net | 3886 | M: dbrownell@users.sourceforge.net |
3898 | L: linux-usb-users@lists.sourceforge.net | 3887 | L: linux-usb@vger.kernel.org |
3899 | L: linux-usb-devel@lists.sourceforge.net | ||
3900 | S: Odd Fixes | 3888 | S: Odd Fixes |
3901 | 3889 | ||
3902 | USB OPTION-CARD DRIVER | 3890 | USB OPTION-CARD DRIVER |
3903 | P: Matthias Urlichs | 3891 | P: Matthias Urlichs |
3904 | M: smurf@smurf.noris.de | 3892 | M: smurf@smurf.noris.de |
3905 | L: linux-usb-devel@lists.sourceforge.net | 3893 | L: linux-usb@vger.kernel.org |
3906 | S: Maintained | 3894 | S: Maintained |
3907 | 3895 | ||
3908 | USB OV511 DRIVER | 3896 | USB OV511 DRIVER |
3909 | P: Mark McClelland | 3897 | P: Mark McClelland |
3910 | M: mmcclell@bigfoot.com | 3898 | M: mmcclell@bigfoot.com |
3911 | L: linux-usb-users@lists.sourceforge.net | 3899 | L: linux-usb@vger.kernel.org |
3912 | L: linux-usb-devel@lists.sourceforge.net | ||
3913 | W: http://alpha.dyndns.org/ov511/ | 3900 | W: http://alpha.dyndns.org/ov511/ |
3914 | S: Maintained | 3901 | S: Maintained |
3915 | 3902 | ||
3916 | USB PEGASUS DRIVER | 3903 | USB PEGASUS DRIVER |
3917 | P: Petko Manolov | 3904 | P: Petko Manolov |
3918 | M: petkan@users.sourceforge.net | 3905 | M: petkan@users.sourceforge.net |
3919 | L: linux-usb-devel@lists.sourceforge.net | 3906 | L: linux-usb@vger.kernel.org |
3920 | L: netdev@vger.kernel.org | 3907 | L: netdev@vger.kernel.org |
3921 | W: http://pegasus2.sourceforge.net/ | 3908 | W: http://pegasus2.sourceforge.net/ |
3922 | S: Maintained | 3909 | S: Maintained |
@@ -3924,14 +3911,13 @@ S: Maintained | |||
3924 | USB PRINTER DRIVER (usblp) | 3911 | USB PRINTER DRIVER (usblp) |
3925 | P: Pete Zaitcev | 3912 | P: Pete Zaitcev |
3926 | M: zaitcev@redhat.com | 3913 | M: zaitcev@redhat.com |
3927 | L: linux-usb-users@lists.sourceforge.net | 3914 | L: linux-usb@vger.kernel.org |
3928 | L: linux-usb-devel@lists.sourceforge.net | ||
3929 | S: Supported | 3915 | S: Supported |
3930 | 3916 | ||
3931 | USB RTL8150 DRIVER | 3917 | USB RTL8150 DRIVER |
3932 | P: Petko Manolov | 3918 | P: Petko Manolov |
3933 | M: petkan@users.sourceforge.net | 3919 | M: petkan@users.sourceforge.net |
3934 | L: linux-usb-devel@lists.sourceforge.net | 3920 | L: linux-usb@vger.kernel.org |
3935 | L: netdev@vger.kernel.org | 3921 | L: netdev@vger.kernel.org |
3936 | W: http://pegasus2.sourceforge.net/ | 3922 | W: http://pegasus2.sourceforge.net/ |
3937 | S: Maintained | 3923 | S: Maintained |
@@ -3939,8 +3925,7 @@ S: Maintained | |||
3939 | USB SE401 DRIVER | 3925 | USB SE401 DRIVER |
3940 | P: Jeroen Vreeken | 3926 | P: Jeroen Vreeken |
3941 | M: pe1rxq@amsat.org | 3927 | M: pe1rxq@amsat.org |
3942 | L: linux-usb-users@lists.sourceforge.net | 3928 | L: linux-usb@vger.kernel.org |
3943 | L: linux-usb-devel@lists.sourceforge.net | ||
3944 | W: http://www.chello.nl/~j.vreeken/se401/ | 3929 | W: http://www.chello.nl/~j.vreeken/se401/ |
3945 | S: Maintained | 3930 | S: Maintained |
3946 | 3931 | ||
@@ -3954,72 +3939,59 @@ USB SERIAL DIGI ACCELEPORT DRIVER | |||
3954 | P: Peter Berger and Al Borchers | 3939 | P: Peter Berger and Al Borchers |
3955 | M: pberger@brimson.com | 3940 | M: pberger@brimson.com |
3956 | M: alborchers@steinerpoint.com | 3941 | M: alborchers@steinerpoint.com |
3957 | L: linux-usb-users@lists.sourceforge.net | 3942 | L: linux-usb@vger.kernel.org |
3958 | L: linux-usb-devel@lists.sourceforge.net | ||
3959 | S: Maintained | 3943 | S: Maintained |
3960 | 3944 | ||
3961 | USB SERIAL DRIVER | 3945 | USB SERIAL DRIVER |
3962 | P: Greg Kroah-Hartman | 3946 | P: Greg Kroah-Hartman |
3963 | M: gregkh@suse.de | 3947 | M: gregkh@suse.de |
3964 | L: linux-usb-users@lists.sourceforge.net | 3948 | L: linux-usb@vger.kernel.org |
3965 | L: linux-usb-devel@lists.sourceforge.net | ||
3966 | S: Supported | 3949 | S: Supported |
3967 | 3950 | ||
3968 | USB SERIAL BELKIN F5U103 DRIVER | 3951 | USB SERIAL BELKIN F5U103 DRIVER |
3969 | P: William Greathouse | 3952 | P: William Greathouse |
3970 | M: wgreathouse@smva.com | 3953 | M: wgreathouse@smva.com |
3971 | L: linux-usb-users@lists.sourceforge.net | 3954 | L: linux-usb@vger.kernel.org |
3972 | L: linux-usb-devel@lists.sourceforge.net | ||
3973 | S: Maintained | 3955 | S: Maintained |
3974 | 3956 | ||
3975 | USB SERIAL CYPRESS M8 DRIVER | 3957 | USB SERIAL CYPRESS M8 DRIVER |
3976 | P: Lonnie Mendez | 3958 | P: Lonnie Mendez |
3977 | M: dignome@gmail.com | 3959 | M: dignome@gmail.com |
3978 | L: linux-usb-users@lists.sourceforge.net | 3960 | L: linux-usb@vger.kernel.org |
3979 | L: linux-usb-devel@lists.sourceforge.net | ||
3980 | S: Maintained | 3961 | S: Maintained |
3981 | W: http://geocities.com/i0xox0i | 3962 | W: http://geocities.com/i0xox0i |
3982 | W: http://firstlight.net/cvs | 3963 | W: http://firstlight.net/cvs |
3983 | 3964 | ||
3984 | USB SERIAL CYBERJACK PINPAD/E-COM DRIVER | ||
3985 | L: linux-usb-users@lists.sourceforge.net | ||
3986 | L: linux-usb-devel@lists.sourceforge.net | ||
3987 | S: Maintained | ||
3988 | |||
3989 | USB AUERSWALD DRIVER | 3965 | USB AUERSWALD DRIVER |
3990 | P: Wolfgang Muees | 3966 | P: Wolfgang Muees |
3991 | M: wolfgang@iksw-muees.de | 3967 | M: wolfgang@iksw-muees.de |
3992 | L: linux-usb-users@lists.sourceforge.net | 3968 | L: linux-usb@vger.kernel.org |
3993 | L: linux-usb-devel@lists.sourceforge.net | ||
3994 | S: Maintained | 3969 | S: Maintained |
3995 | 3970 | ||
3996 | USB SERIAL EMPEG EMPEG-CAR MARK I/II DRIVER | 3971 | USB SERIAL EMPEG EMPEG-CAR MARK I/II DRIVER |
3997 | P: Gary Brubaker | 3972 | P: Gary Brubaker |
3998 | M: xavyer@ix.netcom.com | 3973 | M: xavyer@ix.netcom.com |
3999 | L: linux-usb-users@lists.sourceforge.net | 3974 | L: linux-usb@vger.kernel.org |
4000 | L: linux-usb-devel@lists.sourceforge.net | ||
4001 | S: Maintained | 3975 | S: Maintained |
4002 | 3976 | ||
4003 | USB SERIAL KEYSPAN DRIVER | 3977 | USB SERIAL KEYSPAN DRIVER |
4004 | P: Greg Kroah-Hartman | 3978 | P: Greg Kroah-Hartman |
4005 | M: greg@kroah.com | 3979 | M: greg@kroah.com |
4006 | L: linux-usb-users@lists.sourceforge.net | 3980 | L: linux-usb@vger.kernel.org |
4007 | L: linux-usb-devel@lists.sourceforge.net | ||
4008 | W: http://www.kroah.com/linux/ | 3981 | W: http://www.kroah.com/linux/ |
4009 | S: Maintained | 3982 | S: Maintained |
4010 | 3983 | ||
4011 | USB SERIAL WHITEHEAT DRIVER | 3984 | USB SERIAL WHITEHEAT DRIVER |
4012 | P: Support Department | 3985 | P: Support Department |
4013 | M: support@connecttech.com | 3986 | M: support@connecttech.com |
4014 | L: linux-usb-users@lists.sourceforge.net | 3987 | L: linux-usb@vger.kernel.org |
4015 | L: linux-usb-devel@lists.sourceforge.net | ||
4016 | W: http://www.connecttech.com | 3988 | W: http://www.connecttech.com |
4017 | S: Supported | 3989 | S: Supported |
4018 | 3990 | ||
4019 | USB SN9C1xx DRIVER | 3991 | USB SN9C1xx DRIVER |
4020 | P: Luca Risolia | 3992 | P: Luca Risolia |
4021 | M: luca.risolia@studio.unibo.it | 3993 | M: luca.risolia@studio.unibo.it |
4022 | L: linux-usb-devel@lists.sourceforge.net | 3994 | L: linux-usb@vger.kernel.org |
4023 | L: video4linux-list@redhat.com | 3995 | L: video4linux-list@redhat.com |
4024 | W: http://www.linux-projects.org | 3996 | W: http://www.linux-projects.org |
4025 | S: Maintained | 3997 | S: Maintained |
@@ -4027,8 +3999,7 @@ S: Maintained | |||
4027 | USB SUBSYSTEM | 3999 | USB SUBSYSTEM |
4028 | P: Greg Kroah-Hartman | 4000 | P: Greg Kroah-Hartman |
4029 | M: gregkh@suse.de | 4001 | M: gregkh@suse.de |
4030 | L: linux-usb-users@lists.sourceforge.net | 4002 | L: linux-usb@vger.kernel.org |
4031 | L: linux-usb-devel@lists.sourceforge.net | ||
4032 | W: http://www.linux-usb.org | 4003 | W: http://www.linux-usb.org |
4033 | T: quilt kernel.org/pub/linux/kernel/people/gregkh/gregkh-2.6/ | 4004 | T: quilt kernel.org/pub/linux/kernel/people/gregkh/gregkh-2.6/ |
4034 | S: Supported | 4005 | S: Supported |
@@ -4036,8 +4007,7 @@ S: Supported | |||
4036 | USB UHCI DRIVER | 4007 | USB UHCI DRIVER |
4037 | P: Alan Stern | 4008 | P: Alan Stern |
4038 | M: stern@rowland.harvard.edu | 4009 | M: stern@rowland.harvard.edu |
4039 | L: linux-usb-users@lists.sourceforge.net | 4010 | L: linux-usb@vger.kernel.org |
4040 | L: linux-usb-devel@lists.sourceforge.net | ||
4041 | S: Maintained | 4011 | S: Maintained |
4042 | 4012 | ||
4043 | USB "USBNET" DRIVER FRAMEWORK | 4013 | USB "USBNET" DRIVER FRAMEWORK |
@@ -4050,7 +4020,7 @@ S: Maintained | |||
4050 | USB W996[87]CF DRIVER | 4020 | USB W996[87]CF DRIVER |
4051 | P: Luca Risolia | 4021 | P: Luca Risolia |
4052 | M: luca.risolia@studio.unibo.it | 4022 | M: luca.risolia@studio.unibo.it |
4053 | L: linux-usb-devel@lists.sourceforge.net | 4023 | L: linux-usb@vger.kernel.org |
4054 | L: video4linux-list@redhat.com | 4024 | L: video4linux-list@redhat.com |
4055 | W: http://www.linux-projects.org | 4025 | W: http://www.linux-projects.org |
4056 | S: Maintained | 4026 | S: Maintained |
@@ -4058,7 +4028,7 @@ S: Maintained | |||
4058 | USB ZC0301 DRIVER | 4028 | USB ZC0301 DRIVER |
4059 | P: Luca Risolia | 4029 | P: Luca Risolia |
4060 | M: luca.risolia@studio.unibo.it | 4030 | M: luca.risolia@studio.unibo.it |
4061 | L: linux-usb-devel@lists.sourceforge.net | 4031 | L: linux-usb@vger.kernel.org |
4062 | L: video4linux-list@redhat.com | 4032 | L: video4linux-list@redhat.com |
4063 | W: http://www.linux-projects.org | 4033 | W: http://www.linux-projects.org |
4064 | S: Maintained | 4034 | S: Maintained |
@@ -4066,15 +4036,14 @@ S: Maintained | |||
4066 | USB ZD1201 DRIVER | 4036 | USB ZD1201 DRIVER |
4067 | P: Jeroen Vreeken | 4037 | P: Jeroen Vreeken |
4068 | M: pe1rxq@amsat.org | 4038 | M: pe1rxq@amsat.org |
4069 | L: linux-usb-users@lists.sourceforge.net | 4039 | L: linux-usb@vger.kernel.org |
4070 | L: linux-usb-devel@lists.sourceforge.net | ||
4071 | W: http://linux-lc100020.sourceforge.net | 4040 | W: http://linux-lc100020.sourceforge.net |
4072 | S: Maintained | 4041 | S: Maintained |
4073 | 4042 | ||
4074 | USB ZR364XX DRIVER | 4043 | USB ZR364XX DRIVER |
4075 | P: Antoine Jacquet | 4044 | P: Antoine Jacquet |
4076 | M: royale@zerezo.com | 4045 | M: royale@zerezo.com |
4077 | L: linux-usb-devel@lists.sourceforge.net | 4046 | L: linux-usb@vger.kernel.org |
4078 | L: video4linux-list@redhat.com | 4047 | L: video4linux-list@redhat.com |
4079 | W: http://royale.zerezo.com/zr364xx/ | 4048 | W: http://royale.zerezo.com/zr364xx/ |
4080 | S: Maintained | 4049 | S: Maintained |
diff --git a/drivers/usb/README b/drivers/usb/README index 3c8434128554..284f46b3e1cc 100644 --- a/drivers/usb/README +++ b/drivers/usb/README | |||
@@ -39,12 +39,12 @@ first subdirectory in the list below that it fits into. | |||
39 | 39 | ||
40 | image/ - This is for still image drivers, like scanners or | 40 | image/ - This is for still image drivers, like scanners or |
41 | digital cameras. | 41 | digital cameras. |
42 | input/ - This is for any driver that uses the input subsystem, | 42 | ../input/ - This is for any driver that uses the input subsystem, |
43 | like keyboard, mice, touchscreens, tablets, etc. | 43 | like keyboard, mice, touchscreens, tablets, etc. |
44 | media/ - This is for multimedia drivers, like video cameras, | 44 | ../media/ - This is for multimedia drivers, like video cameras, |
45 | radios, and any other drivers that talk to the v4l | 45 | radios, and any other drivers that talk to the v4l |
46 | subsystem. | 46 | subsystem. |
47 | net/ - This is for network drivers. | 47 | ../net/ - This is for network drivers. |
48 | serial/ - This is for USB to serial drivers. | 48 | serial/ - This is for USB to serial drivers. |
49 | storage/ - This is for USB mass-storage drivers. | 49 | storage/ - This is for USB mass-storage drivers. |
50 | class/ - This is for all USB device drivers that do not fit | 50 | class/ - This is for all USB device drivers that do not fit |
diff --git a/drivers/usb/core/driver.c b/drivers/usb/core/driver.c index 8586817698ad..c51f8e9312e0 100644 --- a/drivers/usb/core/driver.c +++ b/drivers/usb/core/driver.c | |||
@@ -585,9 +585,6 @@ static int usb_uevent(struct device *dev, struct kobj_uevent_env *env) | |||
585 | { | 585 | { |
586 | struct usb_device *usb_dev; | 586 | struct usb_device *usb_dev; |
587 | 587 | ||
588 | if (!dev) | ||
589 | return -ENODEV; | ||
590 | |||
591 | /* driver is often null here; dev_dbg() would oops */ | 588 | /* driver is often null here; dev_dbg() would oops */ |
592 | pr_debug ("usb %s: uevent\n", dev->bus_id); | 589 | pr_debug ("usb %s: uevent\n", dev->bus_id); |
593 | 590 | ||
@@ -631,14 +628,6 @@ static int usb_uevent(struct device *dev, struct kobj_uevent_env *env) | |||
631 | usb_dev->descriptor.bDeviceProtocol)) | 628 | usb_dev->descriptor.bDeviceProtocol)) |
632 | return -ENOMEM; | 629 | return -ENOMEM; |
633 | 630 | ||
634 | if (add_uevent_var(env, "BUSNUM=%03d", | ||
635 | usb_dev->bus->busnum)) | ||
636 | return -ENOMEM; | ||
637 | |||
638 | if (add_uevent_var(env, "DEVNUM=%03d", | ||
639 | usb_dev->devnum)) | ||
640 | return -ENOMEM; | ||
641 | |||
642 | return 0; | 631 | return 0; |
643 | } | 632 | } |
644 | 633 | ||
diff --git a/drivers/usb/core/hcd.c b/drivers/usb/core/hcd.c index fea8256a18d6..d5ed3fa9e304 100644 --- a/drivers/usb/core/hcd.c +++ b/drivers/usb/core/hcd.c | |||
@@ -1311,8 +1311,8 @@ void usb_hcd_flush_endpoint(struct usb_device *udev, | |||
1311 | hcd = bus_to_hcd(udev->bus); | 1311 | hcd = bus_to_hcd(udev->bus); |
1312 | 1312 | ||
1313 | /* No more submits can occur */ | 1313 | /* No more submits can occur */ |
1314 | rescan: | ||
1315 | spin_lock_irq(&hcd_urb_list_lock); | 1314 | spin_lock_irq(&hcd_urb_list_lock); |
1315 | rescan: | ||
1316 | list_for_each_entry (urb, &ep->urb_list, urb_list) { | 1316 | list_for_each_entry (urb, &ep->urb_list, urb_list) { |
1317 | int is_in; | 1317 | int is_in; |
1318 | 1318 | ||
@@ -1345,6 +1345,7 @@ rescan: | |||
1345 | usb_put_urb (urb); | 1345 | usb_put_urb (urb); |
1346 | 1346 | ||
1347 | /* list contents may have changed */ | 1347 | /* list contents may have changed */ |
1348 | spin_lock(&hcd_urb_list_lock); | ||
1348 | goto rescan; | 1349 | goto rescan; |
1349 | } | 1350 | } |
1350 | spin_unlock_irq(&hcd_urb_list_lock); | 1351 | spin_unlock_irq(&hcd_urb_list_lock); |
diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c index 036c3dea855e..13b326a13377 100644 --- a/drivers/usb/core/hub.c +++ b/drivers/usb/core/hub.c | |||
@@ -335,7 +335,7 @@ static void kick_khubd(struct usb_hub *hub) | |||
335 | to_usb_interface(hub->intfdev)->pm_usage_cnt = 1; | 335 | to_usb_interface(hub->intfdev)->pm_usage_cnt = 1; |
336 | 336 | ||
337 | spin_lock_irqsave(&hub_event_lock, flags); | 337 | spin_lock_irqsave(&hub_event_lock, flags); |
338 | if (!hub->disconnected & list_empty(&hub->event_list)) { | 338 | if (!hub->disconnected && list_empty(&hub->event_list)) { |
339 | list_add_tail(&hub->event_list, &hub_event_list); | 339 | list_add_tail(&hub->event_list, &hub_event_list); |
340 | wake_up(&khubd_wait); | 340 | wake_up(&khubd_wait); |
341 | } | 341 | } |
diff --git a/drivers/usb/core/message.c b/drivers/usb/core/message.c index 316a746e0080..fcd40ecbeecc 100644 --- a/drivers/usb/core/message.c +++ b/drivers/usb/core/message.c | |||
@@ -1172,7 +1172,6 @@ int usb_set_interface(struct usb_device *dev, int interface, int alternate) | |||
1172 | struct usb_host_interface *alt; | 1172 | struct usb_host_interface *alt; |
1173 | int ret; | 1173 | int ret; |
1174 | int manual = 0; | 1174 | int manual = 0; |
1175 | int changed; | ||
1176 | 1175 | ||
1177 | if (dev->state == USB_STATE_SUSPENDED) | 1176 | if (dev->state == USB_STATE_SUSPENDED) |
1178 | return -EHOSTUNREACH; | 1177 | return -EHOSTUNREACH; |
@@ -1212,8 +1211,7 @@ int usb_set_interface(struct usb_device *dev, int interface, int alternate) | |||
1212 | */ | 1211 | */ |
1213 | 1212 | ||
1214 | /* prevent submissions using previous endpoint settings */ | 1213 | /* prevent submissions using previous endpoint settings */ |
1215 | changed = (iface->cur_altsetting != alt); | 1214 | if (iface->cur_altsetting != alt && device_is_registered(&iface->dev)) |
1216 | if (changed && device_is_registered(&iface->dev)) | ||
1217 | usb_remove_sysfs_intf_files(iface); | 1215 | usb_remove_sysfs_intf_files(iface); |
1218 | usb_disable_interface(dev, iface); | 1216 | usb_disable_interface(dev, iface); |
1219 | 1217 | ||
@@ -1250,7 +1248,7 @@ int usb_set_interface(struct usb_device *dev, int interface, int alternate) | |||
1250 | * (Likewise, EP0 never "halts" on well designed devices.) | 1248 | * (Likewise, EP0 never "halts" on well designed devices.) |
1251 | */ | 1249 | */ |
1252 | usb_enable_interface(dev, iface); | 1250 | usb_enable_interface(dev, iface); |
1253 | if (changed && device_is_registered(&iface->dev)) | 1251 | if (device_is_registered(&iface->dev)) |
1254 | usb_create_sysfs_intf_files(iface); | 1252 | usb_create_sysfs_intf_files(iface); |
1255 | 1253 | ||
1256 | return 0; | 1254 | return 0; |
@@ -1348,34 +1346,10 @@ static int usb_if_uevent(struct device *dev, struct kobj_uevent_env *env) | |||
1348 | struct usb_interface *intf; | 1346 | struct usb_interface *intf; |
1349 | struct usb_host_interface *alt; | 1347 | struct usb_host_interface *alt; |
1350 | 1348 | ||
1351 | if (!dev) | ||
1352 | return -ENODEV; | ||
1353 | |||
1354 | /* driver is often null here; dev_dbg() would oops */ | ||
1355 | pr_debug ("usb %s: uevent\n", dev->bus_id); | ||
1356 | |||
1357 | intf = to_usb_interface(dev); | 1349 | intf = to_usb_interface(dev); |
1358 | usb_dev = interface_to_usbdev(intf); | 1350 | usb_dev = interface_to_usbdev(intf); |
1359 | alt = intf->cur_altsetting; | 1351 | alt = intf->cur_altsetting; |
1360 | 1352 | ||
1361 | #ifdef CONFIG_USB_DEVICEFS | ||
1362 | if (add_uevent_var(env, "DEVICE=/proc/bus/usb/%03d/%03d", | ||
1363 | usb_dev->bus->busnum, usb_dev->devnum)) | ||
1364 | return -ENOMEM; | ||
1365 | #endif | ||
1366 | |||
1367 | if (add_uevent_var(env, "PRODUCT=%x/%x/%x", | ||
1368 | le16_to_cpu(usb_dev->descriptor.idVendor), | ||
1369 | le16_to_cpu(usb_dev->descriptor.idProduct), | ||
1370 | le16_to_cpu(usb_dev->descriptor.bcdDevice))) | ||
1371 | return -ENOMEM; | ||
1372 | |||
1373 | if (add_uevent_var(env, "TYPE=%d/%d/%d", | ||
1374 | usb_dev->descriptor.bDeviceClass, | ||
1375 | usb_dev->descriptor.bDeviceSubClass, | ||
1376 | usb_dev->descriptor.bDeviceProtocol)) | ||
1377 | return -ENOMEM; | ||
1378 | |||
1379 | if (add_uevent_var(env, "INTERFACE=%d/%d/%d", | 1353 | if (add_uevent_var(env, "INTERFACE=%d/%d/%d", |
1380 | alt->desc.bInterfaceClass, | 1354 | alt->desc.bInterfaceClass, |
1381 | alt->desc.bInterfaceSubClass, | 1355 | alt->desc.bInterfaceSubClass, |
@@ -1641,12 +1615,6 @@ free_interfaces: | |||
1641 | intf->dev.bus_id, ret); | 1615 | intf->dev.bus_id, ret); |
1642 | continue; | 1616 | continue; |
1643 | } | 1617 | } |
1644 | |||
1645 | /* The driver's probe method can call usb_set_interface(), | ||
1646 | * which would mean the interface's sysfs files are already | ||
1647 | * created. Just in case, we'll remove them first. | ||
1648 | */ | ||
1649 | usb_remove_sysfs_intf_files(intf); | ||
1650 | usb_create_sysfs_intf_files(intf); | 1618 | usb_create_sysfs_intf_files(intf); |
1651 | } | 1619 | } |
1652 | 1620 | ||
diff --git a/drivers/usb/core/sysfs.c b/drivers/usb/core/sysfs.c index b04afd06e502..32bd130b1eed 100644 --- a/drivers/usb/core/sysfs.c +++ b/drivers/usb/core/sysfs.c | |||
@@ -735,6 +735,8 @@ int usb_create_sysfs_intf_files(struct usb_interface *intf) | |||
735 | struct usb_host_interface *alt = intf->cur_altsetting; | 735 | struct usb_host_interface *alt = intf->cur_altsetting; |
736 | int retval; | 736 | int retval; |
737 | 737 | ||
738 | if (intf->sysfs_files_created) | ||
739 | return 0; | ||
738 | retval = sysfs_create_group(&dev->kobj, &intf_attr_grp); | 740 | retval = sysfs_create_group(&dev->kobj, &intf_attr_grp); |
739 | if (retval) | 741 | if (retval) |
740 | return retval; | 742 | return retval; |
@@ -746,6 +748,7 @@ int usb_create_sysfs_intf_files(struct usb_interface *intf) | |||
746 | if (intf->intf_assoc) | 748 | if (intf->intf_assoc) |
747 | retval = sysfs_create_group(&dev->kobj, &intf_assoc_attr_grp); | 749 | retval = sysfs_create_group(&dev->kobj, &intf_assoc_attr_grp); |
748 | usb_create_intf_ep_files(intf, udev); | 750 | usb_create_intf_ep_files(intf, udev); |
751 | intf->sysfs_files_created = 1; | ||
749 | return 0; | 752 | return 0; |
750 | } | 753 | } |
751 | 754 | ||
@@ -753,8 +756,11 @@ void usb_remove_sysfs_intf_files(struct usb_interface *intf) | |||
753 | { | 756 | { |
754 | struct device *dev = &intf->dev; | 757 | struct device *dev = &intf->dev; |
755 | 758 | ||
759 | if (!intf->sysfs_files_created) | ||
760 | return; | ||
756 | usb_remove_intf_ep_files(intf); | 761 | usb_remove_intf_ep_files(intf); |
757 | device_remove_file(dev, &dev_attr_interface); | 762 | device_remove_file(dev, &dev_attr_interface); |
758 | sysfs_remove_group(&dev->kobj, &intf_attr_grp); | 763 | sysfs_remove_group(&dev->kobj, &intf_attr_grp); |
759 | sysfs_remove_group(&intf->dev.kobj, &intf_assoc_attr_grp); | 764 | sysfs_remove_group(&intf->dev.kobj, &intf_assoc_attr_grp); |
765 | intf->sysfs_files_created = 0; | ||
760 | } | 766 | } |
diff --git a/drivers/usb/core/usb.c b/drivers/usb/core/usb.c index c4a6f1095b8b..8f142370103d 100644 --- a/drivers/usb/core/usb.c +++ b/drivers/usb/core/usb.c | |||
@@ -192,9 +192,34 @@ static void usb_release_dev(struct device *dev) | |||
192 | kfree(udev); | 192 | kfree(udev); |
193 | } | 193 | } |
194 | 194 | ||
195 | #ifdef CONFIG_HOTPLUG | ||
196 | static int usb_dev_uevent(struct device *dev, struct kobj_uevent_env *env) | ||
197 | { | ||
198 | struct usb_device *usb_dev; | ||
199 | |||
200 | usb_dev = to_usb_device(dev); | ||
201 | |||
202 | if (add_uevent_var(env, "BUSNUM=%03d", usb_dev->bus->busnum)) | ||
203 | return -ENOMEM; | ||
204 | |||
205 | if (add_uevent_var(env, "DEVNUM=%03d", usb_dev->devnum)) | ||
206 | return -ENOMEM; | ||
207 | |||
208 | return 0; | ||
209 | } | ||
210 | |||
211 | #else | ||
212 | |||
213 | static int usb_dev_uevent(struct device *dev, struct kobj_uevent_env *env) | ||
214 | { | ||
215 | return -ENODEV; | ||
216 | } | ||
217 | #endif /* CONFIG_HOTPLUG */ | ||
218 | |||
195 | struct device_type usb_device_type = { | 219 | struct device_type usb_device_type = { |
196 | .name = "usb_device", | 220 | .name = "usb_device", |
197 | .release = usb_release_dev, | 221 | .release = usb_release_dev, |
222 | .uevent = usb_dev_uevent, | ||
198 | }; | 223 | }; |
199 | 224 | ||
200 | #ifdef CONFIG_PM | 225 | #ifdef CONFIG_PM |
diff --git a/drivers/usb/gadget/omap_udc.c b/drivers/usb/gadget/omap_udc.c index 87c4f50dfb61..d377154658b5 100644 --- a/drivers/usb/gadget/omap_udc.c +++ b/drivers/usb/gadget/omap_udc.c | |||
@@ -1241,14 +1241,14 @@ static void pullup_enable(struct omap_udc *udc) | |||
1241 | udc->gadget.dev.parent->power.power_state = PMSG_ON; | 1241 | udc->gadget.dev.parent->power.power_state = PMSG_ON; |
1242 | udc->gadget.dev.power.power_state = PMSG_ON; | 1242 | udc->gadget.dev.power.power_state = PMSG_ON; |
1243 | UDC_SYSCON1_REG |= UDC_PULLUP_EN; | 1243 | UDC_SYSCON1_REG |= UDC_PULLUP_EN; |
1244 | if (!gadget_is_otg(udc->gadget) && !cpu_is_omap15xx()) | 1244 | if (!gadget_is_otg(&udc->gadget) && !cpu_is_omap15xx()) |
1245 | OTG_CTRL_REG |= OTG_BSESSVLD; | 1245 | OTG_CTRL_REG |= OTG_BSESSVLD; |
1246 | UDC_IRQ_EN_REG = UDC_DS_CHG_IE; | 1246 | UDC_IRQ_EN_REG = UDC_DS_CHG_IE; |
1247 | } | 1247 | } |
1248 | 1248 | ||
1249 | static void pullup_disable(struct omap_udc *udc) | 1249 | static void pullup_disable(struct omap_udc *udc) |
1250 | { | 1250 | { |
1251 | if (!gadget_is_otg(udc->gadget) && !cpu_is_omap15xx()) | 1251 | if (!gadget_is_otg(&udc->gadget) && !cpu_is_omap15xx()) |
1252 | OTG_CTRL_REG &= ~OTG_BSESSVLD; | 1252 | OTG_CTRL_REG &= ~OTG_BSESSVLD; |
1253 | UDC_IRQ_EN_REG = UDC_DS_CHG_IE; | 1253 | UDC_IRQ_EN_REG = UDC_DS_CHG_IE; |
1254 | UDC_SYSCON1_REG &= ~UDC_PULLUP_EN; | 1254 | UDC_SYSCON1_REG &= ~UDC_PULLUP_EN; |
@@ -1386,7 +1386,7 @@ static void update_otg(struct omap_udc *udc) | |||
1386 | { | 1386 | { |
1387 | u16 devstat; | 1387 | u16 devstat; |
1388 | 1388 | ||
1389 | if (!gadget_is_otg(udc->gadget)) | 1389 | if (!gadget_is_otg(&udc->gadget)) |
1390 | return; | 1390 | return; |
1391 | 1391 | ||
1392 | if (OTG_CTRL_REG & OTG_ID) | 1392 | if (OTG_CTRL_REG & OTG_ID) |
diff --git a/drivers/usb/gadget/s3c2410_udc.c b/drivers/usb/gadget/s3c2410_udc.c index e3e90f8a75e7..4ce050c3d13f 100644 --- a/drivers/usb/gadget/s3c2410_udc.c +++ b/drivers/usb/gadget/s3c2410_udc.c | |||
@@ -52,10 +52,10 @@ | |||
52 | #include <asm/arch/irqs.h> | 52 | #include <asm/arch/irqs.h> |
53 | 53 | ||
54 | #include <asm/arch/hardware.h> | 54 | #include <asm/arch/hardware.h> |
55 | #include <asm/arch/regs-clock.h> | ||
56 | #include <asm/arch/regs-gpio.h> | 55 | #include <asm/arch/regs-gpio.h> |
57 | #include <asm/arch/regs-udc.h> | 56 | |
58 | #include <asm/arch/udc.h> | 57 | #include <asm/plat-s3c24xx/regs-udc.h> |
58 | #include <asm/plat-s3c24xx/udc.h> | ||
59 | 59 | ||
60 | #include <asm/mach-types.h> | 60 | #include <asm/mach-types.h> |
61 | 61 | ||
@@ -1511,7 +1511,11 @@ static irqreturn_t s3c2410_udc_vbus_irq(int irq, void *_dev) | |||
1511 | unsigned int value; | 1511 | unsigned int value; |
1512 | 1512 | ||
1513 | dprintk(DEBUG_NORMAL, "%s()\n", __func__); | 1513 | dprintk(DEBUG_NORMAL, "%s()\n", __func__); |
1514 | |||
1515 | /* some cpus cannot read from an line configured to IRQ! */ | ||
1516 | s3c2410_gpio_cfgpin(udc_info->vbus_pin, S3C2410_GPIO_INPUT); | ||
1514 | value = s3c2410_gpio_getpin(udc_info->vbus_pin); | 1517 | value = s3c2410_gpio_getpin(udc_info->vbus_pin); |
1518 | s3c2410_gpio_cfgpin(udc_info->vbus_pin, S3C2410_GPIO_SFN2); | ||
1515 | 1519 | ||
1516 | if (udc_info->vbus_pin_inverted) | 1520 | if (udc_info->vbus_pin_inverted) |
1517 | value = !value; | 1521 | value = !value; |
@@ -1872,9 +1876,9 @@ static int s3c2410_udc_probe(struct platform_device *pdev) | |||
1872 | if (udc_info && udc_info->vbus_pin > 0) { | 1876 | if (udc_info && udc_info->vbus_pin > 0) { |
1873 | irq = s3c2410_gpio_getirq(udc_info->vbus_pin); | 1877 | irq = s3c2410_gpio_getirq(udc_info->vbus_pin); |
1874 | retval = request_irq(irq, s3c2410_udc_vbus_irq, | 1878 | retval = request_irq(irq, s3c2410_udc_vbus_irq, |
1875 | IRQF_DISABLED | IRQF_TRIGGER_RISING | 1879 | IRQF_DISABLED | IRQF_TRIGGER_RISING |
1876 | | IRQF_TRIGGER_FALLING, | 1880 | | IRQF_TRIGGER_FALLING | IRQF_SHARED, |
1877 | gadget_name, udc); | 1881 | gadget_name, udc); |
1878 | 1882 | ||
1879 | if (retval != 0) { | 1883 | if (retval != 0) { |
1880 | dev_err(dev, "can't get vbus irq %i, err %d\n", | 1884 | dev_err(dev, "can't get vbus irq %i, err %d\n", |
diff --git a/drivers/usb/host/Kconfig b/drivers/usb/host/Kconfig index 177e78ed241b..49a91c5ee51b 100644 --- a/drivers/usb/host/Kconfig +++ b/drivers/usb/host/Kconfig | |||
@@ -156,7 +156,7 @@ config USB_OHCI_HCD_PCI | |||
156 | 156 | ||
157 | config USB_OHCI_HCD_SSB | 157 | config USB_OHCI_HCD_SSB |
158 | bool "OHCI support for Broadcom SSB OHCI core" | 158 | bool "OHCI support for Broadcom SSB OHCI core" |
159 | depends on USB_OHCI_HCD && (SSB = y || SSB = CONFIG_USB_OHCI_HCD) && EXPERIMENTAL | 159 | depends on USB_OHCI_HCD && (SSB = y || SSB = USB_OHCI_HCD) && EXPERIMENTAL |
160 | default n | 160 | default n |
161 | ---help--- | 161 | ---help--- |
162 | Support for the Sonics Silicon Backplane (SSB) attached | 162 | Support for the Sonics Silicon Backplane (SSB) attached |
diff --git a/drivers/usb/host/ehci-hcd.c b/drivers/usb/host/ehci-hcd.c index c1514442883e..5f2d74ed5ad7 100644 --- a/drivers/usb/host/ehci-hcd.c +++ b/drivers/usb/host/ehci-hcd.c | |||
@@ -575,12 +575,15 @@ static int ehci_run (struct usb_hcd *hcd) | |||
575 | * from the companions to the EHCI controller. If any of the | 575 | * from the companions to the EHCI controller. If any of the |
576 | * companions are in the middle of a port reset at the time, it | 576 | * companions are in the middle of a port reset at the time, it |
577 | * could cause trouble. Write-locking ehci_cf_port_reset_rwsem | 577 | * could cause trouble. Write-locking ehci_cf_port_reset_rwsem |
578 | * guarantees that no resets are in progress. | 578 | * guarantees that no resets are in progress. After we set CF, |
579 | * a short delay lets the hardware catch up; new resets shouldn't | ||
580 | * be started before the port switching actions could complete. | ||
579 | */ | 581 | */ |
580 | down_write(&ehci_cf_port_reset_rwsem); | 582 | down_write(&ehci_cf_port_reset_rwsem); |
581 | hcd->state = HC_STATE_RUNNING; | 583 | hcd->state = HC_STATE_RUNNING; |
582 | ehci_writel(ehci, FLAG_CF, &ehci->regs->configured_flag); | 584 | ehci_writel(ehci, FLAG_CF, &ehci->regs->configured_flag); |
583 | ehci_readl(ehci, &ehci->regs->command); /* unblock posted writes */ | 585 | ehci_readl(ehci, &ehci->regs->command); /* unblock posted writes */ |
586 | msleep(5); | ||
584 | up_write(&ehci_cf_port_reset_rwsem); | 587 | up_write(&ehci_cf_port_reset_rwsem); |
585 | 588 | ||
586 | temp = HC_VERSION(ehci_readl(ehci, &ehci->caps->hc_capbase)); | 589 | temp = HC_VERSION(ehci_readl(ehci, &ehci->caps->hc_capbase)); |
diff --git a/drivers/usb/image/microtek.c b/drivers/usb/image/microtek.c index 91e999c9f680..bc207e3c21f5 100644 --- a/drivers/usb/image/microtek.c +++ b/drivers/usb/image/microtek.c | |||
@@ -819,7 +819,7 @@ static int mts_usb_probe(struct usb_interface *intf, | |||
819 | goto out_kfree2; | 819 | goto out_kfree2; |
820 | 820 | ||
821 | new_desc->host->hostdata[0] = (unsigned long)new_desc; | 821 | new_desc->host->hostdata[0] = (unsigned long)new_desc; |
822 | if (scsi_add_host(new_desc->host, NULL)) { | 822 | if (scsi_add_host(new_desc->host, &dev->dev)) { |
823 | err_retval = -EIO; | 823 | err_retval = -EIO; |
824 | goto out_host_put; | 824 | goto out_host_put; |
825 | } | 825 | } |
diff --git a/drivers/usb/misc/adutux.c b/drivers/usb/misc/adutux.c index c567aa7a41ea..5a2c44e4c1f7 100644 --- a/drivers/usb/misc/adutux.c +++ b/drivers/usb/misc/adutux.c | |||
@@ -79,12 +79,22 @@ MODULE_DEVICE_TABLE(usb, device_table); | |||
79 | 79 | ||
80 | #define COMMAND_TIMEOUT (2*HZ) /* 60 second timeout for a command */ | 80 | #define COMMAND_TIMEOUT (2*HZ) /* 60 second timeout for a command */ |
81 | 81 | ||
82 | /* | ||
83 | * The locking scheme is a vanilla 3-lock: | ||
84 | * adu_device.buflock: A spinlock, covers what IRQs touch. | ||
85 | * adutux_mutex: A Static lock to cover open_count. It would also cover | ||
86 | * any globals, but we don't have them in 2.6. | ||
87 | * adu_device.mtx: A mutex to hold across sleepers like copy_from_user. | ||
88 | * It covers all of adu_device, except the open_count | ||
89 | * and what .buflock covers. | ||
90 | */ | ||
91 | |||
82 | /* Structure to hold all of our device specific stuff */ | 92 | /* Structure to hold all of our device specific stuff */ |
83 | struct adu_device { | 93 | struct adu_device { |
84 | struct mutex mtx; /* locks this structure */ | 94 | struct mutex mtx; |
85 | struct usb_device* udev; /* save off the usb device pointer */ | 95 | struct usb_device* udev; /* save off the usb device pointer */ |
86 | struct usb_interface* interface; | 96 | struct usb_interface* interface; |
87 | unsigned char minor; /* the starting minor number for this device */ | 97 | unsigned int minor; /* the starting minor number for this device */ |
88 | char serial_number[8]; | 98 | char serial_number[8]; |
89 | 99 | ||
90 | int open_count; /* number of times this port has been opened */ | 100 | int open_count; /* number of times this port has been opened */ |
@@ -107,8 +117,11 @@ struct adu_device { | |||
107 | char* interrupt_out_buffer; | 117 | char* interrupt_out_buffer; |
108 | struct usb_endpoint_descriptor* interrupt_out_endpoint; | 118 | struct usb_endpoint_descriptor* interrupt_out_endpoint; |
109 | struct urb* interrupt_out_urb; | 119 | struct urb* interrupt_out_urb; |
120 | int out_urb_finished; | ||
110 | }; | 121 | }; |
111 | 122 | ||
123 | static DEFINE_MUTEX(adutux_mutex); | ||
124 | |||
112 | static struct usb_driver adu_driver; | 125 | static struct usb_driver adu_driver; |
113 | 126 | ||
114 | static void adu_debug_data(int level, const char *function, int size, | 127 | static void adu_debug_data(int level, const char *function, int size, |
@@ -132,27 +145,31 @@ static void adu_debug_data(int level, const char *function, int size, | |||
132 | */ | 145 | */ |
133 | static void adu_abort_transfers(struct adu_device *dev) | 146 | static void adu_abort_transfers(struct adu_device *dev) |
134 | { | 147 | { |
135 | dbg(2," %s : enter", __FUNCTION__); | 148 | unsigned long flags; |
136 | 149 | ||
137 | if (dev == NULL) { | 150 | dbg(2," %s : enter", __FUNCTION__); |
138 | dbg(1," %s : dev is null", __FUNCTION__); | ||
139 | goto exit; | ||
140 | } | ||
141 | 151 | ||
142 | if (dev->udev == NULL) { | 152 | if (dev->udev == NULL) { |
143 | dbg(1," %s : udev is null", __FUNCTION__); | 153 | dbg(1," %s : udev is null", __FUNCTION__); |
144 | goto exit; | 154 | goto exit; |
145 | } | 155 | } |
146 | 156 | ||
147 | dbg(2," %s : udev state %d", __FUNCTION__, dev->udev->state); | ||
148 | if (dev->udev->state == USB_STATE_NOTATTACHED) { | ||
149 | dbg(1," %s : udev is not attached", __FUNCTION__); | ||
150 | goto exit; | ||
151 | } | ||
152 | |||
153 | /* shutdown transfer */ | 157 | /* shutdown transfer */ |
154 | usb_unlink_urb(dev->interrupt_in_urb); | 158 | |
155 | usb_unlink_urb(dev->interrupt_out_urb); | 159 | /* XXX Anchor these instead */ |
160 | spin_lock_irqsave(&dev->buflock, flags); | ||
161 | if (!dev->read_urb_finished) { | ||
162 | spin_unlock_irqrestore(&dev->buflock, flags); | ||
163 | usb_kill_urb(dev->interrupt_in_urb); | ||
164 | } else | ||
165 | spin_unlock_irqrestore(&dev->buflock, flags); | ||
166 | |||
167 | spin_lock_irqsave(&dev->buflock, flags); | ||
168 | if (!dev->out_urb_finished) { | ||
169 | spin_unlock_irqrestore(&dev->buflock, flags); | ||
170 | usb_kill_urb(dev->interrupt_out_urb); | ||
171 | } else | ||
172 | spin_unlock_irqrestore(&dev->buflock, flags); | ||
156 | 173 | ||
157 | exit: | 174 | exit: |
158 | dbg(2," %s : leave", __FUNCTION__); | 175 | dbg(2," %s : leave", __FUNCTION__); |
@@ -162,8 +179,6 @@ static void adu_delete(struct adu_device *dev) | |||
162 | { | 179 | { |
163 | dbg(2, "%s enter", __FUNCTION__); | 180 | dbg(2, "%s enter", __FUNCTION__); |
164 | 181 | ||
165 | adu_abort_transfers(dev); | ||
166 | |||
167 | /* free data structures */ | 182 | /* free data structures */ |
168 | usb_free_urb(dev->interrupt_in_urb); | 183 | usb_free_urb(dev->interrupt_in_urb); |
169 | usb_free_urb(dev->interrupt_out_urb); | 184 | usb_free_urb(dev->interrupt_out_urb); |
@@ -239,7 +254,10 @@ static void adu_interrupt_out_callback(struct urb *urb) | |||
239 | goto exit; | 254 | goto exit; |
240 | } | 255 | } |
241 | 256 | ||
242 | wake_up_interruptible(&dev->write_wait); | 257 | spin_lock(&dev->buflock); |
258 | dev->out_urb_finished = 1; | ||
259 | wake_up(&dev->write_wait); | ||
260 | spin_unlock(&dev->buflock); | ||
243 | exit: | 261 | exit: |
244 | 262 | ||
245 | adu_debug_data(5, __FUNCTION__, urb->actual_length, | 263 | adu_debug_data(5, __FUNCTION__, urb->actual_length, |
@@ -252,12 +270,17 @@ static int adu_open(struct inode *inode, struct file *file) | |||
252 | struct adu_device *dev = NULL; | 270 | struct adu_device *dev = NULL; |
253 | struct usb_interface *interface; | 271 | struct usb_interface *interface; |
254 | int subminor; | 272 | int subminor; |
255 | int retval = 0; | 273 | int retval; |
256 | 274 | ||
257 | dbg(2,"%s : enter", __FUNCTION__); | 275 | dbg(2,"%s : enter", __FUNCTION__); |
258 | 276 | ||
259 | subminor = iminor(inode); | 277 | subminor = iminor(inode); |
260 | 278 | ||
279 | if ((retval = mutex_lock_interruptible(&adutux_mutex))) { | ||
280 | dbg(2, "%s : mutex lock failed", __FUNCTION__); | ||
281 | goto exit_no_lock; | ||
282 | } | ||
283 | |||
261 | interface = usb_find_interface(&adu_driver, subminor); | 284 | interface = usb_find_interface(&adu_driver, subminor); |
262 | if (!interface) { | 285 | if (!interface) { |
263 | err("%s - error, can't find device for minor %d", | 286 | err("%s - error, can't find device for minor %d", |
@@ -267,54 +290,54 @@ static int adu_open(struct inode *inode, struct file *file) | |||
267 | } | 290 | } |
268 | 291 | ||
269 | dev = usb_get_intfdata(interface); | 292 | dev = usb_get_intfdata(interface); |
270 | if (!dev) { | 293 | if (!dev || !dev->udev) { |
271 | retval = -ENODEV; | 294 | retval = -ENODEV; |
272 | goto exit_no_device; | 295 | goto exit_no_device; |
273 | } | 296 | } |
274 | 297 | ||
275 | /* lock this device */ | 298 | /* check that nobody else is using the device */ |
276 | if ((retval = mutex_lock_interruptible(&dev->mtx))) { | 299 | if (dev->open_count) { |
277 | dbg(2, "%s : mutex lock failed", __FUNCTION__); | 300 | retval = -EBUSY; |
278 | goto exit_no_device; | 301 | goto exit_no_device; |
279 | } | 302 | } |
280 | 303 | ||
281 | /* increment our usage count for the device */ | ||
282 | ++dev->open_count; | 304 | ++dev->open_count; |
283 | dbg(2,"%s : open count %d", __FUNCTION__, dev->open_count); | 305 | dbg(2,"%s : open count %d", __FUNCTION__, dev->open_count); |
284 | 306 | ||
285 | /* save device in the file's private structure */ | 307 | /* save device in the file's private structure */ |
286 | file->private_data = dev; | 308 | file->private_data = dev; |
287 | 309 | ||
288 | if (dev->open_count == 1) { | 310 | /* initialize in direction */ |
289 | /* initialize in direction */ | 311 | dev->read_buffer_length = 0; |
290 | dev->read_buffer_length = 0; | ||
291 | 312 | ||
292 | /* fixup first read by having urb waiting for it */ | 313 | /* fixup first read by having urb waiting for it */ |
293 | usb_fill_int_urb(dev->interrupt_in_urb,dev->udev, | 314 | usb_fill_int_urb(dev->interrupt_in_urb,dev->udev, |
294 | usb_rcvintpipe(dev->udev, | 315 | usb_rcvintpipe(dev->udev, |
295 | dev->interrupt_in_endpoint->bEndpointAddress), | 316 | dev->interrupt_in_endpoint->bEndpointAddress), |
296 | dev->interrupt_in_buffer, | 317 | dev->interrupt_in_buffer, |
297 | le16_to_cpu(dev->interrupt_in_endpoint->wMaxPacketSize), | 318 | le16_to_cpu(dev->interrupt_in_endpoint->wMaxPacketSize), |
298 | adu_interrupt_in_callback, dev, | 319 | adu_interrupt_in_callback, dev, |
299 | dev->interrupt_in_endpoint->bInterval); | 320 | dev->interrupt_in_endpoint->bInterval); |
300 | /* dev->interrupt_in_urb->transfer_flags |= URB_ASYNC_UNLINK; */ | 321 | dev->read_urb_finished = 0; |
301 | dev->read_urb_finished = 0; | 322 | if (usb_submit_urb(dev->interrupt_in_urb, GFP_KERNEL)) |
302 | retval = usb_submit_urb(dev->interrupt_in_urb, GFP_KERNEL); | 323 | dev->read_urb_finished = 1; |
303 | if (retval) | 324 | /* we ignore failure */ |
304 | --dev->open_count; | 325 | /* end of fixup for first read */ |
305 | } | 326 | |
306 | mutex_unlock(&dev->mtx); | 327 | /* initialize out direction */ |
328 | dev->out_urb_finished = 1; | ||
329 | |||
330 | retval = 0; | ||
307 | 331 | ||
308 | exit_no_device: | 332 | exit_no_device: |
333 | mutex_unlock(&adutux_mutex); | ||
334 | exit_no_lock: | ||
309 | dbg(2,"%s : leave, return value %d ", __FUNCTION__, retval); | 335 | dbg(2,"%s : leave, return value %d ", __FUNCTION__, retval); |
310 | |||
311 | return retval; | 336 | return retval; |
312 | } | 337 | } |
313 | 338 | ||
314 | static int adu_release_internal(struct adu_device *dev) | 339 | static void adu_release_internal(struct adu_device *dev) |
315 | { | 340 | { |
316 | int retval = 0; | ||
317 | |||
318 | dbg(2," %s : enter", __FUNCTION__); | 341 | dbg(2," %s : enter", __FUNCTION__); |
319 | 342 | ||
320 | /* decrement our usage count for the device */ | 343 | /* decrement our usage count for the device */ |
@@ -326,12 +349,11 @@ static int adu_release_internal(struct adu_device *dev) | |||
326 | } | 349 | } |
327 | 350 | ||
328 | dbg(2," %s : leave", __FUNCTION__); | 351 | dbg(2," %s : leave", __FUNCTION__); |
329 | return retval; | ||
330 | } | 352 | } |
331 | 353 | ||
332 | static int adu_release(struct inode *inode, struct file *file) | 354 | static int adu_release(struct inode *inode, struct file *file) |
333 | { | 355 | { |
334 | struct adu_device *dev = NULL; | 356 | struct adu_device *dev; |
335 | int retval = 0; | 357 | int retval = 0; |
336 | 358 | ||
337 | dbg(2," %s : enter", __FUNCTION__); | 359 | dbg(2," %s : enter", __FUNCTION__); |
@@ -343,15 +365,13 @@ static int adu_release(struct inode *inode, struct file *file) | |||
343 | } | 365 | } |
344 | 366 | ||
345 | dev = file->private_data; | 367 | dev = file->private_data; |
346 | |||
347 | if (dev == NULL) { | 368 | if (dev == NULL) { |
348 | dbg(1," %s : object is NULL", __FUNCTION__); | 369 | dbg(1," %s : object is NULL", __FUNCTION__); |
349 | retval = -ENODEV; | 370 | retval = -ENODEV; |
350 | goto exit; | 371 | goto exit; |
351 | } | 372 | } |
352 | 373 | ||
353 | /* lock our device */ | 374 | mutex_lock(&adutux_mutex); /* not interruptible */ |
354 | mutex_lock(&dev->mtx); /* not interruptible */ | ||
355 | 375 | ||
356 | if (dev->open_count <= 0) { | 376 | if (dev->open_count <= 0) { |
357 | dbg(1," %s : device not opened", __FUNCTION__); | 377 | dbg(1," %s : device not opened", __FUNCTION__); |
@@ -359,19 +379,15 @@ static int adu_release(struct inode *inode, struct file *file) | |||
359 | goto exit; | 379 | goto exit; |
360 | } | 380 | } |
361 | 381 | ||
382 | adu_release_internal(dev); | ||
362 | if (dev->udev == NULL) { | 383 | if (dev->udev == NULL) { |
363 | /* the device was unplugged before the file was released */ | 384 | /* the device was unplugged before the file was released */ |
364 | mutex_unlock(&dev->mtx); | 385 | if (!dev->open_count) /* ... and we're the last user */ |
365 | adu_delete(dev); | 386 | adu_delete(dev); |
366 | dev = NULL; | ||
367 | } else { | ||
368 | /* do the work */ | ||
369 | retval = adu_release_internal(dev); | ||
370 | } | 387 | } |
371 | 388 | ||
372 | exit: | 389 | exit: |
373 | if (dev) | 390 | mutex_unlock(&adutux_mutex); |
374 | mutex_unlock(&dev->mtx); | ||
375 | dbg(2," %s : leave, return value %d", __FUNCTION__, retval); | 391 | dbg(2," %s : leave, return value %d", __FUNCTION__, retval); |
376 | return retval; | 392 | return retval; |
377 | } | 393 | } |
@@ -393,12 +409,12 @@ static ssize_t adu_read(struct file *file, __user char *buffer, size_t count, | |||
393 | 409 | ||
394 | dev = file->private_data; | 410 | dev = file->private_data; |
395 | dbg(2," %s : dev=%p", __FUNCTION__, dev); | 411 | dbg(2," %s : dev=%p", __FUNCTION__, dev); |
396 | /* lock this object */ | 412 | |
397 | if (mutex_lock_interruptible(&dev->mtx)) | 413 | if (mutex_lock_interruptible(&dev->mtx)) |
398 | return -ERESTARTSYS; | 414 | return -ERESTARTSYS; |
399 | 415 | ||
400 | /* verify that the device wasn't unplugged */ | 416 | /* verify that the device wasn't unplugged */ |
401 | if (dev->udev == NULL || dev->minor == 0) { | 417 | if (dev->udev == NULL) { |
402 | retval = -ENODEV; | 418 | retval = -ENODEV; |
403 | err("No device or device unplugged %d", retval); | 419 | err("No device or device unplugged %d", retval); |
404 | goto exit; | 420 | goto exit; |
@@ -452,7 +468,7 @@ static ssize_t adu_read(struct file *file, __user char *buffer, size_t count, | |||
452 | should_submit = 1; | 468 | should_submit = 1; |
453 | } else { | 469 | } else { |
454 | /* even the primary was empty - we may need to do IO */ | 470 | /* even the primary was empty - we may need to do IO */ |
455 | if (dev->interrupt_in_urb->status == -EINPROGRESS) { | 471 | if (!dev->read_urb_finished) { |
456 | /* somebody is doing IO */ | 472 | /* somebody is doing IO */ |
457 | spin_unlock_irqrestore(&dev->buflock, flags); | 473 | spin_unlock_irqrestore(&dev->buflock, flags); |
458 | dbg(2," %s : submitted already", __FUNCTION__); | 474 | dbg(2," %s : submitted already", __FUNCTION__); |
@@ -460,6 +476,7 @@ static ssize_t adu_read(struct file *file, __user char *buffer, size_t count, | |||
460 | /* we must initiate input */ | 476 | /* we must initiate input */ |
461 | dbg(2," %s : initiate input", __FUNCTION__); | 477 | dbg(2," %s : initiate input", __FUNCTION__); |
462 | dev->read_urb_finished = 0; | 478 | dev->read_urb_finished = 0; |
479 | spin_unlock_irqrestore(&dev->buflock, flags); | ||
463 | 480 | ||
464 | usb_fill_int_urb(dev->interrupt_in_urb,dev->udev, | 481 | usb_fill_int_urb(dev->interrupt_in_urb,dev->udev, |
465 | usb_rcvintpipe(dev->udev, | 482 | usb_rcvintpipe(dev->udev, |
@@ -469,15 +486,12 @@ static ssize_t adu_read(struct file *file, __user char *buffer, size_t count, | |||
469 | adu_interrupt_in_callback, | 486 | adu_interrupt_in_callback, |
470 | dev, | 487 | dev, |
471 | dev->interrupt_in_endpoint->bInterval); | 488 | dev->interrupt_in_endpoint->bInterval); |
472 | retval = usb_submit_urb(dev->interrupt_in_urb, GFP_ATOMIC); | 489 | retval = usb_submit_urb(dev->interrupt_in_urb, GFP_KERNEL); |
473 | if (!retval) { | 490 | if (retval) { |
474 | spin_unlock_irqrestore(&dev->buflock, flags); | 491 | dev->read_urb_finished = 1; |
475 | dbg(2," %s : submitted OK", __FUNCTION__); | ||
476 | } else { | ||
477 | if (retval == -ENOMEM) { | 492 | if (retval == -ENOMEM) { |
478 | retval = bytes_read ? bytes_read : -ENOMEM; | 493 | retval = bytes_read ? bytes_read : -ENOMEM; |
479 | } | 494 | } |
480 | spin_unlock_irqrestore(&dev->buflock, flags); | ||
481 | dbg(2," %s : submit failed", __FUNCTION__); | 495 | dbg(2," %s : submit failed", __FUNCTION__); |
482 | goto exit; | 496 | goto exit; |
483 | } | 497 | } |
@@ -486,10 +500,14 @@ static ssize_t adu_read(struct file *file, __user char *buffer, size_t count, | |||
486 | /* we wait for I/O to complete */ | 500 | /* we wait for I/O to complete */ |
487 | set_current_state(TASK_INTERRUPTIBLE); | 501 | set_current_state(TASK_INTERRUPTIBLE); |
488 | add_wait_queue(&dev->read_wait, &wait); | 502 | add_wait_queue(&dev->read_wait, &wait); |
489 | if (!dev->read_urb_finished) | 503 | spin_lock_irqsave(&dev->buflock, flags); |
504 | if (!dev->read_urb_finished) { | ||
505 | spin_unlock_irqrestore(&dev->buflock, flags); | ||
490 | timeout = schedule_timeout(COMMAND_TIMEOUT); | 506 | timeout = schedule_timeout(COMMAND_TIMEOUT); |
491 | else | 507 | } else { |
508 | spin_unlock_irqrestore(&dev->buflock, flags); | ||
492 | set_current_state(TASK_RUNNING); | 509 | set_current_state(TASK_RUNNING); |
510 | } | ||
493 | remove_wait_queue(&dev->read_wait, &wait); | 511 | remove_wait_queue(&dev->read_wait, &wait); |
494 | 512 | ||
495 | if (timeout <= 0) { | 513 | if (timeout <= 0) { |
@@ -509,19 +527,23 @@ static ssize_t adu_read(struct file *file, __user char *buffer, size_t count, | |||
509 | 527 | ||
510 | retval = bytes_read; | 528 | retval = bytes_read; |
511 | /* if the primary buffer is empty then use it */ | 529 | /* if the primary buffer is empty then use it */ |
512 | if (should_submit && !dev->interrupt_in_urb->status==-EINPROGRESS) { | 530 | spin_lock_irqsave(&dev->buflock, flags); |
531 | if (should_submit && dev->read_urb_finished) { | ||
532 | dev->read_urb_finished = 0; | ||
533 | spin_unlock_irqrestore(&dev->buflock, flags); | ||
513 | usb_fill_int_urb(dev->interrupt_in_urb,dev->udev, | 534 | usb_fill_int_urb(dev->interrupt_in_urb,dev->udev, |
514 | usb_rcvintpipe(dev->udev, | 535 | usb_rcvintpipe(dev->udev, |
515 | dev->interrupt_in_endpoint->bEndpointAddress), | 536 | dev->interrupt_in_endpoint->bEndpointAddress), |
516 | dev->interrupt_in_buffer, | 537 | dev->interrupt_in_buffer, |
517 | le16_to_cpu(dev->interrupt_in_endpoint->wMaxPacketSize), | 538 | le16_to_cpu(dev->interrupt_in_endpoint->wMaxPacketSize), |
518 | adu_interrupt_in_callback, | 539 | adu_interrupt_in_callback, |
519 | dev, | 540 | dev, |
520 | dev->interrupt_in_endpoint->bInterval); | 541 | dev->interrupt_in_endpoint->bInterval); |
521 | /* dev->interrupt_in_urb->transfer_flags |= URB_ASYNC_UNLINK; */ | 542 | if (usb_submit_urb(dev->interrupt_in_urb, GFP_KERNEL) != 0) |
522 | dev->read_urb_finished = 0; | 543 | dev->read_urb_finished = 1; |
523 | usb_submit_urb(dev->interrupt_in_urb, GFP_KERNEL); | ||
524 | /* we ignore failure */ | 544 | /* we ignore failure */ |
545 | } else { | ||
546 | spin_unlock_irqrestore(&dev->buflock, flags); | ||
525 | } | 547 | } |
526 | 548 | ||
527 | exit: | 549 | exit: |
@@ -535,24 +557,24 @@ exit: | |||
535 | static ssize_t adu_write(struct file *file, const __user char *buffer, | 557 | static ssize_t adu_write(struct file *file, const __user char *buffer, |
536 | size_t count, loff_t *ppos) | 558 | size_t count, loff_t *ppos) |
537 | { | 559 | { |
560 | DECLARE_WAITQUEUE(waita, current); | ||
538 | struct adu_device *dev; | 561 | struct adu_device *dev; |
539 | size_t bytes_written = 0; | 562 | size_t bytes_written = 0; |
540 | size_t bytes_to_write; | 563 | size_t bytes_to_write; |
541 | size_t buffer_size; | 564 | size_t buffer_size; |
565 | unsigned long flags; | ||
542 | int retval; | 566 | int retval; |
543 | int timeout = 0; | ||
544 | 567 | ||
545 | dbg(2," %s : enter, count = %Zd", __FUNCTION__, count); | 568 | dbg(2," %s : enter, count = %Zd", __FUNCTION__, count); |
546 | 569 | ||
547 | dev = file->private_data; | 570 | dev = file->private_data; |
548 | 571 | ||
549 | /* lock this object */ | ||
550 | retval = mutex_lock_interruptible(&dev->mtx); | 572 | retval = mutex_lock_interruptible(&dev->mtx); |
551 | if (retval) | 573 | if (retval) |
552 | goto exit_nolock; | 574 | goto exit_nolock; |
553 | 575 | ||
554 | /* verify that the device wasn't unplugged */ | 576 | /* verify that the device wasn't unplugged */ |
555 | if (dev->udev == NULL || dev->minor == 0) { | 577 | if (dev->udev == NULL) { |
556 | retval = -ENODEV; | 578 | retval = -ENODEV; |
557 | err("No device or device unplugged %d", retval); | 579 | err("No device or device unplugged %d", retval); |
558 | goto exit; | 580 | goto exit; |
@@ -564,42 +586,37 @@ static ssize_t adu_write(struct file *file, const __user char *buffer, | |||
564 | goto exit; | 586 | goto exit; |
565 | } | 587 | } |
566 | 588 | ||
567 | |||
568 | while (count > 0) { | 589 | while (count > 0) { |
569 | if (dev->interrupt_out_urb->status == -EINPROGRESS) { | 590 | add_wait_queue(&dev->write_wait, &waita); |
570 | timeout = COMMAND_TIMEOUT; | 591 | set_current_state(TASK_INTERRUPTIBLE); |
592 | spin_lock_irqsave(&dev->buflock, flags); | ||
593 | if (!dev->out_urb_finished) { | ||
594 | spin_unlock_irqrestore(&dev->buflock, flags); | ||
571 | 595 | ||
572 | while (timeout > 0) { | 596 | mutex_unlock(&dev->mtx); |
573 | if (signal_pending(current)) { | 597 | if (signal_pending(current)) { |
574 | dbg(1," %s : interrupted", __FUNCTION__); | 598 | dbg(1," %s : interrupted", __FUNCTION__); |
599 | set_current_state(TASK_RUNNING); | ||
575 | retval = -EINTR; | 600 | retval = -EINTR; |
576 | goto exit; | 601 | goto exit_onqueue; |
577 | } | 602 | } |
578 | mutex_unlock(&dev->mtx); | 603 | if (schedule_timeout(COMMAND_TIMEOUT) == 0) { |
579 | timeout = interruptible_sleep_on_timeout(&dev->write_wait, timeout); | 604 | dbg(1, "%s - command timed out.", __FUNCTION__); |
605 | retval = -ETIMEDOUT; | ||
606 | goto exit_onqueue; | ||
607 | } | ||
608 | remove_wait_queue(&dev->write_wait, &waita); | ||
580 | retval = mutex_lock_interruptible(&dev->mtx); | 609 | retval = mutex_lock_interruptible(&dev->mtx); |
581 | if (retval) { | 610 | if (retval) { |
582 | retval = bytes_written ? bytes_written : retval; | 611 | retval = bytes_written ? bytes_written : retval; |
583 | goto exit_nolock; | 612 | goto exit_nolock; |
584 | } | 613 | } |
585 | if (timeout > 0) { | ||
586 | break; | ||
587 | } | ||
588 | dbg(1," %s : interrupted timeout: %d", __FUNCTION__, timeout); | ||
589 | } | ||
590 | |||
591 | |||
592 | dbg(1," %s : final timeout: %d", __FUNCTION__, timeout); | ||
593 | |||
594 | if (timeout == 0) { | ||
595 | dbg(1, "%s - command timed out.", __FUNCTION__); | ||
596 | retval = -ETIMEDOUT; | ||
597 | goto exit; | ||
598 | } | ||
599 | |||
600 | dbg(4," %s : in progress, count = %Zd", __FUNCTION__, count); | ||
601 | 614 | ||
615 | dbg(4," %s : in progress, count = %Zd", __FUNCTION__, count); | ||
602 | } else { | 616 | } else { |
617 | spin_unlock_irqrestore(&dev->buflock, flags); | ||
618 | set_current_state(TASK_RUNNING); | ||
619 | remove_wait_queue(&dev->write_wait, &waita); | ||
603 | dbg(4," %s : sending, count = %Zd", __FUNCTION__, count); | 620 | dbg(4," %s : sending, count = %Zd", __FUNCTION__, count); |
604 | 621 | ||
605 | /* write the data into interrupt_out_buffer from userspace */ | 622 | /* write the data into interrupt_out_buffer from userspace */ |
@@ -622,11 +639,12 @@ static ssize_t adu_write(struct file *file, const __user char *buffer, | |||
622 | bytes_to_write, | 639 | bytes_to_write, |
623 | adu_interrupt_out_callback, | 640 | adu_interrupt_out_callback, |
624 | dev, | 641 | dev, |
625 | dev->interrupt_in_endpoint->bInterval); | 642 | dev->interrupt_out_endpoint->bInterval); |
626 | /* dev->interrupt_in_urb->transfer_flags |= URB_ASYNC_UNLINK; */ | ||
627 | dev->interrupt_out_urb->actual_length = bytes_to_write; | 643 | dev->interrupt_out_urb->actual_length = bytes_to_write; |
644 | dev->out_urb_finished = 0; | ||
628 | retval = usb_submit_urb(dev->interrupt_out_urb, GFP_KERNEL); | 645 | retval = usb_submit_urb(dev->interrupt_out_urb, GFP_KERNEL); |
629 | if (retval < 0) { | 646 | if (retval < 0) { |
647 | dev->out_urb_finished = 1; | ||
630 | err("Couldn't submit interrupt_out_urb %d", retval); | 648 | err("Couldn't submit interrupt_out_urb %d", retval); |
631 | goto exit; | 649 | goto exit; |
632 | } | 650 | } |
@@ -637,16 +655,17 @@ static ssize_t adu_write(struct file *file, const __user char *buffer, | |||
637 | bytes_written += bytes_to_write; | 655 | bytes_written += bytes_to_write; |
638 | } | 656 | } |
639 | } | 657 | } |
640 | 658 | mutex_unlock(&dev->mtx); | |
641 | retval = bytes_written; | 659 | return bytes_written; |
642 | 660 | ||
643 | exit: | 661 | exit: |
644 | /* unlock the device */ | ||
645 | mutex_unlock(&dev->mtx); | 662 | mutex_unlock(&dev->mtx); |
646 | exit_nolock: | 663 | exit_nolock: |
647 | |||
648 | dbg(2," %s : leave, return value %d", __FUNCTION__, retval); | 664 | dbg(2," %s : leave, return value %d", __FUNCTION__, retval); |
665 | return retval; | ||
649 | 666 | ||
667 | exit_onqueue: | ||
668 | remove_wait_queue(&dev->write_wait, &waita); | ||
650 | return retval; | 669 | return retval; |
651 | } | 670 | } |
652 | 671 | ||
@@ -831,25 +850,22 @@ static void adu_disconnect(struct usb_interface *interface) | |||
831 | dbg(2," %s : enter", __FUNCTION__); | 850 | dbg(2," %s : enter", __FUNCTION__); |
832 | 851 | ||
833 | dev = usb_get_intfdata(interface); | 852 | dev = usb_get_intfdata(interface); |
834 | usb_set_intfdata(interface, NULL); | ||
835 | 853 | ||
854 | mutex_lock(&dev->mtx); /* not interruptible */ | ||
855 | dev->udev = NULL; /* poison */ | ||
836 | minor = dev->minor; | 856 | minor = dev->minor; |
837 | |||
838 | /* give back our minor */ | ||
839 | usb_deregister_dev(interface, &adu_class); | 857 | usb_deregister_dev(interface, &adu_class); |
840 | dev->minor = 0; | 858 | mutex_unlock(&dev->mtx); |
841 | 859 | ||
842 | mutex_lock(&dev->mtx); /* not interruptible */ | 860 | mutex_lock(&adutux_mutex); |
861 | usb_set_intfdata(interface, NULL); | ||
843 | 862 | ||
844 | /* if the device is not opened, then we clean up right now */ | 863 | /* if the device is not opened, then we clean up right now */ |
845 | dbg(2," %s : open count %d", __FUNCTION__, dev->open_count); | 864 | dbg(2," %s : open count %d", __FUNCTION__, dev->open_count); |
846 | if (!dev->open_count) { | 865 | if (!dev->open_count) |
847 | mutex_unlock(&dev->mtx); | ||
848 | adu_delete(dev); | 866 | adu_delete(dev); |
849 | } else { | 867 | |
850 | dev->udev = NULL; | 868 | mutex_unlock(&adutux_mutex); |
851 | mutex_unlock(&dev->mtx); | ||
852 | } | ||
853 | 869 | ||
854 | dev_info(&interface->dev, "ADU device adutux%d now disconnected\n", | 870 | dev_info(&interface->dev, "ADU device adutux%d now disconnected\n", |
855 | (minor - ADU_MINOR_BASE)); | 871 | (minor - ADU_MINOR_BASE)); |
diff --git a/drivers/usb/misc/usbled.c b/drivers/usb/misc/usbled.c index 49c5c5c4c431..06cb71942dc7 100644 --- a/drivers/usb/misc/usbled.c +++ b/drivers/usb/misc/usbled.c | |||
@@ -144,12 +144,14 @@ static void led_disconnect(struct usb_interface *interface) | |||
144 | struct usb_led *dev; | 144 | struct usb_led *dev; |
145 | 145 | ||
146 | dev = usb_get_intfdata (interface); | 146 | dev = usb_get_intfdata (interface); |
147 | usb_set_intfdata (interface, NULL); | ||
148 | 147 | ||
149 | device_remove_file(&interface->dev, &dev_attr_blue); | 148 | device_remove_file(&interface->dev, &dev_attr_blue); |
150 | device_remove_file(&interface->dev, &dev_attr_red); | 149 | device_remove_file(&interface->dev, &dev_attr_red); |
151 | device_remove_file(&interface->dev, &dev_attr_green); | 150 | device_remove_file(&interface->dev, &dev_attr_green); |
152 | 151 | ||
152 | /* first remove the files, then set the pointer to NULL */ | ||
153 | usb_set_intfdata (interface, NULL); | ||
154 | |||
153 | usb_put_dev(dev->udev); | 155 | usb_put_dev(dev->udev); |
154 | 156 | ||
155 | kfree(dev); | 157 | kfree(dev); |
diff --git a/drivers/usb/serial/generic.c b/drivers/usb/serial/generic.c index 9eb4a65ee4d9..d41531139c55 100644 --- a/drivers/usb/serial/generic.c +++ b/drivers/usb/serial/generic.c | |||
@@ -327,6 +327,7 @@ void usb_serial_generic_read_bulk_callback (struct urb *urb) | |||
327 | struct usb_serial_port *port = (struct usb_serial_port *)urb->context; | 327 | struct usb_serial_port *port = (struct usb_serial_port *)urb->context; |
328 | unsigned char *data = urb->transfer_buffer; | 328 | unsigned char *data = urb->transfer_buffer; |
329 | int status = urb->status; | 329 | int status = urb->status; |
330 | unsigned long flags; | ||
330 | 331 | ||
331 | dbg("%s - port %d", __FUNCTION__, port->number); | 332 | dbg("%s - port %d", __FUNCTION__, port->number); |
332 | 333 | ||
@@ -339,11 +340,11 @@ void usb_serial_generic_read_bulk_callback (struct urb *urb) | |||
339 | usb_serial_debug_data(debug, &port->dev, __FUNCTION__, urb->actual_length, data); | 340 | usb_serial_debug_data(debug, &port->dev, __FUNCTION__, urb->actual_length, data); |
340 | 341 | ||
341 | /* Throttle the device if requested by tty */ | 342 | /* Throttle the device if requested by tty */ |
342 | spin_lock(&port->lock); | 343 | spin_lock_irqsave(&port->lock, flags); |
343 | if (!(port->throttled = port->throttle_req)) | 344 | if (!(port->throttled = port->throttle_req)) |
344 | /* Handle data and continue reading from device */ | 345 | /* Handle data and continue reading from device */ |
345 | flush_and_resubmit_read_urb(port); | 346 | flush_and_resubmit_read_urb(port); |
346 | spin_unlock(&port->lock); | 347 | spin_unlock_irqrestore(&port->lock, flags); |
347 | } | 348 | } |
348 | EXPORT_SYMBOL_GPL(usb_serial_generic_read_bulk_callback); | 349 | EXPORT_SYMBOL_GPL(usb_serial_generic_read_bulk_callback); |
349 | 350 | ||
diff --git a/drivers/usb/serial/mos7840.c b/drivers/usb/serial/mos7840.c index a5ced7e08cbf..c29c91271133 100644 --- a/drivers/usb/serial/mos7840.c +++ b/drivers/usb/serial/mos7840.c | |||
@@ -2711,7 +2711,7 @@ static int mos7840_startup(struct usb_serial *serial) | |||
2711 | status = mos7840_set_reg_sync(serial->port[0], ZLP_REG5, Data); | 2711 | status = mos7840_set_reg_sync(serial->port[0], ZLP_REG5, Data); |
2712 | if (status < 0) { | 2712 | if (status < 0) { |
2713 | dbg("Writing ZLP_REG5 failed status-0x%x\n", status); | 2713 | dbg("Writing ZLP_REG5 failed status-0x%x\n", status); |
2714 | return -1; | 2714 | goto error; |
2715 | } else | 2715 | } else |
2716 | dbg("ZLP_REG5 Writing success status%d\n", status); | 2716 | dbg("ZLP_REG5 Writing success status%d\n", status); |
2717 | 2717 | ||
diff --git a/drivers/usb/serial/pl2303.c b/drivers/usb/serial/pl2303.c index 2cd3f1d4b687..cf8add91de05 100644 --- a/drivers/usb/serial/pl2303.c +++ b/drivers/usb/serial/pl2303.c | |||
@@ -86,6 +86,7 @@ static struct usb_device_id id_table [] = { | |||
86 | { USB_DEVICE(ALCOR_VENDOR_ID, ALCOR_PRODUCT_ID) }, | 86 | { USB_DEVICE(ALCOR_VENDOR_ID, ALCOR_PRODUCT_ID) }, |
87 | { USB_DEVICE(HUAWEI_VENDOR_ID, HUAWEI_PRODUCT_ID) }, | 87 | { USB_DEVICE(HUAWEI_VENDOR_ID, HUAWEI_PRODUCT_ID) }, |
88 | { USB_DEVICE(WS002IN_VENDOR_ID, WS002IN_PRODUCT_ID) }, | 88 | { USB_DEVICE(WS002IN_VENDOR_ID, WS002IN_PRODUCT_ID) }, |
89 | { USB_DEVICE(COREGA_VENDOR_ID, COREGA_PRODUCT_ID) }, | ||
89 | { } /* Terminating entry */ | 90 | { } /* Terminating entry */ |
90 | }; | 91 | }; |
91 | 92 | ||
diff --git a/drivers/usb/serial/pl2303.h b/drivers/usb/serial/pl2303.h index ed603e3decd6..d31f5d299989 100644 --- a/drivers/usb/serial/pl2303.h +++ b/drivers/usb/serial/pl2303.h | |||
@@ -104,3 +104,6 @@ | |||
104 | #define WS002IN_VENDOR_ID 0x11f6 | 104 | #define WS002IN_VENDOR_ID 0x11f6 |
105 | #define WS002IN_PRODUCT_ID 0x2001 | 105 | #define WS002IN_PRODUCT_ID 0x2001 |
106 | 106 | ||
107 | /* Corega CG-USBRS232R Serial Adapter */ | ||
108 | #define COREGA_VENDOR_ID 0x07aa | ||
109 | #define COREGA_PRODUCT_ID 0x002a | ||
diff --git a/drivers/usb/serial/sierra.c b/drivers/usb/serial/sierra.c index 833f6e1e3721..605ebccdcd51 100644 --- a/drivers/usb/serial/sierra.c +++ b/drivers/usb/serial/sierra.c | |||
@@ -136,6 +136,8 @@ static struct usb_device_id id_table_3port [] = { | |||
136 | { USB_DEVICE(0x0f30, 0x1b1d) }, /* Sierra Wireless MC5720 */ | 136 | { USB_DEVICE(0x0f30, 0x1b1d) }, /* Sierra Wireless MC5720 */ |
137 | { USB_DEVICE(0x1199, 0x0218) }, /* Sierra Wireless MC5720 */ | 137 | { USB_DEVICE(0x1199, 0x0218) }, /* Sierra Wireless MC5720 */ |
138 | { USB_DEVICE(0x1199, 0x0020) }, /* Sierra Wireless MC5725 */ | 138 | { USB_DEVICE(0x1199, 0x0020) }, /* Sierra Wireless MC5725 */ |
139 | { USB_DEVICE(0x1199, 0x0220) }, /* Sierra Wireless MC5725 */ | ||
140 | { USB_DEVICE(0x1199, 0x0220) }, /* Sierra Wireless MC5725 */ | ||
139 | { USB_DEVICE(0x1199, 0x0019) }, /* Sierra Wireless AirCard 595 */ | 141 | { USB_DEVICE(0x1199, 0x0019) }, /* Sierra Wireless AirCard 595 */ |
140 | { USB_DEVICE(0x1199, 0x0021) }, /* Sierra Wireless AirCard 597E */ | 142 | { USB_DEVICE(0x1199, 0x0021) }, /* Sierra Wireless AirCard 597E */ |
141 | { USB_DEVICE(0x1199, 0x0120) }, /* Sierra Wireless USB Dongle 595U*/ | 143 | { USB_DEVICE(0x1199, 0x0120) }, /* Sierra Wireless USB Dongle 595U*/ |
diff --git a/drivers/usb/storage/scsiglue.c b/drivers/usb/storage/scsiglue.c index 1ba19eaa1970..836a34ae6ec6 100644 --- a/drivers/usb/storage/scsiglue.c +++ b/drivers/usb/storage/scsiglue.c | |||
@@ -177,6 +177,10 @@ static int slave_configure(struct scsi_device *sdev) | |||
177 | * is an occasional series of retries that will all fail. */ | 177 | * is an occasional series of retries that will all fail. */ |
178 | sdev->retry_hwerror = 1; | 178 | sdev->retry_hwerror = 1; |
179 | 179 | ||
180 | /* USB disks should allow restart. Some drives spin down | ||
181 | * automatically, requiring a START-STOP UNIT command. */ | ||
182 | sdev->allow_restart = 1; | ||
183 | |||
180 | } else { | 184 | } else { |
181 | 185 | ||
182 | /* Non-disk-type devices don't need to blacklist any pages | 186 | /* Non-disk-type devices don't need to blacklist any pages |
diff --git a/drivers/usb/storage/unusual_devs.h b/drivers/usb/storage/unusual_devs.h index 22ab2380367d..2c27721bd259 100644 --- a/drivers/usb/storage/unusual_devs.h +++ b/drivers/usb/storage/unusual_devs.h | |||
@@ -342,11 +342,11 @@ UNUSUAL_DEV( 0x04b0, 0x040d, 0x0100, 0x0100, | |||
342 | US_FL_FIX_CAPACITY), | 342 | US_FL_FIX_CAPACITY), |
343 | 343 | ||
344 | /* Reported by Graber and Mike Pagano <mpagano-kernel@mpagano.com> */ | 344 | /* Reported by Graber and Mike Pagano <mpagano-kernel@mpagano.com> */ |
345 | UNUSUAL_DEV( 0x04b0, 0x040f, 0x0200, 0x0200, | 345 | UNUSUAL_DEV( 0x04b0, 0x040f, 0x0100, 0x0200, |
346 | "NIKON", | 346 | "NIKON", |
347 | "NIKON DSC D200", | 347 | "NIKON DSC D200", |
348 | US_SC_DEVICE, US_PR_DEVICE, NULL, | 348 | US_SC_DEVICE, US_PR_DEVICE, NULL, |
349 | US_FL_FIX_CAPACITY), | 349 | US_FL_FIX_CAPACITY), |
350 | 350 | ||
351 | /* Reported by Emil Larsson <emil@swip.net> */ | 351 | /* Reported by Emil Larsson <emil@swip.net> */ |
352 | UNUSUAL_DEV( 0x04b0, 0x0411, 0x0100, 0x0101, | 352 | UNUSUAL_DEV( 0x04b0, 0x0411, 0x0100, 0x0101, |
@@ -731,6 +731,13 @@ UNUSUAL_DEV( 0x0584, 0x0008, 0x0102, 0x0102, | |||
731 | US_SC_SCSI, US_PR_ALAUDA, init_alauda, 0 ), | 731 | US_SC_SCSI, US_PR_ALAUDA, init_alauda, 0 ), |
732 | #endif | 732 | #endif |
733 | 733 | ||
734 | /* Reported by RTE <raszilki@yandex.ru> */ | ||
735 | UNUSUAL_DEV( 0x058f, 0x6387, 0x0141, 0x0141, | ||
736 | "JetFlash", | ||
737 | "TS1GJF2A/120", | ||
738 | US_SC_DEVICE, US_PR_DEVICE, NULL, | ||
739 | US_FL_MAX_SECTORS_64 ), | ||
740 | |||
734 | /* Fabrizio Fellini <fello@libero.it> */ | 741 | /* Fabrizio Fellini <fello@libero.it> */ |
735 | UNUSUAL_DEV( 0x0595, 0x4343, 0x0000, 0x2210, | 742 | UNUSUAL_DEV( 0x0595, 0x4343, 0x0000, 0x2210, |
736 | "Fujifilm", | 743 | "Fujifilm", |
diff --git a/include/linux/usb.h b/include/linux/usb.h index c5c8f169d3cf..416ee7617d9e 100644 --- a/include/linux/usb.h +++ b/include/linux/usb.h | |||
@@ -157,6 +157,7 @@ struct usb_interface { | |||
157 | * bound to */ | 157 | * bound to */ |
158 | enum usb_interface_condition condition; /* state of binding */ | 158 | enum usb_interface_condition condition; /* state of binding */ |
159 | unsigned is_active:1; /* the interface is not suspended */ | 159 | unsigned is_active:1; /* the interface is not suspended */ |
160 | unsigned sysfs_files_created:1; /* the sysfs attributes exist */ | ||
160 | unsigned needs_remote_wakeup:1; /* driver requires remote wakeup */ | 161 | unsigned needs_remote_wakeup:1; /* driver requires remote wakeup */ |
161 | 162 | ||
162 | struct device dev; /* interface specific device info */ | 163 | struct device dev; /* interface specific device info */ |
diff --git a/include/linux/usbdevice_fs.h b/include/linux/usbdevice_fs.h index 342dd5a7e8bb..8ca5a7fbc9ec 100644 --- a/include/linux/usbdevice_fs.h +++ b/include/linux/usbdevice_fs.h | |||
@@ -102,7 +102,8 @@ struct usbdevfs_urb { | |||
102 | int start_frame; | 102 | int start_frame; |
103 | int number_of_packets; | 103 | int number_of_packets; |
104 | int error_count; | 104 | int error_count; |
105 | unsigned int signr; /* signal to be sent on error, -1 if none should be sent */ | 105 | unsigned int signr; /* signal to be sent on completion, |
106 | or 0 if none should be sent. */ | ||
106 | void *usercontext; | 107 | void *usercontext; |
107 | struct usbdevfs_iso_packet_desc iso_frame_desc[0]; | 108 | struct usbdevfs_iso_packet_desc iso_frame_desc[0]; |
108 | }; | 109 | }; |