summaryrefslogtreecommitdiffstats
path: root/drivers/usb/phy
Commit message (Collapse)AuthorAgeFilesLines
* USB: OMAP: ISP1301 needs USB_PHYArnd Bergmann2013-04-251-1/+1
| | | | | | | | | | | | | | | | The Kconfig entry for USB_OMAP unconditionally selects USB_ISP1301, which is now only visible when USB_PHY is also enabled. This adds an appropriate dependency and enables USB_PHY in the omap1 defconfig, avoiding these build warnings: warning: (USB_OHCI_HCD && USB_OMAP) selects ISP1301_OMAP which has unmet direct dependencies (USB_SUPPORT && USB_PHY && I2C && ARCH_OMAP_OTG) Also fix a Makefile typo while we're at it. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Cc: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* usb: phy: tegra: don't call into tegra-ehci directlyArnd Bergmann2013-04-231-4/+9
| | | | | | | | | | | | | | | | | | | | | | | | Both phy-tegra-usb.c and ehci-tegra.c export symbols used by the other one, which does not work if one of them or both are loadable modules, resulting in an error like: drivers/built-in.o: In function `utmi_phy_clk_disable': drivers/usb/phy/phy-tegra-usb.c:302: undefined reference to `tegra_ehci_set_phcd' drivers/built-in.o: In function `utmi_phy_clk_enable': drivers/usb/phy/phy-tegra-usb.c:324: undefined reference to `tegra_ehci_set_phcd' drivers/built-in.o: In function `utmi_phy_power_on': drivers/usb/phy/phy-tegra-usb.c:447: undefined reference to `tegra_ehci_set_pts' This turns the interface into a one-way dependency by letting the tegra ehci driver pass two function pointers for callbacks that need to be called by the phy driver. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Cc: Venu Byravarasu <vbyravarasu@nvidia.com> Cc: Alan Stern <stern@rowland.harvard.edu> Cc: Felipe Balbi <balbi@ti.com> Cc: Stephen Warren <swarren@nvidia.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* usb: phy: phy core cannot yet be a moduleArnd Bergmann2013-04-231-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A lot of platform code calls into the usb phy core at the moment, which does not work if it is built as a loadable module. This will hopefully change when those platforms are all converted to DT based probing, but for now, the easiest solution is to change it from "tristate" to "bool". This solves at least these ARM allmodconfig build errors: arch/arm/mach-imx/built-in.o: In function `imx_otg_ulpi_create': arch/arm/mach-imx/ulpi.c:117: undefined reference to `otg_ulpi_create' arch/arm/mach-omap2/built-in.o: In function `usbhs_init_phys': arch/arm/mach-omap2/usb-host.c:652: undefined reference to `usb_bind_phy' arch/arm/mach-omap2/built-in.o: In function `omap_2430sdp_init': arch/arm/mach-omap2/board-2430sdp.c:236: undefined reference to `usb_bind_phy' arch/arm/mach-omap2/built-in.o: In function `omap3_beagle_init': arch/arm/mach-omap2/board-omap3beagle.c:554: undefined reference to `usb_bind_phy' arch/arm/mach-omap2/built-in.o: In function `devkit8000_init': arch/arm/mach-omap2/board-devkit8000.c:596: undefined reference to `usb_bind_phy' arch/arm/mach-omap2/built-in.o: In function `omap_ldp_init': arch/arm/mach-omap2/board-ldp.c:379: undefined reference to `usb_bind_phy' drivers/built-in.o: In function `ab8500_charger_probe': drivers/power/ab8500_charger.c:3629: undefined reference to `usb_get_phy' drivers/power/ab8500_charger.c:3706: undefined reference to `usb_put_phy' drivers/built-in.o: In function `ab8500_charger_remove': drivers/power/ab8500_charger.c:3411: undefined reference to `usb_put_phy' Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Merge tag 'usb-for-v3.10-part2' of ↵Greg Kroah-Hartman2013-04-231-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb into usb-next Felipe writes: usb: urgent fixes for v3.10 merge window Here are some late urgent fixes for v3.10 merge window. All of these errors were introduced by recent commits which are in linux-next. f_obex, multi and cdc2 gadget drivers have learned to return a proper error code when something goes wrong. usb_bind_phy() was mistakenly placed into .init.text section which caused Section mismatch warnings and undefined reference compile errors. f_source_sink had a copy-paste error which is now corrected. g_zero got a memory leak plugged. Two defconfigs got fixed to enable the newly introduced CONFIG_USB_PHY.
| * usb: phy: remove exported function from __init sectionDenis Efremov2013-04-231-1/+1
| | | | | | | | | | | | | | | | | | | | | | The symbol usb_bind_phy is exported and annotated __init. It looks like section mismatch. Fix by removing the __init annotation of usb_bind_phy. Found by Linux Driver Verification project (linuxtesting.org). Signed-off-by: Denis Efremov <yefremov.denis@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
* | Merge tag 'usb-for-v3.10' of ↵Greg Kroah-Hartman2013-04-0533-1032/+12244
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb into usb-next Felipe writes: usb: patches for v3.10 merge window Here is the big Gadget & PHY pull request. Many of us have been really busy lately getting multiple drivers to a better position. Since this pull request is so large, I will divide it in sections so it's easier to grasp what's included. - cleanups: . UDC drivers no longer touch gadget->dev, that's now udc-core responsibility . Many more UDC drivers converted to usb_gadget_map/unmap_request() . UDC drivers no longer initialize DMA-related fields from gadget's device structure . UDC drivers don't touch gadget.dev.driver directly . UDC drivers don't assign gadget.dev.release directly . Removal of some unused DMA_ADDR_INVALID . Introduction of CONFIG_USB_PHY . All phy drivers have been moved to drivers/usb/phy and renamed to a common naming scheme . Fix PHY layer so it never returns a NULL pointer, also fix all callers to avoid using IS_ERR_OR_NULL() . Sparse fixes all over the place . drivers/usb/otg/ has been deleted . Marvel drivers (mv_udc, ehci-mv, mv_otg and mv_u3d) improved clock usage - new features: . UDC core now provides a generic way for tracking and reporting UDC's state (not attached, resuming, suspended, addressed, default, etc) . twl4030-usb learned that it shouldn't be enabled during init . Full DT support for DWC3 has been implemented . ab8500-usb learned about pinctrl framework . nop PHY learned about DeviceTree and regulators . DWC3 learned about suspend/resume . DWC3 can now be compiled in host-only and gadget-only (as well as DRD) configurations . UVC now enables streaming endpoint based on negotiated speed . isp1301 now implements the PHY API properly . configfs-based interface for gadget drivers which will lead to the removal of all code which just combines functions together to build functional gadget drivers. . f_serial and f_obex were converted to new configfs interface while maintaining old interface around. - non-critical fixes: . UVC gadget driver got fixes for Endpoint usage and stream calculation . ab8500-usb fixed unbalanced clock and regulator API usage . twl4030-usb got a fix for when OMAP3 is booted with cable connected . fusb300_udc got a fix for DMA usage . UVC got fixes for two assertions of the USB Video Class Compliance specification revision 1.1 . build warning issues caused by recent addition of __must_check to regulator API These are all changes which deserve a mention, all other changes are related to these one or minor spelling fixes and other similar tasks. Signed-of-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: twl6030-usb: check regulator_enable return valueFabio Baltieri2013-04-031-2/+9
| | | | | | | | | | | | | | | | | | | | Since regulator_enable() is going to be marked as __must_check in the next merge window, always check regulator_enable() return value and print a warning if it fails. Cc: Hema HK <hemahk@ti.com> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: twl4030-usb: check regulator_enable return valueFabio Baltieri2013-04-031-3/+15
| | | | | | | | | | | | | | | | | | | | Since regulator_enable() is going to be marked as __must_check in the next merge window, always check regulator_enable() return value and print a warning if it fails. Reviewed-by: Kalle Jokiniemi <kalle.jokiniemi@jollamobile.com> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: ab8500-usb: check regulator_enable return valueFabio Baltieri2013-04-031-3/+9
| | | | | | | | | | | | | | | | | | | | Since regulator_enable() is going to be marked as __must_check in the next merge window, always check regulator_enable() return value and print a warning if it fails. Cc: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: ab8500-usb: call phy_dis_work only when necessarySakethram Bommisetti2013-04-031-9/+8
| | | | | | | | | | | | | | | | | | | | | | Modify ab8500_usb_set_peripheral() and ab8500_usb_set_host() code to schedule phy_dis_work only when necessary in order to prevent regulator count mismatch during reboot/shutdown. Signed-off-by: Sakethram Bommisetti <sakethram.bommisetti@stericsson.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: ab8500-usb: drop link status delayed workSakethram Bommisetti2013-04-031-28/+2
| | | | | | | | | | | | | | | | | | | | | | ab8500_usb_delayed_work was implemented as a workaroud for the internal only and now unsupported v1.0 version of AB850. This patch removes the delayed work and just leave a link status update call at probe time. Signed-off-by: Sakethram Bommisetti <sakethram.bommisetti@stericsson.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: ab8500-usb: adopt pinctrl supportPatrice Chotard2013-04-031-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Amend the ab8500-usb driver to optionally take a pin control handle and set the state of the pins to "default" on ab8500_usb_phy_enable and to "sleep" on ab8500_usb_phy_disable. The pinctrl handle is released on ab8500_usb_phy_disable because USB pins are shared with ab8505_micro_usb_iddet driver. Signed-off-by: Patrice Chotard <patrice.chotard@st.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: ab8500-usb: fix last notifier argumentsFabio Baltieri2013-04-031-7/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | Fix last ab->phy.notifier call to use vbus_draw as notifier argument, as that's used in ab8500_charger to control charging current. Also drop a related TODO comment, and the additional ux500_musb_set_vbus(musb, 0), as with this patch it was causing an erratic behaviour of gadget ep0 state machine. Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: ab8500-usb: fix unbalanced clock and regulator disable warningsMian Yousaf Kaukab2013-04-031-2/+4
| | | | | | | | | | | | | | | | | | | | | | To prevent clock and regulator frameworks from complaining, only disable the host or peripheral phy if they were enabled. Reported-by: Sakethram Bommisetti <sakethram.bommisetti@stericsson.com> Signed-off-by: Mian Yousaf Kaukab <mian.yousaf.kaukab@stericsson.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: ab8500-usb: enable/disable regulator on phy eventsFabio Baltieri2013-04-031-2/+66
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add ab8500_usb_regulator_{enable,disable} functions to control USB phy regulators on corresponding ab8500_usb_phy_{enable,disable} events. This contains some workaround and optimization for specific AB8500 versions. Signed-off-by: Mian Yousaf Kaukab <mian.yousaf.kaukab@stericsson.com> Signed-off-by: Sakethram Bommisetti <sakethram.bommisetti@stericsson.com> Signed-off-by: Praveena Nadahally <praveen.nadahally@stericsson.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: ab8500-usb: split ab8500_usb_phy_ctrlFabio Baltieri2013-04-031-29/+26
| | | | | | | | | | | | | | | | | | Split ab8500_usb_phy_ctrl into separate enable/disable functions to make the code more linear and readable. Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: ab8500-usb: add regulator supportFabio Baltieri2013-04-031-0/+36
| | | | | | | | | | | | | | | | | | Add initial regulator support to ab8500-usb by introducing necessary devm_regulator_get(). Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: ab8500-usb: fix eye diagram for ab8500 v2.0Sakethram Bommisetti2013-04-031-0/+15
| | | | | | | | | | | | | | | | | | | | AB8500 v2.0 has eye diagram issues when drawing more than 100mA from VBUS. Force charging current to 100mA in case of standard host. Signed-off-by: Sakethram Bommisetti <sakethram.bommisetti@stericsson.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: ab8500-usb: set phy tuning valuesSakethram Bommisetti2013-04-031-0/+87
| | | | | | | | | | | | | | | | | | | | Set phy tuning values proposed by the hardware teams for AB8500 and AB8505 to improve USB eye diagram performances. Signed-off-by: Sakethram Bommisetti <sakethram.bommisetti@stericsson.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: ab8500-usb: convert to devm_kzallocFabio Baltieri2013-04-031-14/+5
| | | | | | | | | | | | | | | | | | Convert local data allocation to devm_kzalloc and drop unnecessary fail path code. Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: samsung: convert to devm_ioremap_resource()Sachin Kamat2013-04-031-5/+3
| | | | | | | | | | | | | | | | | | | | | | Use the newly introduced devm_ioremap_resource() instead of devm_request_and_ioremap() which provides more consistent error handling. devm_ioremap_resource() provides its own error messages; so all explicit error messages can be removed from the failure code paths. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: otg: mv_otg: remove unused clockChao Xie2013-04-022-23/+8
| | | | | | | | | | | | | | | | | | | | The origianl understanding of clock is wrong. The OTG controller only have one clock input. Passing clock name by pdata is wrong. The clock is defined by device iteself. Signed-off-by: Chao Xie <chao.xie@marvell.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: twl4030-usb: check if vbus is driven by twl itselfGrazvydas Ignotas2013-04-021-3/+28
| | | | | | | | | | | | | | | | | | | | At least on pandora, STS_VBUS gets set even when VBUS is driven by twl itself. Reporting VBUS in this case confuses OMAP musb glue and charger driver, so check if OTG VBUS charge pump is on before reporting VBUS event to avoid this problem. Signed-off-by: Grazvydas Ignotas <notasas@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: gadget: mv_u3d: drop ARCH dependencyFelipe Balbi2013-03-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | this driver compiles fine everywhere which means we can use linux-next to compile it for us frequently. By dropping the arch dependency, we also ensure driver writers don't add virtual arch-depdencies to the driver by e.g. using the wrong headers. While at that, fix Marvell's USB3 PHY dependency, that's the driver which depends on CPU_MM3, not mv_u3d_core. Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: twl4030-usb: poll for ID disconnectGrazvydas Ignotas2013-03-211-7/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On pandora, STS_USB interrupt doesn't arrive on USB host cable disconnect for some reason while VBUS is driven by twl itself, but STS_HW_CONDITIONS is updated correctly. It does work fine when PHY is powered down though. To work around that we have to poll. This patch also moves twl->linkstat update code to callers so that changes can be handled in thread safe way (as polling work can trigger at the same time as real irq now). TI PSP kernels have similar workarounds, so (many?) more boards are likely affected. Signed-off-by: Grazvydas Ignotas <notasas@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: twl4030-usb: don't switch the phy on/off needlesslyGrazvydas Ignotas2013-03-211-6/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With runtime_pm in place there is no longer need to turn the phy on/off in OTG layer on cable connect/disconnect, OMAP glue does this through otg.set_suspend() callback after it's called through omap_musb_mailbox() on VBUS/ID interrupt. Not doing this will save power when cable is connected but no gadget driver is loaded. This will also have side effect of automatic USB charging no longer working without twl4030_charger driver, because a regulator needed for charging will no longer be enabled, so be sure to enable charger driver if charging is needed. Signed-off-by: Grazvydas Ignotas <notasas@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: twl4030-usb: ignore duplicate eventsGrazvydas Ignotas2013-03-211-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | In some rare cases we may get multiple interrupts that will generate duplicate omap_musb_mailbox() calls. This is a problem because each VBUS/ID event generates runtime_pm call in OMAP glue code, causing unbalanced gets or puts and breaking PM. The same goes for initial state, glue already defaults to "no cable" state, so only bother it if we have VBUS or ID. Signed-off-by: Grazvydas Ignotas <notasas@gmail.com> Reviewed-by: Kishon Vijay Abraham I <kishon@ti.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: twl4030-usb: don't enable PHY during initGrazvydas Ignotas2013-03-211-11/+9
| | | | | | | | | | | | | | | | | | | | There is no need to do it, otg.set_suspend(false) (which itself comes from runtime_pm OMAP glue calls) will enable it later anyway. This used to be the place where things were enabled if booted with cable connected before runtime_pm conversion, but now can be dropped. Signed-off-by: Grazvydas Ignotas <notasas@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: gpio-vbus: don't ignore regulator APIs return valueFelipe Balbi2013-03-201-2/+7
| | | | | | | | | | | | | | | | | | | | | | Due to recent changes to regulator API, all users which don't check regulator_{en,dis}able()'s return value will generate compile warnings. Add such checks to gpio-vbus. Cc: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: samsung: fix sparse warningFelipe Balbi2013-03-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Fix the following sparse warning: drivers/usb/phy/phy-samsung-usb2.c:50:26: sparse: incorrect type in argument 1 (different address spaces) drivers/usb/phy/phy-samsung-usb2.c:50:26: expected void const volatile [noderef] <asn:2>*addr drivers/usb/phy/phy-samsung-usb2.c:50:26: got void * Cc: Vivek Gautam <gautam.vivek@samsung.com> Cc: Kukjin Kim <kgene.kim@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: ab8500-usb: update irq handling codeFabio Baltieri2013-03-181-93/+347
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Update irq handling code to notify all possible link status changes of AB8500 and AB8505 to the ux500-musb glue driver. The additional event codes will be used for pm-runtime implementation, and are defined in a separate ux500-specific header. This also modify the irq registration code to use devm_* helpers and drop all non necessary fail path code. Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: otg: ab8500-usb: drop support for ab8500 pre v2.0Fabio Baltieri2013-03-181-128/+11
| | | | | | | | | | | | | | | | | | | | AB8500 versions preceding 2.0 were only used internally by ST-Ericsson and are not supported anymore. This patch drops all v1.0 and v1.1 support code. Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: twl4030: fix cold plug on OMAP3Kishon Vijay Abraham I2013-03-181-6/+4
| | | | | | | | | | | | | | | | | | | | | | | | Having twl4030_usb_phy_init() (detects if a cable is connected before twl4030 is probed) in twl4030 probe makes cable connect events to be missed by musb glue, since it gets loaded after twl4030. Having twl4030_usb_phy_init as a usb_phy ops lets twl4030_usb_phy_init to be called when glue is ready. Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> Tested-by: Grazvydas Ignotas <notasas@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: twl4030: use devres API for regulator get and request irqKishon Vijay Abraham I2013-03-181-20/+8
| | | | | | | | | | | | | | | | | | Used devres APIs devm_request_threaded_irq and devm_regulator_get for requesting irq and for getting regulator respectively. Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> Tested-by: Grazvydas Ignotas <notasas@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: samsung: Add PHY support for USB 3.0 controllerVivek Gautam2013-03-184-0/+437
| | | | | | | | | | | | | | | | | | Adding PHY driver support for USB 3.0 controller for Samsung's SoCs. Signed-off-by: Vivek Gautam <gautam.vivek@samsung.com> Acked-by: Kukjin Kim <kgene.kim@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: samsung: Common out the generic stuffVivek Gautam2013-03-185-713/+785
| | | | | | | | | | | | | | | | | | | | | | | | | | Moving register and structure definitions to header file, and keeping the generic functions to be used across multiple PHYs in common phy helper driver under SAMSUNG_USBPHY, and moving USB 2.0 PHY driver under SAMSUNG_USB2PHY. Also allowing samsung PHY drivers be built as modules. Signed-off-by: Vivek Gautam <gautam.vivek@samsung.com> Acked-by: Kukjin Kim <kgene.kim@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: isp1301: implement PHY APIFelipe Balbi2013-03-181-0/+59
| | | | | | | | | | | | | | | | | | | | this patch implements ->init() and ->set_vbus() methods for isp1301 transceiver driver. Later patches can now come in order to remove the hackery from ohci-nxp and lpc32xx udc drivers. Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: isp1301: give it a context structureFelipe Balbi2013-03-181-0/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | this patch is a small preparation to fix isp1301 driver so that other platforms can use it. We're defining our private data structure to represent this device and adding the PHY to the PHY list. Later patches will come implementing proper PHY API and removing bogus code from ohci_nxp and lpc32xx_udc drivers. Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: rename all phy drivers to phy-$name-usb.cFelipe Balbi2013-03-1826-25/+25
| | | | | | | | | | | | | | | | this will make sure that we have sensible names for all phy drivers. Current situation was already quite bad with too generic names being used. Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: remove CONFIG_USB_OTG_UTILSFelipe Balbi2013-03-181-23/+0
| | | | | | | | | | | | | | | | | | | | | | | | there are no more users of CONFIG_USB_OTG_UTILS left in tree, we can remove it just fine. [ kishon@ti.com : fixed a linking error due to original patch forgetting to change drivers/usb/Makefile ] Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: make it a menuconfigFelipe Balbi2013-03-182-6/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | We already have a considerable amount of USB PHY drivers, making it a menuconfig just prevents us from adding too much churn to USB's menuconfig. While at that, also select USB_OTG_UTILS from this new menuconfig just to keep backwards compatibility until we manage to remove that symbol. Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: move all PHY drivers to drivers/usb/phy/Felipe Balbi2013-03-1818-21/+9821
| | | | | | | | | | | | | | | | | | | | | | | | that's a much more reasonable location for those drivers. It helps us saving drivers/usb/otg/ for when we actually start adding generic OTG code. Also completely delete drivers/usb/otg/ as there's nothing left there. Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: convert EXPORT_SYMBOL to EXPORT_SYMBOL_GPLFelipe Balbi2013-03-181-10/+10
| | | | | | | | | | | | | | we only want GPL users for our generic functions, so let's switch over to EXPORT_SYMBOL_GPL. Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: move bulk of otg/otg.c to phy/phy.cSascha Hauer2013-03-182-0/+439
| | | | | | | | | | | | | | | | | | | | | | Most of otg/otg.c is not otg specific, but phy specific, so move it to the phy directory. Tested-by: Steffen Trumtrar <s.trumtrar@pengutronix.de> Reported-by: Kishon Vijay Abraham I <kishon@ti.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: Felipe Balbi <balbi@ti.com>
* | Merge branch 'usb-linus' into usb-nextGreg Kroah-Hartman2013-03-281-0/+1
|\ \ | | | | | | | | | | | | | | | | | | This lets us fix the build error that happens when these two trees are merged together. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * | usb: Fix compile error by selecting USB_OTG_UTILSRoland Stigge2013-03-271-0/+1
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The current lpc32xx_defconfig breaks like this, caused by recent phy restructuring: LD init/built-in.o drivers/built-in.o: In function `usb_hcd_nxp_probe': drivers/usb/host/ohci-nxp.c:224: undefined reference to `isp1301_get_client' drivers/built-in.o: In function `lpc32xx_udc_probe': drivers/usb/gadget/lpc32xx_udc.c:3104: undefined reference to `isp1301_get_client' distcc[27867] ERROR: compile (null) on localhost failed make: *** [vmlinux] Error 1 Caused by 1c2088812f095df77f4b3224b65db79d7111a300 (usb: Makefile: fix drivers/usb/phy/ Makefile entry) This patch fixes this by selecting USB_OTG_UTILS in Kconfig which causes the phy driver to be built again. Signed-off-by: Roland Stigge <stigge@antcom.de> Acked-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | Merge branch 'usb-linus' into usb-nextGreg Kroah-Hartman2013-03-203-25/+15
|\| | | | | | | | | | | | | | | This is to pick up the fixes in that branch, and let Alan fix the merge error in drivers/usb/host/ehci-timer.c better than I just did (as I know I messed it up...) Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * usb: phy: omap-control-usb: Convert to devm_ioremap_resource()Sachin Kamat2013-03-041-15/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | Use the newly introduced devm_ioremap_resource() instead of devm_request_and_ioremap() which provides more consistent error handling. devm_ioremap_resource() provides its own error messages; so all explicit error messages can be removed from the failure code paths. Reviewed-by: Thierry Reding <thierry.reding@avionic-design.de> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Cc: Kishon Vijay Abraham I <kishon@ti.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: omap-usb3: Convert to devm_ioremap_resource()Sachin Kamat2013-03-041-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | Use the newly introduced devm_ioremap_resource() instead of devm_request_and_ioremap() which provides more consistent error handling. devm_ioremap_resource() provides its own error messages; so all explicit error messages can be removed from the failure code paths. Reviewed-by: Thierry Reding <thierry.reding@avionic-design.de> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Cc: Kishon Vijay Abraham I <kishon@ti.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
| * usb: phy: samsung: Convert to devm_ioremap_resource()Sachin Kamat2013-03-041-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | Use the newly introduced devm_ioremap_resource() instead of devm_request_and_ioremap() which provides more consistent error handling. devm_ioremap_resource() provides its own error messages; so all explicit error messages can be removed from the failure code paths. Reviewed-by: Thierry Reding <thierry.reding@avionic-design.de> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Felipe Balbi <balbi@ti.com>