Skip to contentSkip to conversation

phy: Add a driver for dm816x USB PHY

PATCH New Tony Lindgren 1 participant 1 message Mar 20, 2015

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH v3 1/1 phy: Add a driver for dm816x USB PHY

Add a minimal driver for dm816x USB. This makes USB work on dm816x without any other changes needed as it can use the existing musb_dsps glue layer for the USB controller.

Note that this phy is different from dm814x and am335x.

Cc Bin Liu <[email protected]>
Cc Brian Hutchinson <[email protected]>
Cc Felipe Balbi <[email protected]>
Cc Matthijs van Duin <[email protected]>
Cc Paul Bolle <[email protected]>
Cc Rusty Russell <[email protected]>
---
 .../devicetree/bindings/phy/dm816x-phy.txt         |  24 ++
 drivers/phy/Kconfig                                |   7 +
 drivers/phy/Makefile                               |   1 +
 drivers/phy/phy-dm816x-usb.c                       | 290 +++++++++++++++++++++
 4 files changed, 322 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/phy/dm816x-phy.txt
 create mode 100644 drivers/phy/phy-dm816x-usb.c
Documentation/devicetree/bindings/phy/dm816x-phy.txt new file +24 -0
new file mode 100644
index 0000000..2fe3d11
@@ -0,0 +1,24 @@
+Device tree binding documentation for am816x USB PHY
+=========================
+
+Required properties:
+- compatible : should be "ti,dm816x-usb-phy"
+- reg : offset and length of the PHY register set.
+- reg-names : name for the phy registers
+- clocks : phandle to the clock
+- clock-names : name of the clock
+- syscon: phandle for the syscon node to access misc registers
+- #phy-cells : from the generic PHY bindings, must be 1
+- syscon: phandle for the syscon node to access misc registers
+
+Example:
+
+usb_phy0: usb-phy@20 {
+	compatible = "ti,dm8168-usb-phy";
+	reg = <0x20 0x8>;
+	reg-names = "phy";
+	clocks = <&main_fapll 6>;
+	clock-names = "refclk";
+	#phy-cells = <0>;
+	syscon = <&scm_conf>;
+};
drivers/phy/Kconfig +7 -0
index 2962de2..08269ea 100644
@@ -35,6 +35,13 @@ config ARMADA375_USBCLUSTER_PHY
 	depends on OF
 	select GENERIC_PHY
 
+config PHY_DM816X_USB
+	tristate "TI dm816x USB PHY driver"
+	depends on ARCH_OMAP2PLUS
+	select GENERIC_PHY
+	help
+	  Enable this for dm81xx USB to work.
+
 config PHY_EXYNOS_MIPI_VIDEO
 	tristate "S5P/EXYNOS SoC series MIPI CSI-2/DSI PHY driver"
 	depends on HAS_IOMEM
drivers/phy/Makefile +1 -0
index f080e1b..dab6665 100644
@@ -5,6 +5,7 @@
 obj-$(CONFIG_GENERIC_PHY)		+= phy-core.o
 obj-$(CONFIG_PHY_BERLIN_USB)		+= phy-berlin-usb.o
 obj-$(CONFIG_PHY_BERLIN_SATA)		+= phy-berlin-sata.o
+obj-$(CONFIG_PHY_DM816X_USB)		+= phy-dm816x-usb.o
 obj-$(CONFIG_ARMADA375_USBCLUSTER_PHY)	+= phy-armada375-usb2.o
 obj-$(CONFIG_BCM_KONA_USB2_PHY)		+= phy-bcm-kona-usb2.o
 obj-$(CONFIG_PHY_EXYNOS_DP_VIDEO)	+= phy-exynos-dp-video.o
drivers/phy/phy-dm816x-usb.c new file +290 -0

290 lines not on this page · raw message

Signature · 1 line
2.1.4