Commit graph

388368 commits

Author SHA1 Message Date
Sebastian Andrzej Siewior
97238b35d5 usb: musb: dsps: use proper child nodes
This moves the two instances from the big node into two child nodes. The
glue layer ontop does almost nothing.

There is one devices containing the control module for USB (2) phy,
(2) usb and later the dma engine. The usb device is the "glue device"
which contains the musb device as a child. This is what we do ever since.

The new file musb_am335x is just here to prob the new bus and populate
child devices.

There are a lot of changes to the dsps file as a result of the changes:

- musb_core_offset
  This is gone. The device tree provides memory ressources information
  for the device there is no need to "fix" things

- instances
  This is gone as well. If we have two instances then we have have two
  child enabled nodes in the device tree. For instance the SoC in beagle
  bone has two USB instances but only one has been wired up so there is
  no need to load and init the second instance since it won't be used.

- dsps_glue is now per glue device
  In the past there was one of this structs but with an array of two and
  each instance accessed its variable depending on the platform device
  id.

- no unneeded copy of structs
  I do not know why struct dsps_musb_wrapper is copied but it is not
  necessary. The same goes for musb_hdrc_platform_data which allocated
  on demand and then again by platform_device_add_data(). One copy is
  enough.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-09 17:35:44 +03:00
Sebastian Andrzej Siewior
e96bdc3daf usb: musb: dsps: remove the hardcoded phy pieces
dsps uses a nop driver which is added in dsps itself and does the PHY
on/off calls within dsps. Since those calls are now moved the nop driver
itself, we can now request the phy proper phy and remove those calls.
Currently only the first musb interface is used so we only add one phy
node for now.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-09 17:34:16 +03:00
Sebastian Andrzej Siewior
3bb869c8b3 usb: phy: Add AM335x PHY driver
This driver is a redo of my earlier attempt. It uses parts of the
generic PHY driver and uses the new control driver for the register
the phy needs to power on/off the phy. It also enables easy access for
the wakeup register which is not yet implemented.
The difference between the omap attempt is:
- no static holding variable
- one global visible function which exports a struct with callbacks to
  access the "control" registers.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-09 17:34:15 +03:00
Sebastian Andrzej Siewior
53b6fc28ea usb: phy: phy-generic: export init functions
This patch exports the mostly generic functions so they can be used from
other phy driver instead of duplicating the code.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-09 17:34:02 +03:00
Felipe Balbi
9e5f9c8aa8 Merge branch 'nop-phy-rename' into next
Signed-off-by: Felipe Balbi <balbi@ti.com>

Conflicts:
	drivers/usb/phy/phy-generic.c
2013-08-09 17:31:23 +03:00
Sebastian Andrzej Siewior
3fa4d7344b usb: phy: rename nop_usb_xceiv => usb_phy_gen_xceiv
The "nop" driver isn't a do-nothing-stub but supports a couple functions
like clock on/off or is able to use a voltage regulator. This patch
simply renames the driver to "generic" since it is easy possible to
extend it by a simple function istead of writing a complete driver.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-09 17:26:00 +03:00
Jingoo Han
d07f4a8200 usb: phy: mv-usb: remove incorrect __exit_p annotation
When platform_driver_probe() is not used, bind/unbind via sysfs
is enabled.  Thus, __exit_p annotation should be removed from
remove().

Also, mv_otg_remove() is staticized, because this function is
used only in this file. Fix the following sparse warning:

drivers/usb/phy/phy-mv-usb.c:656:5: warning: symbol 'mv_otg_remove' was not declared. Should it be static?

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-09 16:34:23 +03:00
Jingoo Han
1e0f20bea2 usb: phy: mv-u3d: Staticize mv_u3d_phy_shutdown()
mv_u3d_phy_shutdown() is used only in this file.
Fix the following sparse warning:

drivers/usb/phy/phy-mv-u3d-usb.c:85:6: warning: symbol 'mv_u3d_phy_shutdown' was not declared. Should it be static?

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-09 16:34:21 +03:00
Jingoo Han
cf1dea73c7 usb: gadget: f_uac1: Staticize local functions
control_selector_init() is used only in this file.
audio_bind_config() is used only in audio.c file to which
f_uac1.c is included. Thus, these functions are staticized
to fix the following warnings.

drivers/usb/gadget/f_uac1.c:698:12: warning: symbol 'control_selector_init' was not declared. Should it be static?
drivers/usb/gadget/f_uac1.c:722:12: warning: symbol 'audio_bind_config' was not declared. Should it be static?

Acked-by: Jassi Brar <jaswinder.singh@linaro.org>
Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-09 16:34:19 +03:00
Jingoo Han
2419831c37 usb: gadget: u_uac1: add __user annotation
Added __user annotation to fix the following sparse warning.

drivers/usb/gadget/u_uac1.c:194:52: warning: incorrect type in argument 2 (different address spaces)
drivers/usb/gadget/u_uac1.c:194:52:    expected void const [noderef] <asn:1>*buf
drivers/usb/gadget/u_uac1.c:194:52:    got void *buf

Acked-by: Jassi Brar <jaswinder.singh@linaro.org>
Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-09 16:34:13 +03:00
Jingoo Han
bf19647d8f usb: gadget: rndis: Staticize rndis_init()/rndis_exit()
rndis_init() and rndis_exit() are used only in this file.
Fix the following sparse warnings:

drivers/usb/gadget/rndis.c:1145:5: warning: symbol 'rndis_init' was not declared. Should it be static?
drivers/usb/gadget/rndis.c:1179:6: warning: symbol 'rndis_exit' was not declared. Should it be static?

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-09 16:33:36 +03:00
Jingoo Han
136c489b1c usb: gadget: f_mass_storage: use NULL instead of 0
The local variables such as 'filename', 'vendor_name', and
'product_name' are pointers; thus, use NULL instead of 0 to fix
the following sparse warnings

drivers/usb/gadget/f_mass_storage.c:3046:27: warning: Using plain integer as NULL pointer
drivers/usb/gadget/f_mass_storage.c:3050:28: warning: Using plain integer as NULL pointer
drivers/usb/gadget/f_mass_storage.c:3051:29: warning: Using plain integer as NULL pointer

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-09 16:33:34 +03:00
Alexey Khoroshilov
ffcba5a510 usb: gadget: amd5536udc: unconditionally use GFP_ATOMIC in udc_queue()
As far as prep_dma() is called with spinlock held,
we have to pass GFP_ATOMIC regardless of gfp argument.

Found by Linux Driver Verification project (linuxtesting.org).

Signed-off-by: Alexey Khoroshilov <khoroshilov@ispras.ru>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-09 16:33:31 +03:00
Boris BREZILLON
c0aefc75ce usb: gadget: at91_udc: add usb_clk for transition to common clk framework
The AT91 PMC (Power Management Controller) provides an USB clock used by
USB Full Speed host (ohci) and USB Full Speed device (udc).
The usb drivers (ohci and udc) must configure this clock to 48Mhz.
This configuration was formely done in mach-at91/clock.c, but this
implementation will be removed when moving to common clk framework.

This patch adds support for usb clock retrieval and configuration, and is
backward compatible with the current at91 clk implementation (if usb clk
is not found, it does not configure/enable it).

Signed-off-by: Boris BREZILLON <b.brezillon@overkiz.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-02 15:17:03 +03:00
Boris BREZILLON
30ce198716 usb: gadget: at91_udc: add missing clk_put on fclk and iclk
This patch adds missing clk_put on fclk and iclk in case the probe function
fails after these clocks have been retrieved.

Signed-off-by: Boris BREZILLON <b.brezillon@overkiz.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-02 15:17:02 +03:00
Jingoo Han
93487aa163 usb: gadget: fusb300_udc: Staticize fusb300_rdcxf()
fusb300_rdcxf() used only in this file.
Fix the following sparse warning:

drivers/usb/gadget/fusb300_udc.c:560:6: warning: symbol 'fusb300_rdcxf' was not declared. Should it be static?

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-02 11:19:52 +03:00
Jingoo Han
027ca0d2fe usb: gadget: goku_udc: use NULL instead of 0
'req' is a pointer; thus, use NULL instead of 0
to fix the following sparse warning:

drivers/usb/gadget/goku_udc.c:775:13: warning: Using plain integer as NULL pointer

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-02 11:19:51 +03:00
Jingoo Han
fb74d282d2 usb: dwc3: pci: add CONFIG_PM_SLEEP to suspend/resume functions
Add CONFIG_PM_SLEEP to suspend/resume functions to fix the following
build warning when CONFIG_PM_SLEEP is not selected. This is because
sleep PM callbacks defined by SET_SYSTEM_SLEEP_PM_OPS are only used
when the CONFIG_PM_SLEEP is enabled. Unnecessary CONFIG_PM ifdefs
are removed.

drivers/usb/dwc3/dwc3-pci.c:215:12: warning: 'dwc3_pci_suspend' defined but not used [-Wunused-function]
drivers/usb/dwc3/dwc3-pci.c:224:12: warning: 'dwc3_pci_resume' defined but not used [-Wunused-function]

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-08-02 11:19:49 +03:00
Felipe Balbi
941ea3616c usb: dwc3: use dev_get_platdata()
Use the wrapper function for retrieving the
platform_data instead of accessing dev->platform_data
directly.

While at that also make change 'node' initialization
to use the dev pointer.

Inspired-by: Jingoo Han  <jg1.han@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-31 16:52:02 +03:00
Jingoo Han
f074245960 usb: renesas: use dev_get_platdata()
Use the wrapper function for retrieving the platform data instead of
accessing dev->platform_data directly.

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-30 11:21:58 +03:00
Jingoo Han
c1a7d67c19 usb: musb: use dev_get_platdata()
Use the wrapper function for retrieving the platform data instead of
accessing dev->platform_data directly.

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-30 11:21:54 +03:00
Jingoo Han
19f9e188de usb: phy: use dev_get_platdata()
Use the wrapper function for retrieving the platform data instead of
accessing dev->platform_data directly.

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-30 11:18:53 +03:00
Jingoo Han
e01ee9f509 usb: gadget: use dev_get_platdata()
Use the wrapper function for retrieving the platform data instead of
accessing dev->platform_data directly.

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-30 11:18:46 +03:00
Mikko Perttunen
b27f274d35 usb: tegra: Fix typo in tegra20-usb-phy documentation
The device tree binding documentation for tegra20-usb-phy used to claim
that the vbus-supply property is required for host phys and optional
for otg phys. This should be the other way around.

Signed-off-by: Mikko Perttunen <mperttunen@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-30 09:59:43 +03:00
Felipe Balbi
9cf7b24418 usb: of: fix build breakage caused by recent patches
commit 052a11d (usb: phy: make PHY driver selection
possible by controller drivers) changed the rules
on how drivers/usb/phy/of.c would be compiled and
failed to update include/linux/usb/of.h accordingly.

Because of that, we can fall into situations where
of_usb_get_phy_mode() is redefined. In order to fix
the error, we update the IS_ENABLED() check in
include/linux/usb/of.h to reflect the condition
where of.c is built.

Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-30 09:09:15 +03:00
Ivan T. Ivanov
2e112345c2 usb: dwc3: core: modify IO memory resource after deferred probe completes
When deferred probe happens driver will try to ioremap multiple times
and will fail. Memory resource.start variable is a global variable,
modifications in this field will be accumulated on every probe.
Fix this by moving the above operations after driver hold all
required PHY's.

Signed-off-by: Ivan T. Ivanov <iivanov@mm-sol.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 15:22:37 +03:00
Tuomas Tynkkynen
a554aea67a usb: phy: tegra: Use switch instead of if-else
Use switch() instead of if-else when checking for the PHY type.

Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 15:19:19 +03:00
Sebastian Andrzej Siewior
9be73bae70 usb: musb: dsps: remove EOI access
The EOI register is not present in the AM335x memory space according to
the TRM and thus removed.
Should any platform using the EOI register get merged then it may be
used again if the register address is not zero.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:28 +03:00
Sebastian Andrzej Siewior
fa7b4ca50f usb: musb: dsps: rename ti81xx_driver_data to am33xx_driver_data
The ti81xx platform is not fully supported right now. This patch renames
the date structure to a am33xx prefix which is actually used.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:28 +03:00
Tuomas Tynkkynen
6558d7edbe usb: phy: tegra: Use DT helpers for dr_mode
Use the new of_usb_get_dr_mode helper function for parsing dr_mode
from the device tree. Also replace the usage of the custom
tegra_usb_phy_mode enum with the standard enum.

Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:27 +03:00
Tuomas Tynkkynen
9fdb07f720 usb: phy: tegra: Use DT helpers for phy_type
Use the new of_usb_get_phy_mode helper function for parsing phy_type
from the device tree.

Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:26 +03:00
Tuomas Tynkkynen
3b102e8bc0 usb: phy: tegra: Remove custom PHY locating APIs
The Tegra EHCI driver is no longer using these custom functions, so they
can be removed.

Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:25 +03:00
Tuomas Tynkkynen
7db71a9a67 usb: host: tegra: Locate a PHY via standard API
Use devm_get_phy_by_phandle to get a PHY device instead of the custom
Tegra functions.

Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:25 +03:00
Tuomas Tynkkynen
0ee5b4ab79 usb: phy: tegra: Register as an USB PHY.
Register the Tegra PHY device instances with the PHY subsystem so that
the Tegra EHCI driver can locate a PHY via the standard APIs.

Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:24 +03:00
Tuomas Tynkkynen
5fed682831 ARM: tegra: Remove USB platform data
USB-related platform data is not used anymore in the Tegra USB drivers,
so remove all of it.

Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Acked-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:23 +03:00
Tuomas Tynkkynen
d506427945 usb: tegra: host: Remove references to plat data
Platform data is not used in tegra-ehci anymore, so remove all
references to it.

Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:22 +03:00
Tuomas Tynkkynen
de3f233703 usb: host: tegra: Remove leftover code
ehci-tegra calls devm_usb_get_phy, which will never succeed since the Tegra
PHY does not register itself with the PHY subsystem. It is also completely
redundant since the code has already located a PHY via an internal API.

Call otg_set_host unconditionally to simplify the code since it should
be safe to do so.

Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:21 +03:00
Tuomas Tynkkynen
185d0fd570 usb: phy: tegra: Remove unnecessary 'dev' field
struct usb_phy already has a field for the device pointer, so this
unnecessary field can be removed.

Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:21 +03:00
Mikko Perttunen
103566e40d arm: tegra: Remove obsolete nvidia,vbus-gpio properties
USB VBUS regulators are now specified with the vbus-supply property
instead of nvidia,vbus-gpio, so remove the obsolete properties.

The equivalent vbus-supply properties were already added in patch
"ARM: tegra: update device trees for USB binding rework".

Signed-off-by: Mikko Perttunen <mperttunen@nvidia.com>
Acked-by: Stephen Warren <swarren@nvidia.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:20 +03:00
Mikko Perttunen
80bd8a9471 usb: tegra: Add vbus-supply property for host mode PHYs
Document vbus-supply as an optional property for host mode phy-tegra-usb PHYs.

Signed-off-by: Mikko Perttunen <mperttunen@nvidia.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:19 +03:00
Mikko Perttunen
f5b8c8b6d3 usb: tegra: Use regulators instead of GPIOs for USB PHY VBUS
The tegra ehci driver has enabled USB vbus regulators directly using
GPIOs and the device tree attribute nvidia,vbus-gpio. This is ugly
and causes error messages on boot when both the regulator driver
and the ehci driver want access to the same GPIO.

After this patch, usb vbus regulators for tegra usb phy devices are specified
with the device tree attribute vbus-supply = <&x> where x is a regulator defined
in the device tree. The old nvidia,vbus-gpio property is no longer supported.

Signed-off-by: Mikko Perttunen <mperttunen@nvidia.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:18 +03:00
Mikko Perttunen
81d5dfe6d8 usb: phy: tegra: Read UTMIP parameters from device tree
UTMIP parameters used to be hardcoded into tables in the
PHY driver. This patch reads them from the device tree instead
in accordance with the phy-tegra-usb DT documentation.

Signed-off-by: Mikko Perttunen <mperttunen@nvidia.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:17 +03:00
Mikko Perttunen
c49667e56f arm: dts: tegra20: Rename USB UTMI parameters according to new definitions
This patch changes the Tegra20 USB PHY nodes to use the UTMI configuration
parameter names as specified in the device tree binding documentation
after patch "ARM: tegra: finalize USB EHCI and PHY bindings".

Signed-off-by: Mikko Perttunen <mperttunen@nvidia.com>
Acked-by: Stephen Warren <swarren@nvidia.com>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:17 +03:00
Sebastian Andrzej Siewior
63c5b4ca7d usb: musb: do not change dev's dma_mask
Commit 8d2421e ("usb: musb: kill global and static for multi instance")
removed the global dma_mask copy and replaced by parent's DMA mask. The
problem here is that if the parent does not have a dma_mask then
musb_remove() goes kaboom.
Instead trying to fix this I was thinking we do we need to erase
dma_mask in the first place?

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:16 +03:00
Sebastian Andrzej Siewior
e9eb2e08d9 usb: musb: remove ti81xx pieces from musb
ti81xx does not have a baseport mainline i.e. it should not boot. The
amount of rework that is required makes it easier to simply remove that
platform (i.e. that possible platform device) and add it later once it
comes back with DT support.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:15 +03:00
Sebastian Andrzej Siewior
7557a57f5e usb: musb: dsps: init / shutdown the phy
If the init / shutdown function of the phy moves out of dsps into the
phy driver, then dsps needs to call the callbacks of the phy driver to
ensure that this happens.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:14 +03:00
Wolfram Sang
fda7130354 usb: phy: don't check resource with devm_ioremap_resource
devm_ioremap_resource does sanity checks on the given resource. No need to
duplicate this in the driver.

Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:14 +03:00
Boris BREZILLON
0d98b9d642 usb: gadget: atmel_usba: prepare clk before calling enable
Replace clk_enable/disable with clk_prepare_enable/disable_unprepare to
avoid common clk framework warnings.

Signed-off-by: Boris BREZILLON <b.brezillon@overkiz.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:13 +03:00
Kuninori Morimoto
925403f425 usb: renesas_usbhs: tidyup original usbhsx_for_each_xxx macro
Current usbhsx_for_each_xxx macro will read out-of-array's
memory after last loop operation.
It was not good C language operation, and the binary which was
compiled by (at least) gcc 4.8.1 is broken
This patch tidyup these issues

Reported-by: Yusuke Goda <yusuke.goda.sx@renesas.com>
Reviewed-by: Takashi Yoshii <takashi.yoshii.zj@renesas.com>
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:12 +03:00
Roger Quadros
519c6013d3 usb: phy: omap-usb3: Improve DPLL parameter lookup code
Use a mapping table (dpll_map) to match the possible system clock rates
to the appropriate DPLL parameters.

Introduce a function "omap_usb3_get_dpll_params()" that will
return the matching DPLL parameters for the given clock rate.

Also, bail out on phy init if DPLL locking fails.

Signed-off-by: Roger Quadros <rogerq@ti.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
2013-07-29 13:58:09 +03:00