summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* usb: musb: host: unmap the buffer for PIO data transfersMaulik Mankad2010-10-223-1/+8
| | | | | | | | | | | | | | | The USB stack maps the buffer for DMA if the controller supports DMA. MUSB controller can perform DMA as well as PIO transfers. The buffer needs to be unmapped before CPU can perform PIO data transfers. Export unmap_urb_for_dma() so that drivers can perform the DMA unmapping in a sane way. Signed-off-by: Maulik Mankad <x0082077@ti.com> Acked-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* usb: musb: musbhsdma: increase max_len to 1MBAnil Shetty2010-10-221-1/+1
| | | | | | | | | MUSB's DMA controller max channel length was set to 64k. Transfer length greater than this max value is being truncated. Signed-off-by: Anil Shetty <anil@ti.com> Signed-off-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* usb: musb: support ISO high bandwidth for gadget modeMing Lei2010-10-222-12/+39
| | | | | | | | | | | | | | This patch has been tested OK on beagle B5 board and use usbtest #15 and #16 as testcase. Signed-off-by: Ming Lei <tom.leiming@gmail.com> Reviewed-by: Sergei Shtylyov <sshtylyov@mvista.com> Cc: David Brownell <dbrownell@users.sourceforge.net> Cc: Anand Gadiyar <gadiyar@ti.com> Cc: Mike Frysinger <vapier@gentoo.org> Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* usb: musb: introduce DA8xx/OMAP-L1x glue layerSergei Shtylyov2010-10-224-1/+478
| | | | | | | | | | | Texas Instruments DA8xx/OMAP-L1x glue layer for the MUSBMHRDC driver. Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Yadviga Grigorieva <yadviga@ru.mvista.com> Signed-off-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: musb: make DBG() calls actually depend on CONFIG_USB_MUSB_DEBUGSergei Shtylyov2010-10-221-7/+4
| | | | | | | | | | | | | | | | | Enabling CONFIG_USB_MUSB_DEBUG option causes -DDEBUG to be added to gcc's command line, however the DBG() macro doesn't depend on DEBUG, so that the debugging messages get printed regardless of the option, and I don't think that this was intended. Get rid of otherwise unused xprintk() macro and make DBG() macro directly call pr_debug() which only results in the actual code generated if DEBUG is defined. This change makes musb_hdrc.o ~30% less in size with CONFIG_USB_MUSB_DEBUG disabled (in host mode). Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: yurex: fix memory leak and corrupted messagesTomoki Sekiyama2010-10-221-6/+17
| | | | | | | | | This fixes the memory leak on disconnecting the device. In addition, it fixes some messages corrupted by incorrect encoding. Signed-off-by: Tomoki Sekiyama <tomoki.sekiyama@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: yurex: assign a real minor number to the driverGreg Kroah-Hartman2010-10-222-3/+6
| | | | | | | | | This assigns the minor number 192 to the yurex driver. We also fix up the previous usb minor number entry, it was wrong. Cc: Tomoki Sekiyama <tomoki.sekiyama@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: add driver for Meywa-Denki & Kayac YUREXTomoki Sekiyama2010-10-225-0/+570
| | | | | | | | | | | | | | Meywa-Denki/Kayac YUREX is a leg-shakes sensor device. See http://bbu.kayac.com/en/about/ for further information. This driver support read/write the leg-shakes counter in the device via a device file /dev/yurex[0-9]*. [minor coding style cleanups fixed by gregkh] Signed-off-by: Tomoki Sekiyama <tomoki.sekiyama@gmail.com> Cc: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: gadget: file_storage: reuse definitions from a header fileMichal Nazarewicz2010-10-221-13/+1
| | | | | | | | | | | This commit changes storage_common.c and file_storage.c to reuse definitions from linux/usb/storage.h header file. Signed-off-by: Michal Nazarewicz <mina86@mina86.com> Cc: Alan Stern <stern@rowland.harvard.edu> Cc: Matthew Wilcox <willy@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: Add UAS driverMatthew Wilcox2010-10-224-0/+773
| | | | | | | | | | | | USB Attached SCSI is a new protocol specified jointly by the SCSI T10 committee and the USB Implementors Forum. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Matthew Dharm <mdharm-usb@one-eyed-alien.net> [mina86@mina86.com: updated to use new USB_ prefix] Signed-off-by: Michal Nazarewicz <mina86@mina86.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: Move USB Storage definitions to their own header fileMatthew Wilcox2010-10-222-37/+49
| | | | | | | | | | | | | | The libusual header file is hard to use from code that isn't part of libusual. As the comment suggests, these definitions are moved to their own header file, paralleling other USB classes. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Alan Stern <stern@rowland.harvard.edu> [mina86@mina86.com: updated to use USB_ prefix and added #include guard] Signed-off-by: Michal Nazarewicz <mina86@mina86.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> index 0000000..d7fc910
* USB: storage: Use USB_ prefix instead of US_ prefixMichal Nazarewicz2010-10-2218-380/+381
| | | | | | | | | | | | This commit changes prefix for some of the USB mass storage class related macros (ie. USB_SC_ for subclass and USB_PR_ for class). Signed-off-by: Michal Nazarewicz <mina86@mina86.com> Cc: Alan Stern <stern@rowland.harvard.edu> Cc: Matthew Wilcox <willy@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: qcserial: Enable Diagnostics Monitor and GPS ports on Gobi 2000Matthias G. Eckermann2010-10-221-1/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | this patch to qcserial.c enables the Diagnostics Monitor and NMEA GPS ports on Qualcomm Gobi 2000 devices. A Gobi 2000 device will provide 3 serial ports: # /dev/ttyUSB0 -> Diagnostics # /dev/ttyUSB1 -> 3G Modem # /dev/ttyUSB2 -> NMEA GPS port * The Diagnostics Monitor uses Qualcomm's DM protocol; I used libqcdm (ModemManager) to talk to it, found it working, but at least DM commands 12 and 64 are not implemented on my device (Gobi 2000 built into Thinkpad x100e). * Functionality of the 3G Modem port remains unchanged. * The GPS port and how to enable it has been confirmed now in the Gobi 3000 source code at: https://www.codeaurora.org/patches/quic/gobi/ Enable/disable GPS via: echo "\$GPS_START" > /dev/ttyUSB2 # use GPS echo "\$GPS_STOP" > /dev/ttyUSB2 Signed-off-by: Matthias G. Eckermann <mge@arcor.de>
* USB: cdc.h: ncm: fix one more typoYauheni Kaliuta2010-10-221-2/+2
| | | | | | | | | | | In usb_cdc_ncm_dpe32 the fields are 32 bit long and according to usb style (hungarian notation) should be called dwDatagramIndex and dwDatagramLength (see CDC NCM subclass spec, 3.3.2). Actually, they were called wDatagramIndex, wDatagramLength. Signed-off-by: Yauheni Kaliuta <yauheni.kaliuta@nokia.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: ftdi_sio: revert "USB: ftdi_sio: fix DTR/RTS line modes"Johan Hovold2010-10-221-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 6a1a82df91fa0eb1cc76069a9efe5714d087eccd. RTS and DTR should not be modified based on CRTSCTS when calling set_termios. Modem control lines are raised at port open by the tty layer and should stay raised regardless of whether hardware flow control is enabled or not. This is in conformance with the way serial ports work today and many applications depend on this behaviour to be able to talk to hardware implementing hardware flow control (without the applications actually using it). Hardware which expects different behaviour on these lines can always use TIOCMSET/TIOCMBI[SC] after port open to change them. Reported-by: Daniel Mack <daniel@caiaq.de> Reported-by: Dave Mielke <dave@mielke.cc> Signed-off-by: Johan Hovold <jhovold@gmail.com> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: serial: Enable USB autosuspend by default on qcserialMatthew Garrett2010-10-221-0/+2
| | | | | | | | Seems to work fine in my testing. Signed-off-by: Matthew Garrett <mjg@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: atmel_usba_udc: force vbus_pin at -EINVAL when gpio_request failledJean-Christophe PLAGNIOL-VILLARD2010-10-221-0/+3
| | | | | | | | | | to ensure gpio_is_valid return false Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: cdc.h: ncm: add missed constants and structuresYauheni Kaliuta2010-10-221-2/+55
| | | | | | | | | | | | Make a dedicated structure for datagram pointer entry. There is no explicit declaration in the spec, but it's used by the host implementation and makes the structure more clear. Add some missed constants from the spec Signed-off-by: Yauheni Kaliuta <yauheni.kaliuta@nokia.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* Revert "USB: ncm: added ncm.h with auxiliary definitions"Yauheni Kaliuta2010-10-221-114/+0
| | | | | | | | | | | This reverts commit 65e0b499105ec8ff3bc4ab7680873dec20127f9d. Since the host and gadget implementations are different, there is no common code for the file, remove for now. Signed-off-by: Yauheni Kaliuta <yauheni.kaliuta@nokia.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: cdc.h: ncm: typo and style fixesYauheni Kaliuta2010-10-221-10/+12
| | | | | | | | | | | | | | Some typos were in the initial commit, make the spelling according to the spec. Add some more comments. Also change constant names according to the style of the rest of the file Signed-off-by: Yauheni Kaliuta <yauheni.kaliuta@nokia.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: option: Add new ONDA vendor id and product id for ONDA MT825UPEnrico Mioso2010-10-221-0/+7
| | | | | | | | | | | | | | | | | | | | | This patch, adds to the option driver the Onda Communication (http://www.ondacommunication.com) vendor id, and the MT825UP modem device id. Note that many variants of this same device are being release here in Italy (at least one or two per telephony operator). These devices are perfectly equivalent except for some predefined settings (which can be changed of course). It should be noted that most ONDA devices are allready supported (they used other vendor's ids in the past). The patch seems working fine here, and the rest of the driver seems uninfluenced. Signed-off-by: Enrico Mioso <mrkiko.rs@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: cp210x: Add Renesas RX-Stick device IDDJ Delorie2010-10-221-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | RX610 development board by Renesas Bus 001 Device 024: ID 045b:0053 Hitachi, Ltd Device Descriptor: bLength 18 bDescriptorType 1 bcdUSB 1.10 bDeviceClass 0 (Defined at Interface level) bDeviceSubClass 0 bDeviceProtocol 0 bMaxPacketSize0 64 idVendor 0x045b Hitachi, Ltd idProduct 0x0053 bcdDevice 1.00 iManufacturer 1 Silicon Labs iProduct 2 RX-Stick iSerial 3 0001 . . . http://am.renesas.com/rx610stick Signed-off-by: DJ Delorie <dj@delorie.com> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* usb: omap: ohci: Missing driver unregister in module exitKeshava Munegowda2010-10-221-0/+3
| | | | | | | | | | | | The un-registration of OHCI driver was not done in the ohci_hcd_mod_exit function. This was affecting rmmod command not to work for OMAP3 platforms. The platform driver un-registration for OMAP3 platforms is perfomed while removing the OHCI module from kernel. Signed-off-by: Keshava Munegowda <keshava_mgowda@ti.com> Signed-of-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: ftdi_sio: Add PID for accesio productsRich Mattes2010-10-222-0/+7
| | | | | | | | | | Adds support for Accesio USB to Serial adapters, which are built around FTDI FT232 UARTs. Tested with the Accesio USB-COM-4SM. Signed-off-by: Rich Mattes <richmattes@gmail.com> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* usb: host: oxu210hp-hcd: Use static const char * const where possibleJoe Perches2010-10-221-1/+1
| | | | | | Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: teach "devices" file about Wireless and SuperSpeed USBAlan Stern2010-10-222-16/+29
| | | | | | | | | | | | The /sys/kernel/debug/usb/devices file doesn't know about Wireless or SuperSpeed USB. This patch (as1416b) teaches it, and updates the Documentation/usb/proc_sub_info.txt file accordingly. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> CC: David Vrabel <david.vrabel@csr.com> CC: Sarah Sharp <sarah.a.sharp@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* uwb: use '%pM' format to print MAC addressAndy Shevchenko2010-10-222-9/+3
| | | | | | | Signed-off-by: Andy Shevchenko <andy.shevchenko@gmail.com> Cc: David Vrabel <david.vrabel@csr.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: option: Add more ZTE modem USB id'sMauro Carvalho Chehab2010-10-221-3/+20
| | | | | | | | | | | | | | | | | | | | There are lots of ZTE USB id's currently not covered by usb/serial. Adds them, to allow those devices to work properly on Linux. While here, put the USB ID's for 0x2002/0x2003 at the sorted order. This patch is based on zte.c file found on MF645. PS.: The ZTE driver is commenting the USB ID for 0x0053. It also adds, commented, an USB ID for 0x0026. Not sure why, but I think that 0053 is used by their devices in storage mode only. So, I opted to keep the comment on this patch. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: gadget: Remove pr_<level> uses of KERN_<level>Joe Perches2010-10-221-1/+1
| | | | | | Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: isp1362-hcd: Removes CONFIG_USB_OTG dependent code, fix build breakageJavier Martinez Canillas2010-10-221-7/+0
| | | | | | | | | | | | | | | | | | | | | | In today linux-next I got a compile error on usb/host/isp1362-hcd: drivers/usb/host/isp1362-hcd.c: In function ‘isp1362_hub_control’: drivers/usb/host/isp1362-hcd.c:1680: error: ‘ohci’ undeclared (first use in this function) The problem is when the CONFIG_USB_OTG option is enabled. ohci variable is never declared and there isn't any CONFIG_USB_OTG dependent code besides the portion defined in isp1362_hub_control. So I think that maybe USB OTG support is not needed/supported. This patch removes the CONFIG_USB_OTG dependent block so the driver can compile cleanly. Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com> Cc: Mike Frysinger <vapier@gentoo.org> Cc: Lothar Wassmann <LW@KARO-electronics.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* usb gadget: composite: prevent OOPS for non-standard control requestRoger Quadros2010-10-221-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The composite gadget will OOPS if the host sends a control request targetted to an interface of an un-configured composite device. This patch prevents this. The OOPS was observed during WHQL USB CV tests. With this patch, the device STALLs as per requirement. Failing test case: From host do the following. I used libusb-1.0 1) Set configuration to zero. libusb_control_transfer(device_handle, 0, /* standard OUT */ 0x9, /* setConfiguration */ 0, 0, NULL, 0, 0); 2) Query current configuratioan. libusb_control_transfer(device_handle, 0x80, /* standard IN*/ 0x8, /* getConfiguration */ 0, 0, data, 1, 0); 3) Send the non-standard ctrl transfer targetted to interface libusb_control_transfer(device_handle, 0x81, /* standard IN to interface*/ 0x6, /* getDescriptor */ 0x2300, 0, data, 0x12, 0); Signed-off-by: Roger Quadros <roger.quadros@nokia.com> Cc: stable <stable@kernel.org> Cc: David Brownell <dbrownell@users.sourceforge.net> Cc: Michal Nazarewicz <m.nazarewicz@samsung.com> Cc: Robert Lukassen <robert.lukassen@tomtom.com> Cc: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* OHCI: work around for nVidia shutdown problemAlan Stern2010-10-225-9/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch (as1417) fixes a problem affecting some (or all) nVidia chipsets. When the computer is shut down, the OHCI controllers continue to power the USB buses and evidently they drive a Reset signal out all their ports. This prevents attached devices from going to low power. Mouse LEDs stay on, for example, which is disconcerting for users and a drain on laptop batteries. The fix involves leaving each OHCI controller in the OPERATIONAL state during system shutdown rather than putting it in the RESET state. Although this nominally means the controller is running, in fact it's not doing very much since all the schedules are all disabled. However there is ongoing DMA to the Host Controller Communications Area, so the patch also disables the bus-master capability of all PCI USB controllers after the shutdown routine runs. The fix is applied only to nVidia-based PCI OHCI controllers, so it shouldn't cause problems on systems using other hardware. As an added safety measure, in case the kernel encounters one of these running controllers during boot, the patch changes quirk_usb_handoff_ohci() (which runs early on during PCI discovery) to reset the controller before anything bad can happen. Reported-by: Pali Rohár <pali.rohar@gmail.com> Signed-off-by: Alan Stern <stern@rowland.harvard.edu> CC: David Brownell <david-b@pacbell.net> Tested-by: Pali Rohár <pali.rohar@gmail.com> CC: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: ohci-sm501: add iounmap on error pathDan Carpenter2010-10-221-1/+3
| | | | | | | | This ioremap() was leaked on an error path. Signed-off-by: Dan Carpenter <error27@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: Change acm_iad_descriptor bFunctionProtocol to USB_CDC_ACM_PROTO_AT_V25TERPraveena Nadahally2010-10-221-1/+1
| | | | | | | | | | | | | | | The protocol code is set 00 in IAD and it's set to 01 in ACM control interface descriptor in f_acm.c file. Due to this, windows is unable to install the modem(ACM) driver based on class-subclass-protocol matching. This patch corrects the protocol code in ACM IAD to the same as in acm_control_interface_desc protocol code. Acked-by: Linus Walleij <linus.walleij@stericsson.com> Signed-off-by: Praveena Nadahally <praveen.nadahally@stericsson.com> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: r8a66597-udc: Initialize uninitialized variable, fix compile warningJavier Martinez Canillas2010-10-221-1/+1
| | | | | | | | | | | | | | | In today linux-next I got a compile warning due a possible uninitialized variable This patch solves the issue initializing the variable Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com> Cc: David Brownell <dbrownell@users.sourceforge.net> Cc: Paul Mundt <lethal@linux-sh.org> Cc: Magnus Damm <damm@opensource.se> Cc: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB OTG Langwell: Update OTG Kconfig and driver version.Hao Wu2010-10-223-4/+4
| | | | | | | | | | | This patch updated Kconfig for langwell otg transceiver driver. Add ipc driver(INTEL_SCU_IPC) as a dependency. Driver version is updated too. Signed-off-by: Hao Wu <hao.wu@intel.com> Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB OTG: Add common data structure for Intel MID Platform (Langwell/Penwell)Hao Wu2010-10-221-0/+180
| | | | | | | | | | | | | This patch adds one new header file for the common data structure used in Intel Penwell/Langwell MID Platform OTG Transceiver drivers. After switched to the common data structure, Langwell/Penwell OTG Transceiver driver will provide an unified interface to host/client driver. Reported-by: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Hao Wu <hao.wu@intel.com> Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* usb: ftdi-elan: Convert "mutex" to semaphoreThomas Gleixner2010-10-221-1/+1
| | | | | | | | | The "mutex" ftdi->sw_lock is used as a lock and a completion. Convert it to a real semaphore which allows both. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: gadget: rndis: fix up coding style issues in the fileMihai Donțu2010-10-221-248/+244
| | | | | | | | | Corrected the coding style. Signed-off-by: Mihai Dontu <mihai.dontu@gmail.com> Cc: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: ehci tdi : let's tdi_reset set host modeMatthieu CASTET2010-10-224-15/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | tdi_reset is already taking care of setting host mode for tdi devices. Don't duplicate code in platform driver. Make ehci_halt a nop if the controller is not in host mode (otherwise it will fail), and let's ehci_reset do the tdi_reset. We need to move hcd->has_tt flags before ehci_halt, in order ehci_halt knows we are a tdi device. Before the setup routine was doing : - put controller in host mode - ehci_halt - ehci_init - hcd->has_tt = 1; - ehci_reset Now we do : - hcd->has_tt = 1; - ehci_halt - ehci_init - ehci_reset PS : now we handle correctly the device -> host transition. Signed-off-by: Matthieu CASTET <matthieu.castet@parrot.com> Cc: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: Kconfig: fix typos in USB_FUNCTIONFS* descriptionMichael Prokop2010-10-221-5/+5
| | | | | | | | | | | | It's spelled "Function Filesystem" / "FunctionFS". This patch fixes some typos (FunctioFS->FunctionFS, Funcion->Function, funcion->function, redundant "as") in the Kconfig description of USB_FUNCTIONFS*. Signed-off-by: Michael Prokop <mika@grml.org> Acked-by: Michal Nazarewicz <m.nazarewicz@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: g_file_storage: don't generate automatic serial stringAlan Stern2010-10-222-36/+15
| | | | | | | | | | | | | This patch (as1413) changes g_file_storage to avoid generating a bogus automatic serial-number string descriptor. If the user doesn't provide a valid serial number via a module parameter then a warning is logged and the gadget won't have any serial string descriptor at all. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Acked-by: David Brownell <david-b@pacbell.net> CC: Michal Nazarewicz <m.nazarewicz@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: langwell: Remove unnecessary return's from void functionsJoe Perches2010-10-221-5/+0
| | | | | | | | | | | | | There are about 2500 void functions in drivers/usb Only a few used return; at end of function. Standardize them a bit. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> Cc: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: output an error message when the pipe type doesn't match the endpoint typeSimon Arlott2010-10-221-1/+4
| | | | | | | | | | | Commit f661c6f8c67bd55e93348f160d590ff9edf08904 adds a check of the pipe type if CONFIG_USB_DEBUG is enabled, but it doesn't output anything if this scenario occurs. Signed-off-by: Simon Arlott <simon@fire.lp0.eu> Cc: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: gadget: amd5536udc.c: Remove double testJulia Lawall2010-10-221-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | The same expression is tested twice and the result is the same each time. Instead test for use_dma_ppb as in the test above. The sematic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // <smpl> @expression@ expression E; @@ ( * E || ... || E | * E && ... && E ) // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* init.h: add some more documentation to __ref* tagsMichal Nazarewicz2010-10-221-3/+10
| | | | | | | | | | | | | The __ref* tags may have been confusing for new kernel developers (I was confused by them for sure) so adding a few more sentences to comment to clear things up for people who see those for the first time. Signed-off-by: Michal Nazarewicz <m.nazarewicz@samsung.com> Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Acked-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* usb gadget: don't save bind callback in struct usb_configurationUwe Kleine-König2010-10-2214-43/+33
| | | | | | | | | | | | | The bind function is most of the time only called at init time so there is no need to save a pointer to it in the configuration structure. This fixes many section mismatches reported by modpost. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> [m.nazarewicz@samsung.com: updated for -next] Signed-off-by: Michał Nazarewicz <m.nazarewicz@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* usb gadget: don't save bind callback in struct usb_composite_driverMichal Nazarewicz2010-10-2213-40/+27
| | | | | | | | | | | The bind function is most of the time only called at init time so there is no need to save a pointer to it in the composite driver structure. This fixes many section mismatches reported by modpost. Signed-off-by: Michał Nazarewicz <m.nazarewicz@samsung.com> Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* usb gadget: don't save bind callback in struct usb_gadget_driverUwe Kleine-König2010-10-2227-125/+128
| | | | | | | | | | | | | | | | | | | | | | To accomplish this the function to register a gadget driver takes the bind function as a second argument. To make things clearer rename the function to resemble platform_driver_probe. This fixes many section mismatches like WARNING: drivers/usb/gadget/g_printer.o(.data+0xc): Section mismatch in reference from the variable printer_driver to the function .init.text:printer_bind() The variable printer_driver references the function __init printer_bind() All callers are fixed. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> [m.nazarewicz@samsung.com: added dbgp] Signed-off-by: Michał Nazarewicz <m.nazarewicz@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: Revert "USB: gadget: section mismatch warning fixed"Michal Nazarewicz2010-10-2213-22/+22
| | | | | | | | | | | | | This reverts a commit which proposed an invalid solution for a section mismatch. Next 3 commits will fix it correctly. Conflicts: drivers/usb/gadget/mass_storage.c Signed-off-by: Michal Nazarewicz <m.nazarewicz@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
OpenPOWER on IntegriCloud