USB OTG PHY driver for NXP LPC18xx family
v4 cover USB OTG PHY driver for NXP LPC18xx family
This patch set adds support for the internal USB OTG PHY found on NXP LPC18xx and LPC43xx devices. Driver takes care of enabling the PHY and setting the clock rate which is need for USB0 support on this platform.
This version address moves the dt node under the creg syscon and rebases the patch set on 4.2-rc1.
Changes in v4:
- rebase on 4.2-rc1
- move dt node under creg where the control reg is
Changes in v3:
- depend on MFD_SYSCON
Changes in v2:
- use PTR_ERR_OR_ZERO in phy driver
- rename binding doc
- update doc commit message
Joachim Eastwood (2):
phy: add lpc18xx usb otg phy driver
phy: dt bindings: add NXP LPC18xx/43xx USB OTG PHY bindings
.../bindings/phy/phy-lpc18xx-usb-otg.txt | 26 ++++ drivers/phy/Kconfig | 11 ++ drivers/phy/Makefile | 1 + drivers/phy/phy-lpc18xx-usb-otg.c | 143 +++++++++++++++++++++ 4 files changed, 181 insertions(+) create mode 100644 Documentation/devicetree/bindings/phy/phy-lpc18xx-usb-otg.txt create mode 100644 drivers/phy/phy-lpc18xx-usb-otg.c
Signature · 1 line
1.8.0
PATCH v4 1/2 phy: add lpc18xx usb otg phy driver
Add PHY driver for the internal USB OTG PHY found on NXP LPC18xx and LPC43xx devices. This driver takes care of enabling the PHY in CREG (syscon) and setting the required clock frequency.
--- drivers/phy/Kconfig | 11 +++ drivers/phy/Makefile | 1 + drivers/phy/phy-lpc18xx-usb-otg.c | 143 ++++++++++++++++++++++++++++++++++++++ 3 files changed, 155 insertions(+) create mode 100644 drivers/phy/phy-lpc18xx-usb-otg.c
drivers/phy/Kconfig +11 -0
@@ -54,6 +54,17 @@ config PHY_EXYNOS_MIPI_VIDEO Support for MIPI CSI-2 and MIPI DSI DPHY found on Samsung S5P and EXYNOS SoCs. +config PHY_LPC18XX_USB_OTG + tristate "NXP LPC18xx/43xx SoC USB OTG PHY driver" + depends on OF && (ARCH_LPC18XX || COMPILE_TEST) + depends on MFD_SYSCON + select GENERIC_PHY + help + Enable this to support NXP LPC18xx/43xx internal USB OTG PHY. + + This driver is need for USB0 support on LPC18xx/43xx and takes + care of enabling and clock setup. + config PHY_PXA_28NM_HSIC tristate "Marvell USB HSIC 28nm PHY Driver" select GENERIC_PHY
drivers/phy/Makefile +1 -0
@@ -10,6 +10,7 @@ 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 obj-$(CONFIG_PHY_EXYNOS_MIPI_VIDEO) += phy-exynos-mipi-video.o +obj-$(CONFIG_PHY_LPC18XX_USB_OTG) += phy-lpc18xx-usb-otg.o obj-$(CONFIG_PHY_PXA_28NM_USB2) += phy-pxa-28nm-usb2.o obj-$(CONFIG_PHY_PXA_28NM_HSIC) += phy-pxa-28nm-hsic.o obj-$(CONFIG_PHY_MVEBU_SATA) += phy-mvebu-sata.o
drivers/phy/phy-lpc18xx-usb-otg.c new file +143 -0
143 lines not on this page · raw message
Signature · 1 line
1.8.0
PATCH v4 2/2 phy: dt bindings: add NXP LPC18xx/43xx USB OTG PHY bindings
In reply to Joachim EastwoodAdd binding documentation for NXP LPC18xx/43xx USB OTG PHY. This PHY can found on NXP LPC18xx and LPC43xx devices with USB support.
--- .../bindings/phy/phy-lpc18xx-usb-otg.txt | 26 ++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 Documentation/devicetree/bindings/phy/phy-lpc18xx-usb-otg.txt
Documentation/devicetree/bindings/phy/phy-lpc18xx-usb-otg.txt new file +26 -0
@@ -0,0 +1,26 @@ +NXP LPC18xx/43xx internal USB OTG PHY binding +--------------------------------------------- + +This file contains documentation for the internal USB OTG PHY found +in NXP LPC18xx and LPC43xx SoCs. + +Required properties: +- compatible : must be "nxp,lpc1850-usb-otg-phy" +- clocks : must be exactly one entry +See: Documentation/devicetree/bindings/clock/clock-bindings.txt +- #phy-cells : must be 0 for this phy +See: Documentation/devicetree/bindings/phy/phy-bindings.txt + +The phy node must be a child of the creg syscon node. + +Example: +creg: syscon at 40043000 { + compatible = "nxp,lpc1850-creg", "syscon", "simple-mfd"; + reg = <0x40043000 0x1000>; + + usb0_otg_phy: phy at 004 { + compatible = "nxp,lpc1850-usb-otg-phy"; + clocks = <&ccu1 CLK_USB0>; + #phy-cells = <0>; + }; +};
Signature · 1 line
1.8.0
v4 cover USB OTG PHY driver for NXP LPC18xx family
In reply to Joachim EastwoodQuoted 7 lines · Joachim Eastwood
This patch set adds support for the internal USB OTG PHY found on NXP LPC18xx and LPC43xx devices. Driver takes care of enabling the PHY and setting the clock rate which is need for USB0 support on this platform.
This version address moves the dt node under the creg syscon and rebases the patch set on 4.2-rc1.
merged this to linux-phy tree.
Cheers
Kishon
Quoted 25 lines
Changes in v4:
- rebase on 4.2-rc1
- move dt node under creg where the control reg isChanges in v3:
- depend onMFD_SYSCONChanges in v2:
- usePTR_ERR_OR_ZEROin phy driver
- rename binding doc
- update doc commit messageJoachim Eastwood (2):
phy: add lpc18xx usb otg phy driver
phy: dt bindings: add NXP LPC18xx/43xx USB OTG PHY bindings.../bindings/phy/phy-lpc18xx-usb-otg.txt | 26 ++++ drivers/phy/Kconfig | 11 ++ drivers/phy/Makefile | 1 + drivers/phy/phy-lpc18xx-usb-otg.c | 143 +++++++++++++++++++++ 4 files changed, 181 insertions(+) create mode 100644 Documentation/devicetree/bindings/phy/phy-lpc18xx-usb-otg.txt create mode 100644 drivers/phy/phy-lpc18xx-usb-otg.c
v4 cover USB OTG PHY driver for NXP LPC18xx family
Quoted 8 lines · Kishon Vijay Abraham I
Quoted 5 lines · Joachim Eastwood
This patch set adds support for the internal USB OTG PHY found on NXP LPC18xx and LPC43xx devices. Driver takes care of enabling the PHY and setting the clock rate which is need for USB0 support on this platform.
Quoted 4 lines
Quoted 2 lines
This version address moves the dt node under the creg syscon and rebases the patch set on 4.2-rc1.
merged this to linux-phy tree.
Thanks, Kishon.
regards,
Joachim Eastwood