summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2012-02-28usb/storage: redefine US_BULK_FLAG_IN and use itSebastian Andrzej Siewior
US_BULK_FLAG_IN is defined as 1 and not used. The USB storage spec says that bit 7 of flags within CBW defines the data direction. 1 is DATA-IN (read from device) and 0 is the DATA-OUT. Bit 6 is obselete and bits 0-5 are reserved. This patch redefines the unsued define US_BULK_FLAG_IN from 1 to 1 << 7 aka 0x80 and replaces the obvious users. In a following patch the storage gadget will use it as well. Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28usb/storage: a couple defines from drivers/usb/storage/transport.h to ↵Sebastian Andrzej Siewior
include/linux/usb/storage.h This moves the BOT data structures for CBW and CSW from drivers internal header file to global include able file in include/. The storage gadget is using the same name for CSW but a different for CBW so I fix it up properly. The same goes for the ub driver and keucr driver in staging. Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28USB: option: Add MediaTek MT6276M modem&app interfacesMeng Zhang
Add MEDIATEK products to Option driver Signed-off-by: Meng Zhang <meng.zhang@mediatek.com> Signed-off-by: Matthias Urlichs <matthias@urlichs.de> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28powerpc/usb: fix usb CTRL_PHY_CLK_VALID breaks on some platformShengzhou Liu
Fix checking of CTRL_PHY_CLK_VALID bit break on some platform on which there is not USB CTRL_PHY_CLK_VALID bit. - P1023/P3041/P5020 etc,have this bit - P3060/4080/PSC913x do have this bit, but not mentioned in RM. - P1022(perhaps and other) has no this bit Signed-off-by: Shengzhou Liu <Shengzhou.Liu@freescale.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28usb: fix defined but not used warnings in hcd-pci.cPaul Gortmaker
Shows up on ia64 builds (and possibly elsewhere) for configs that don't set PM_RUNTIME or PM_SLEEP as follows: drivers/usb/core/hcd-pci.c:383:12: warning: 'suspend_common' defined but not used drivers/usb/core/hcd-pci.c:438:12: warning: 'resume_common' defined but not used As per above, the functions are only used if RUNTIME/SLEEP are set, so make the two functions conditional on these Kconfig values. Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Acked-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28USB: ftdi_sio: fix problem when the manufacture is a NULL stringGreg Kroah-Hartman
On some misconfigured ftdi_sio devices, if the manufacturer string is NULL, the kernel will oops when the device is plugged in. This patch fixes the problem. Reported-by: Wojciech M Zabolotny <W.Zabolotny@elka.pw.edu.pl> Tested-by: Wojciech M Zabolotny <W.Zabolotny@elka.pw.edu.pl> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28usb: gadget: goku: use generic map/unmap routinesFelipe Balbi
those routines have everything we need to map/unmap USB requests and it's better to use them. Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-28usb: gadget: net2280: use generic map/unmap routinesFelipe Balbi
those routines have everything we need to map/unmap USB requests and it's better to use them. Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-28usb: gadget: net2272: use generic map/umap routinesFelipe Balbi
those routines have everything we need to map/unmap USB requests and it's better to use them. Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-28usb: gadget: r8a66597: use generic map/unmap routinesFelipe Balbi
those routines have everything we need to map/unmap USB requests and it's better to use them. Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-28usb: gadget: amd5536: use generic map/unmap routinesFelipe Balbi
those routines have everything we need to map/unmap USB requests and it's better to use them. Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-28usb: renesas: gadget: use generic map/unmap routinesFelipe Balbi
those routines have everything we need to map/unmap USB requests and it's better to use them. Tested-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-28usb: gadget: langwell: use generic map/unmap functionsFelipe Balbi
those routines have everything we need to map/unmap USB requests and it's better to use them. Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-28usb: dwc3: gadget: use generic map/unmap routinesFelipe Balbi
those routines have everything we need to map/unmap USB requests and it's better to use them. In order to achieve that, we had to add a simple change on how we allocate and use our setup buffer; we cannot allocate it from coherent anymore otherwise the generic map/unmap routines won't be able to easily know that the GetStatus request already has a DMA address. Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-28usb: gadget: add generic map/unmap request utilitiesFelipe Balbi
such utilities are currently duplicated on all UDC drivers basically with the same structure. Let's group all implementations into one generic implementation and get rid of that duplication. Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-27usb: amd5536udc: Remove old CVS markersCyril Roelandt
Git does not care about CVS markers. Signed-off-by: Cyril Roelandt <tipecaml@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-27usb: amd5536udc: Fix the type of ep_stringCyril Roelandt
Use "static const char *const" instead of "static const char *". Signed-off-by: Cyril Roelandt <tipecaml@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-27usb: amd5536udc: use the DEFINE_PCI_DEVICE_TABLE macroCyril Roelandt
Use DEFINE_PCI_DEVICE_TABLE instead of "const struct pci_device_id". Signed-off-by: Cyril Roelandt <tipecaml@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-27usb: amd5536udc: Fix indentationCyril Roelandt
Remove an unnecessary level of indentation. Signed-off-by: Cyril Roelandt <tipecaml@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-27usb: amd5536udc: Fix coding style issues.Cyril Roelandt
Remove unnecessary whitespaces. Signed-off-by: Cyril Roelandt <tipecaml@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-27usb: amd5536udc: Fix brace coding style issues.Cyril Roelandt
Remove a bunch of unneeded braces. Signed-off-by: Cyril Roelandt <tipecaml@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-27usb: otg: Convert all users to pass struct usb_otg for OTG functionsHeikki Krogerus
This changes the otg functions so that they receive struct otg instead of struct usb_phy as parameter and converts all users of these functions to pass the otg member of their usb_phy. Includes fixes to IMX code from Sascha Hauer. [ balbi@ti.com : fixed a compile warning on ehci-mv.c ] Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Acked-by: Sascha Hauer <s.hauer@pengutronix.de> Acked-by: Igor Grinberg <grinberg@compulab.co.il> Acked-by: Pavankumar Kondeti <pkondeti@codeaurora.org> Acked-by: Li Yang <leoli@freescale.com> Acked-by: Alan Stern <stern@rowland.harvard.edu> Reviewed-by: Marek Vasut <marek.vasut@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-27usb: otg: Remove OTG specific members from usb_phyHeikki Krogerus
All the drivers are now converted to use struct usb_otg, so removing the OTG specific members from struct usb_phy. Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Reviewed-by: Marek Vasut <marek.vasut@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-27usb: Convert all users to new usb_phyHeikki Krogerus
Use the new usb_phy_* functions with transceiver operations instead of the old otg functions. Includes fixes from Sascha Hauer. Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Acked-by: Sascha Hauer <s.hauer@pengutronix.de> Acked-by: Pavankumar Kondeti <pkondeti@codeaurora.org> Acked-by: Li Yang <leoli@freescale.com> Acked-by: Alan Stern <stern@rowland.harvard.edu> Reviewed-by: Marek Vasut <marek.vasut@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-27usb: otg: mv_otg: Start using struct usb_otgHeikki Krogerus
Use struct usb_otg members with OTG specific functions instead of usb_phy members. [ balbi@ti.com : fixed a compile error on isp1704_charger.c ] Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Reviewed-by: Marek Vasut <marek.vasut@gmail.com> Acked-by: Neil Zhang <zhangwm@marvell.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2012-02-25usb-serial: Add support for the Sealevel SeaLINK+8 2038-ROHS deviceScott Dial
This patch adds new device IDs to the ftdi_sio module to support the new Sealevel SeaLINK+8 2038-ROHS device. Signed-off-by: Scott Dial <scott.dial@scientiallc.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24usb: host: add dependence for USB_EHCI_MVNeil Zhang
This ehci driver is mainly designed to support host controller found on Marvell PXA and MMP Soc series. Add the dependence to avoid the potential build failure which may include two EHCI controller drivers. Signed-off-by: Neil Zhang <zhangwm@marvell.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24USB: ohci-exynos: replace hcd->state with ohci->rh_stateJingoo Han
This patch removes uses of hcd->state and replaces hcd->state with ohci->rh_state field. Signed-off-by: Jingoo Han <jg1.han@samsung.com> Acked-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24USB: ehci-spear: Add PM supportDeepak Sikri
This patch adds support for standby/S2R/hibernate for ehci-spear driver. Signed-off-by: Deepak Sikri <deepak.sikri@st.com> Signed-off-by: Pratyush Anand <pratyush.anand@st.com> Signed-off-by: Viresh Kumar <viresh.kumar@st.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24USB: ums_realtek: do not use stack memory for DMA in __do_config_autodelinkjwboyer@redhat.com
__do_config_autodelink passes the data variable to the transport function. If the calling functions pass a stack variable, this will eventually trigger a DMA-API debug backtrace for mapping stack memory in the DMA buffer. Fix this by calling kmemdup for the passed data instead. Signed-off-by: Josh Boyer <jwboyer@redhat.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24powerpc/usb: fix bug of kernel hang when initializing usbShengzhou Liu
If USB UTMI PHY is not enable, writing to portsc register will lead to kernel hang during boot up. Signed-off-by: Shengzhou Liu <Shengzhou.Liu@freescale.com> Reported-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24usb: Fix build error due to dma_mask is not at pdev_archdata at ARMPeter Chen
When build i.mx platform with imx_v6_v7_defconfig, and after adding USB Gadget support, it has below build error: CC drivers/usb/host/fsl-mph-dr-of.o drivers/usb/host/fsl-mph-dr-of.c: In function 'fsl_usb2_device_register': drivers/usb/host/fsl-mph-dr-of.c:97: error: 'struct pdev_archdata' has no member named 'dma_mask' It has discussed at: http://www.spinics.net/lists/linux-usb/msg57302.html For PowerPC, there is dma_mask at struct pdev_archdata, but there is no dma_mask at struct pdev_archdata for ARM. The pdev_archdata is related to specific platform, it should NOT be accessed by cross platform drivers, like USB. The code for pdev_archdata should be useless, as for PowerPC, it has already gotten the value for pdev->dev.dma_mask at function arch_setup_pdev_archdata of arch/powerpc/kernel/setup-common.c. Tested-by: Ramneek Mehresh <ramneek.mehresh@freescale.com> Signed-off-by: Peter Chen <peter.chen@freescale.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24usb: Fix typo in ehci-dbg.cMasanari Iida
Correct spelling "peridic" to "periodic" in drivers/usb/host/ehci-dbg.c Signed-off-by: Masanari Iida <standby24x7@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24usb: isp1362-hcd: Convert to module_platform_driverTobias Klauser
Move the usb_disabled() check to the probe function and get rid of the rather pointless message on module load. Signed-off-by: Tobias Klauser <tklauser@distanz.ch> Acked-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24USB: allow users to run setserial with cdc-acmOliver Neukum
We had a user report that running setserial on /dev/ttyACM0 didn't work. He pointed at an old patch by Oliver Neukum from 2008 that never went anywhere.. http://permalink.gmane.org/gmane.linux.usb.general/9236 I made some minor changes to get it to apply again, and got the user to retest on 3.1, and he reported it worked for him. https://bugzilla.redhat.com/show_bug.cgi?id=787607 The diff below is against 3.3rc. The only difference between this and the version the user tested is the removal of the if (!ACM_READY) test Havard removed ACM_READY in 99823f457d5994b3bd3775515578c8bfacc64b04 I'm unclear if there's need for a different test in its place. From: Oliver Neukum <oliver@neukum.org> Signed-off-by: Dave Jones <davej@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24USB: ehci-fsl: Turn on cache snooping on MPC8xxxPan Jiafei
If a MPC8xxx was being used, 'have_sysif_regs' should be set and it should setup cache snooping for all the 4GB space on both PPC32 and PPC64. Signed-off-by: Pan Jiafei <Jiafei.Pan@freescale.com> Acked-by: Li Yang <leoli@freescale.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24cdc-wdm: Don't clear WDM_READ unless entire read buffer is emptiedBen Hutchings
The WDM_READ flag is cleared later iff desc->length is reduced to 0. Signed-off-by: Ben Hutchings <ben@decadent.org.uk> Tested-by: Bjørn Mork <bjorn@mork.no> Cc: Oliver Neukum <oliver@neukum.org> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24usb: host: remove ehci-pxa168.cNeil Zhang
Since ehci-mv.c can cover Marvell PXA and MMP series including PXA168, so this driver seems redundant now. Signed-off-by: Neil Zhang <zhangwm@marvell.com> Cc: <tanmay.upadhyay@einfochips.com> Acked-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24cdc-wdm: Fix more races on the read pathBen Hutchings
We must not allow the input buffer length to change while we're shuffling the buffer contents. We also mustn't clear the WDM_READ flag after more data might have arrived. Therefore move both of these into the spinlocked region at the bottom of wdm_read(). When reading desc->length without holding the iuspin lock, use ACCESS_ONCE() to ensure the compiler doesn't re-read it with inconsistent results. Signed-off-by: Ben Hutchings <ben@decadent.org.uk> Tested-by: Bjørn Mork <bjorn@mork.no> Cc: Oliver Neukum <oliver@neukum.org> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24USB: qcserial: don't grab QMI port on Gobi 1000 devicesDan Williams
Gobi 1000 devices have a different port layout, which wasn't respected by the current driver, and thus it grabbed the QMI/net port. In the near future we'll be attaching another driver to the QMI/net port for these devices (cdc-wdm and qmi_wwan) so make sure the qcserial driver doesn't claim them. This patch also prevents qcserial from binding to interfaces 0 and 1 on 1K devices because those interfaces do not respond. Signed-off-by: Dan Williams <dcbw@redhat.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24USB: serial: remove usb_serial_register and usb_serial_deregisterGreg Kroah-Hartman
No one uses them anymore, they should be using the safer usb_serial_register_drivers() and usb_serial_deregister_drivers() functions instead. Thanks to Alan Stern for writing these functions and porting all in-kernel users to them. Cc: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24usb-serial: use new registration API in keyspan_pda.cGreg Kroah-Hartman
This was missed in Alan's last round of conversions. Cc: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24usb-serial: use new registration API in staging driversAlan Stern
This patch (as1530) modifies the following usb-serial drivers from drivers/staging to utilize the new usb_serial_{de}register_drivers() routines: quatech_usb2 and serqt_usb2. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24usb-serial: use new registration API in [t-z]* driversAlan Stern
This patch (as1529) modifies the following usb-serial drivers to utilize the new usb_serial_{de}register_drivers() routines: ti_usb_3410_5052, usb_debug, visor, vivopay-serial, whiteheat, and zio. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24usb-serial: use new registration API in [q-s]* driversAlan Stern
This patch (as1528) modifies the following usb-serial drivers to utilize the new usb_serial_{de}register_drivers() routines: qcaux, qcserial, safe_serial, siemens_mpi, sierra, spcp8x5, ssu100, and symbolserial. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24usb-serial: use new registration API in [n-p]* driversAlan Stern
This patch (as1527) modifies the following usb-serial drivers to utilize the new usb_serial_{de}register_drivers() routines: navman, omninet, opticon, option, oti6858, and pl2303. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24usb-serial: use new registration API in [k-m]* driversAlan Stern
This patch (as1526) modifies the following usb-serial drivers to utilize the new usb_serial_{de}register_drivers() routines: keyspan, kl5kusb105, kobil_sct, mct_u232, mos7720, mos7840, and moto_modem. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24usb-serial: use new registration API in [i-j]* driversAlan Stern
This patch (as1525) modifies the following usb-serial drivers to utilize the new usb_serial_{de}register_drivers() routines: io_edgeport, io_ti, ipaq, ipw, ir-usb, and iuu_phoenix. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24usb-serial: use new registration API in [d-h]* driversAlan Stern
This patch (as1524) modifies the following usb-serial drivers to utilize the new usb_serial_{de}register_drivers() routines: digi_acceleport, empeg, ftdi_sio, funsoft, garmin_gps, and hp4x. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24usb-serial: use new registration API in [a-c]* driversAlan Stern
This patch (as1523) modifies the following usb-serial drivers to utilize the new usb_serial_{de}register_drivers() routines: aircable, ark3116, belkin_sa, ch341, cp210x, cyberjack, and cypress_m8. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>