aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb (follow)
AgeCommit message (Collapse)AuthorFilesLines
2015-08-08usb: core: hub.c: Removed some warnings generated by checkpatch.plChase Metzger1-20/+20
Removed some checkpatch.pl warnings saying there was an unwanted space between function names and their arguments. Signed-off-by: Chase Metzger <chasemetzger15@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-08usb: devio: fix spacingKris Borer1-2/+2
Fix two occurrences of the checkpatch.pl error: ERROR: space prohibited before that ',' (ctx:WxW) Fix one occurrence of the checkpatch error: ERROR: space required before the open parenthesis '(' Signed-off-by: Kris Borer <kborer@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-08xhci: xHCI 1.1: Stopped - Short Packet Capability (SPC)Lu Baolu3-5/+47
This patch enables xhci driver to support SPC by handling Stopped - Short Packet event in transfer event path. If SPC = '1' and the stop endpoint command is executed, after a Short Packet condition has been detected, but before the end of the TD has been reached, (i.e. the TD is in progress for pipe), then a Transfer Event TRB with its Completion Code set to Stopped - Short Packet and its TRB Transfer Length set to value of the EDTLA shall be forced for the interrupted TRB, irrespective of whether its IOC or ISP flags are set. This Transfer Event TRB will precede the Command Completion Event TRB for the command, and is referred to as a Stopped Transfer Event. Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-08xhci: xHCI 1.1: Contiguous Frame ID Capability (CFC)Lu Baolu3-13/+187
If the Contiguous Frame ID Capability is supported (CFC = 1), then the xHC shall match the Frame ID in every Isoch TD with SIA = 0 against the Frame Index of the MFINDEX register. This rule ensures resynchronization of Isoch TDs even if some are dropped due to Missed Service Errors or Stopping the endpoint. This patch enables xHCI driver to support CFC by calculating and setting the Frame ID field of an Isoch TRB. [made some dbg messages checkpatch friendly -Mathias] Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-08usb: xhci: Add support for URB_ZERO_PACKET to bulk/sg transfersReyad Attiyat2-14/+57
This commit checks for the URB_ZERO_PACKET flag and creates an extra zero-length td if the urb transfer length is a multiple of the endpoint's max packet length. Signed-off-by: Reyad Attiyat <reyad.attiyat@gmail.com> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-08usb: xhci: make USB_XHCI_PLATFORM selectableRafał Miłecki1-1/+8
Right now xhci-plat-hcd can be built when using one of platform specific drivers only (mvebu/rcar). There shouldn't be such limitation as some platforms may not require any quirks and may want to just use a generic driver ("generic-xhci" / "xhci-hcd"). Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-07usb: musb: gadget: fix build break by adding missing 'break'Robert Baldyga1-0/+1
Add missing break after 'default' label to fix compilation error. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-07treewide: fix typos in comment blocksMasahiro Yamada1-1/+1
Looks like the word "contiguous" is often mistyped. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Jiri Kosina <jkosina@suse.com>
2015-08-07drivers/usb/gadget/composite.c: i18n is not an acronymDiego Viola1-2/+2
Signed-off-by: Diego Viola <diego.viola@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.com>
2015-08-07treewide: Fix typo in printkMasanari Iida1-1/+1
This patch fix spelling typo inv various part of sources. Signed-off-by: Masanari Iida <standby24x7@gmail.com> Acked-by: Randy Dunlap <rdunlap@infradead.org> Signed-off-by: Jiri Kosina <jkosina@suse.com>
2015-08-06usb: gadget: legacy: nokia: add CONFIG_BLOCK dependencyFelipe Balbi1-0/+1
g_nokia now has mass_storage function, so it should depend on CONFIG_BLOCK. Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-06usb: gadget: f_mass_storage: add mising <linux/uaccess.h>Felipe Balbi1-0/+1
<linux/uaccess.h> was originally being pulled indirectly through some other header, however it's not anymore, so we need to include it directly Reported-by: Jim Davis <jim.epost@gmail.com> Suggested-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-06usb: musb: cppi41: allow it to work againFelipe Balbi1-3/+3
since commit 33c300cb90a6 ("usb: musb: dsps: don't fake of_node to musb core") we have been preventing CPPI 4.1 from probing due to NULL of_node. We can't revert said commit otherwise a different regression would show up, so the fix is to look for the parent device's (glue layer's) of_node instead, since that's the thing which is actually described in DTS. Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-06usb: musb: gadget: remove remaining DMA ifdeferryFelipe Balbi1-21/+18
Commit fb91cddc54e7 ("usb: musb: Remove DMA ifdef for musb_gadget.c short_packet") tried to remove DMA ifdeferry from musb_gadget.c but ended up leaving some around. Remove them so that when building kernels with all DMA engines enabled, we don't end up trying to allocte channels twice. Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-06usb: gadget: remove gadget_chips.hRobert Baldyga15-74/+0
This header file contains helpers for quirks based on UDC controller name. Since we have generic quirk bitfields in usb_gadget structure for all of these quirks we don't need to have this header any longer. This patch removes gadget_chips.h file and makes sure that it's no longer included anywhere in kernel sources. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-06usb: musb: gadget: add musb_match_ep() functionRobert Baldyga2-23/+34
Add 'match_ep' callback to utilize chip-specific knowledge in endpoint matching process. Function does the same that was done by chip-specific code inside of epautoconf. Now this code can be removed from there to separate generic code from platform specific logic. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-06usb: gadget: goku_udc: add goku_match_ep() functionRobert Baldyga2-18/+32
Add 'match_ep' callback to utilize chip-specific knowledge in endpoint matching process. Function does the same that was done by chip-specific code inside of epautoconf. Now this code can be removed from there to separate generic code from platform specific logic. [ balbi@ti.com : fix build breakage ] Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-06usb: gadget: net2280: add net2280_match_ep() functionRobert Baldyga2-22/+29
Add 'match_ep' callback to utilize chip-specific knowledge in endpoint matching process. Function does the same that was done by chip-specific code inside of epautoconf. Now this code can be removed from there to separate generic code from platform specific logic. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-06usb: gadget: move find_ep() from epautoconf to udc-coreRobert Baldyga2-21/+30
Move find_ep() to udc-core and rename it to gadget_find_ep_by_name(). It can be used in UDC drivers, especially in 'match_ep' callback after moving chip-specific endpoint matching logic from epautoconf to UDC drivers. Replace all calls of find_ep() function with gadget_find_ep_by_name(). Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-06usb: gadget: move ep_matches() from epautoconf to udc-coreRobert Baldyga2-84/+80
Move ep_matches() function to udc-core and rename it to usb_gadget_ep_match_desc(). This function can be used by UDC drivers in 'match_ep' callback to avoid writing lots of repetitive code. Replace all calls of ep_matches() with usb_gadget_ep_match_desc(). Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-06usb: gadget: add 'ep_match' callback to usb_gadget_opsRobert Baldyga1-0/+6
Add callback that is called by epautoconf to allow UDC driver match the best endpoint for specific descriptor. It's intended to supply mechanism which allows to get rid of chip-specific endpoint matching code from epautoconf. If gadget has set 'ep_match' callback we prefer to call it first, and if it fails to find matching endpoint, then we try to use default matching algorithm. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-06usb: gadget: epautoconf: rework ep_matches() functionRobert Baldyga1-49/+32
Rework ep_matches() function to make it shorter and more readable. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-05usb: misc: ftdi-elan: Simplify return statementSaurabh Karajgaonkar1-10/+2
Replace redundant variable use in return statement. Signed-off-by: Saurabh Karajgaonkar <skarajga@visteon.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-05usb: serial: mxuport: Simplify return statementSaurabh Karajgaonkar1-7/+3
Replace redundant variable use in return statement. Signed-off-by: Saurabh Karajgaonkar <skarajga@visteon.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-05usb: host: xhci: Simplify return statementSaurabh Karajgaonkar1-5/+1
Replace redundant variable use in return statement. Signed-off-by: Saurabh Karajgaonkar <skarajga@visteon.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-05usb: host: u132-hcd: Simplify return statementSaurabh Karajgaonkar1-26/+9
Replace redundant variable use in return statement. Signed-off-by: Saurabh Karajgaonkar <skarajga@visteon.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-05usb: host: oxu210hp-hcd: Simplify return statementSaurabh Karajgaonkar1-6/+1
Replace redundant variable use in return statement. Signed-off-by: Saurabh Karajgaonkar <skarajga@visteon.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-05usb: host: ehci-st: Simplify return statementSaurabh Karajgaonkar1-6/+1
Replace redundant variable use in return statement. Signed-off-by: Saurabh Karajgaonkar <skarajga@visteon.com> Acked-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-05usb: musb: musb_dsps: Simplify return statementSaurabh Karajgaonkar1-5/+1
Replace redundant variable use in return statement. Signed-off-by: Saurabh Karajgaonkar <skarajga@visteon.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-05usb: phy: phy-keystone: Simplify return statementSaurabh Karajgaonkar1-5/+1
Replace redundant variable use in return statement. Signed-off-by: Saurabh Karajgaonkar <skarajga@visteon.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-05usb: phy: phy-mxs-usb: Simplify return statementSaurabh Karajgaonkar1-5/+1
Replace redundant variable use in return statement. Signed-off-by: Saurabh Karajgaonkar <skarajga@visteon.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-05usb: devio: remove assignment from if conditionKris Borer1-5/+10
Fix five occurrences of the checkpatch.pl error: ERROR: do not use assignment in if condition The semantic patch that makes this change is: // <smpl> @@ identifier i; expression E; statement S1, S2; @@ + i = E; if ( - (i = E) + i ) S1 else S2 @@ identifier i; expression E; statement S; constant c; binary operator b; @@ + i = E; if ( - (i = E) + i b c ) S // </smpl> Signed-off-by: Kris Borer <kborer@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-05usb: ehci-platform: Fix using multiple controllers from OFAlban Bedel1-4/+9
When using OF defined controllers the platform data struct is shared between all devices, so it can't be used for device specific settings. However it is currently used for the OF properties needs-reset-on-resume and has-transaction-translator. To fix this issue move setting hcd->has_tt to the probe and move pdata->reset_on_resume to the private data. Signed-off-by: Alban Bedel <albeu@free.fr> Acked-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-04usb: gadget: epautoconf: remove ep and desc configuration from ep_matches()Robert Baldyga1-32/+34
As function ep_matches() is used to match endpoint with usb descriptor it's highly unintuitive that it modifies endpoint and descriptor structures fields. This patch moves code configuring ep and desc from ep_matches() to usb_ep_autoconfig_ss(), so now function ep_matches() does nothing more than its name suggests. [ balbi@ti.com : fix build warning ] Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-04usb: gadget: epautoconf: remove pxa quirk from ep_matches()Robert Baldyga2-11/+3
The same effect can be achieved by using capabilities flags, so now we can get rid of handling of hardware specific limitations in generic code. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-04usb: gadget: epautoconf: add endpoint capabilities flags verificationRobert Baldyga1-66/+30
Introduce endpoint matching mechanism basing on endpoint capabilities flags. We check if endpoint supports transfer type and direction requested in ep descriptor. Since we have this new endpoint matching mechanism there is no need to have old code guessing endpoint capabilities basing on its name, so we are getting rid of it. Remove also the obsolete comment. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-04usb: gadget: atmel_usba_udc: add ep capabilities supportRobert Baldyga1-0/+11
Convert endpoint configuration to new capabilities model. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-04usb: renesas: gadget: add ep capabilities supportRobert Baldyga1-0/+6
Convert endpoint configuration to new capabilities model. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-04usb: musb: gadget: add ep capabilities supportRobert Baldyga1-0/+12
Convert endpoint configuration to new capabilities model. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-04usb: isp1760: udc: add ep capabilities supportRobert Baldyga1-0/+11
Convert endpoint configuration to new capabilities model. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-04usb: gadget: udc-xilinx: add ep capabilities supportRobert Baldyga1-0/+9
Convert endpoint configuration to new capabilities model. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-04usb: gadget: s3c2410_udc: add ep capabilities supportRobert Baldyga1-0/+10
Convert endpoint configuration to new capabilities model. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-04usb: gadget: s3c-hsudc: add ep capabilities supportRobert Baldyga1-0/+15
Convert endpoint configuration to new capabilities model. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-04usb: gadget: r8a66597-udc: add ep capabilities supportRobert Baldyga1-0/+10
Convert endpoint configuration to new capabilities model. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-04usb: gadget: pxa27x_udc: add ep capabilities supportRobert Baldyga1-15/+25
Convert endpoint configuration to new capabilities model. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-04usb: gadget: pxa25x_udc: add ep capabilities supportRobert Baldyga1-0/+32
Convert endpoint configuration to new capabilities model. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-04usb: gadget: pch_udc: add ep capabilities supportRobert Baldyga1-2/+12
Convert endpoint configuration to new capabilities model. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-04usb: gadget: omap_udc: add ep capabilities supportRobert Baldyga1-0/+22
Convert endpoint configuration to new capabilities model. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-04usb: gadget: net2280: add ep capabilities supportRobert Baldyga1-12/+55
Convert endpoint configuration to new capabilities model. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
2015-08-04usb: gadget: net2272: add ep capabilities supportRobert Baldyga1-0/+11
Convert endpoint configuration to new capabilities model. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>