All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/3]  Add picoPHY usb phy driver found on stih407 family SoC's
@ 2014-09-03 10:27 ` Peter Griffin
  0 siblings, 0 replies; 23+ messages in thread
From: Peter Griffin @ 2014-09-03 10:27 UTC (permalink / raw)
  To: linux-arm-kernel, linux-kernel, srinivas.kandagatla,
	maxime.coquelin, patrice.chotard, kishon
  Cc: peter.griffin, lee.jones, devicetree

This series adds support for the picoPHY usb phy which is used by the usb2
and usb3 host controllers when controlling usb2/1.1 devices. It is found on
stih407 family SoC's from the consumer electronics devision of STMicroelectronics.

Peter Griffin (3):
  phy: phy-stih407-usb: Add usb picoPHY driver found on stih407 SoC
    family
  phy: phy-stih407-usb: Add dt documentation for USB picophy found on
    stih407 SoC family
  MAINTAINERS: Add phy-stih407-usb.c file to ARCH/STI architecture

 .../devicetree/bindings/phy/phy-stih407-usb.txt    |  37 +++++
 MAINTAINERS                                        |   1 +
 drivers/phy/Kconfig                                |   8 +
 drivers/phy/Makefile                               |   2 +
 drivers/phy/phy-stih407-usb.c                      | 185 +++++++++++++++++++++
 5 files changed, 233 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
 create mode 100644 drivers/phy/phy-stih407-usb.c

-- 
1.9.1


^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH 0/3]  Add picoPHY usb phy driver found on stih407 family SoC's
@ 2014-09-03 10:27 ` Peter Griffin
  0 siblings, 0 replies; 23+ messages in thread
From: Peter Griffin @ 2014-09-03 10:27 UTC (permalink / raw)
  To: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	srinivas.kandagatla-Re5JQEeQqe8AvxtiuMwx3w,
	maxime.coquelin-qxv4g6HH51o, patrice.chotard-qxv4g6HH51o,
	kishon-l0cyMroinI0
  Cc: peter.griffin-QSEj5FYQhm4dnm+yROfE0A,
	lee.jones-QSEj5FYQhm4dnm+yROfE0A,
	devicetree-u79uwXL29TY76Z2rM5mHXA

This series adds support for the picoPHY usb phy which is used by the usb2
and usb3 host controllers when controlling usb2/1.1 devices. It is found on
stih407 family SoC's from the consumer electronics devision of STMicroelectronics.

Peter Griffin (3):
  phy: phy-stih407-usb: Add usb picoPHY driver found on stih407 SoC
    family
  phy: phy-stih407-usb: Add dt documentation for USB picophy found on
    stih407 SoC family
  MAINTAINERS: Add phy-stih407-usb.c file to ARCH/STI architecture

 .../devicetree/bindings/phy/phy-stih407-usb.txt    |  37 +++++
 MAINTAINERS                                        |   1 +
 drivers/phy/Kconfig                                |   8 +
 drivers/phy/Makefile                               |   2 +
 drivers/phy/phy-stih407-usb.c                      | 185 +++++++++++++++++++++
 5 files changed, 233 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
 create mode 100644 drivers/phy/phy-stih407-usb.c

-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH 0/3] Add picoPHY usb phy driver found on stih407 family SoC's
@ 2014-09-03 10:27 ` Peter Griffin
  0 siblings, 0 replies; 23+ messages in thread
From: Peter Griffin @ 2014-09-03 10:27 UTC (permalink / raw)
  To: linux-arm-kernel

This series adds support for the picoPHY usb phy which is used by the usb2
and usb3 host controllers when controlling usb2/1.1 devices. It is found on
stih407 family SoC's from the consumer electronics devision of STMicroelectronics.

Peter Griffin (3):
  phy: phy-stih407-usb: Add usb picoPHY driver found on stih407 SoC
    family
  phy: phy-stih407-usb: Add dt documentation for USB picophy found on
    stih407 SoC family
  MAINTAINERS: Add phy-stih407-usb.c file to ARCH/STI architecture

 .../devicetree/bindings/phy/phy-stih407-usb.txt    |  37 +++++
 MAINTAINERS                                        |   1 +
 drivers/phy/Kconfig                                |   8 +
 drivers/phy/Makefile                               |   2 +
 drivers/phy/phy-stih407-usb.c                      | 185 +++++++++++++++++++++
 5 files changed, 233 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
 create mode 100644 drivers/phy/phy-stih407-usb.c

-- 
1.9.1

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH 1/3] phy: phy-stih407-usb: Add usb picoPHY driver found on stih407 SoC family
  2014-09-03 10:27 ` Peter Griffin
@ 2014-09-03 10:27   ` Peter Griffin
  -1 siblings, 0 replies; 23+ messages in thread
From: Peter Griffin @ 2014-09-03 10:27 UTC (permalink / raw)
  To: linux-arm-kernel, linux-kernel, srinivas.kandagatla,
	maxime.coquelin, patrice.chotard, kishon
  Cc: peter.griffin, lee.jones, devicetree, Giuseppe Cavallaro

This is the generic phy driver for the picoPHY ports used by the
USB2 and USB3 Host controllers available on STiH407 consumer electronic
SoC families available from STMicroelectronics.

Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com>
Signed-off-by: Peter Griffin <peter.griffin@linaro.org>
---
 drivers/phy/Kconfig           |   8 ++
 drivers/phy/Makefile          |   2 +
 drivers/phy/phy-stih407-usb.c | 185 ++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 195 insertions(+)
 create mode 100644 drivers/phy/phy-stih407-usb.c

diff --git a/drivers/phy/Kconfig b/drivers/phy/Kconfig
index 0dd7427..58018f7 100644
--- a/drivers/phy/Kconfig
+++ b/drivers/phy/Kconfig
@@ -230,4 +230,12 @@ config PHY_XGENE
 	help
 	  This option enables support for APM X-Gene SoC multi-purpose PHY.
 
+config PHY_STIH407_USB
+	tristate "STMicroelectronics USB2 picoPHY driver for STiH407 family"
+	depends on ARCH_STI
+	depends on GENERIC_PHY
+	help
+	  Enable this support to enable the picoPHY device used by USB2
+	  and USB3 controllers on STMicroelectronics STiH407 SoC families.
+
 endmenu
diff --git a/drivers/phy/Makefile b/drivers/phy/Makefile
index 95c69ed..c82ac59 100644
--- a/drivers/phy/Makefile
+++ b/drivers/phy/Makefile
@@ -28,3 +28,5 @@ obj-$(CONFIG_PHY_QCOM_IPQ806X_SATA)	+= phy-qcom-ipq806x-sata.o
 obj-$(CONFIG_PHY_ST_SPEAR1310_MIPHY)	+= phy-spear1310-miphy.o
 obj-$(CONFIG_PHY_ST_SPEAR1340_MIPHY)	+= phy-spear1340-miphy.o
 obj-$(CONFIG_PHY_XGENE)			+= phy-xgene.o
+obj-$(CONFIG_PHY_STIH407_USB)		+= phy-stih407-usb.o
+
diff --git a/drivers/phy/phy-stih407-usb.c b/drivers/phy/phy-stih407-usb.c
new file mode 100644
index 0000000..8019e3b
--- /dev/null
+++ b/drivers/phy/phy-stih407-usb.c
@@ -0,0 +1,185 @@
+/*
+ * Copyright (C) 2014 STMicroelectronics
+ *
+ * STMicroelectronics Generic PHY driver for STiH407 USB2.
+ *
+ * Author: Giuseppe Cavallaro <peppe.cavallaro@st.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2, as
+ * published by the Free Software Foundation.
+ *
+ */
+#include <linux/platform_device.h>
+#include <linux/io.h>
+#include <linux/kernel.h>
+#include <linux/module.h>
+#include <linux/of.h>
+#include <linux/of_platform.h>
+#include <linux/clk.h>
+#include <linux/regmap.h>
+#include <linux/reset.h>
+#include <linux/mfd/syscon.h>
+#include <linux/phy/phy.h>
+
+/* Default PHY_SEL and REFCLKSEL configuration */
+#define STIH407_USB_PICOPHY_CTRL_PORT_CONF	0x6
+#define STIH407_USB_PICOPHY_CTRL_PORT_MASK	0x1f
+
+/* ports parameters overriding */
+#define STIH407_USB_PICOPHY_PARAM_DEF		0x39a4dc
+#define STIH407_USB_PICOPHY_PARAM_MASK		0xffffffff
+
+struct stih407_usb2_picophy {
+	struct phy *phy;
+	struct regmap *regmap;
+	struct device *dev;
+	struct reset_control *rstc;
+	struct reset_control *rstport;
+	int ctrl;
+	int param;
+};
+
+static int stih407_usb2_pico_ctrl(struct stih407_usb2_picophy *phy_dev)
+{
+	reset_control_deassert(phy_dev->rstc);
+
+	return regmap_update_bits(phy_dev->regmap, phy_dev->ctrl,
+				  STIH407_USB_PICOPHY_CTRL_PORT_MASK,
+				  STIH407_USB_PICOPHY_CTRL_PORT_CONF);
+}
+
+static int stih407_usb2_init_port(struct phy *phy)
+{
+	int ret;
+	struct stih407_usb2_picophy *phy_dev = phy_get_drvdata(phy);
+
+	stih407_usb2_pico_ctrl(phy_dev);
+
+	ret = regmap_update_bits(phy_dev->regmap,
+				 phy_dev->param,
+				 STIH407_USB_PICOPHY_PARAM_MASK,
+				 STIH407_USB_PICOPHY_PARAM_DEF);
+	if (ret)
+		return ret;
+
+	return reset_control_deassert(phy_dev->rstport);
+}
+
+static int stih407_usb2_exit_port(struct phy *phy)
+{
+	struct stih407_usb2_picophy *phy_dev = phy_get_drvdata(phy);
+
+	/*
+	 * Only port reset is asserted, phy global reset is kept untouched
+	 * as other ports may still be active. When all ports are in reset
+	 * state, assumption is made that power will be cut off on the phy, in
+	 * case of suspend for instance. Theoretically, asserting individual
+	 * reset (like here) or global reset should be equivalent.
+	 */
+	return reset_control_assert(phy_dev->rstport);
+}
+
+static const struct phy_ops stih407_usb2_picophy_data = {
+	.init = stih407_usb2_init_port,
+	.exit = stih407_usb2_exit_port,
+	.owner = THIS_MODULE,
+};
+
+static const struct of_device_id stih407_usb2_picophy_of_match[];
+
+static int stih407_usb2_picophy_probe(struct platform_device *pdev)
+{
+	const struct of_device_id *match;
+	struct stih407_usb2_picophy *phy_dev;
+	struct device *dev = &pdev->dev;
+	struct device_node *np = dev->of_node;
+	struct phy_provider *phy_provider;
+	struct phy *phy;
+	struct resource *res;
+
+	phy_dev = devm_kzalloc(dev, sizeof(*phy_dev), GFP_KERNEL);
+	if (!phy_dev)
+		return -ENOMEM;
+
+	match = of_match_device(stih407_usb2_picophy_of_match, dev);
+	if (!match)
+		return -ENODEV;
+
+	phy_dev->dev = dev;
+	dev_set_drvdata(dev, phy_dev);
+
+	phy_dev->rstc = devm_reset_control_get(dev, "global");
+	if (IS_ERR(phy_dev->rstc)) {
+		dev_err(dev, "failed to ctrl picoPHY reset\n");
+		return PTR_ERR(phy_dev->rstc);
+	}
+
+	phy_dev->rstport = devm_reset_control_get(dev, "port");
+	if (IS_ERR(phy_dev->rstport)) {
+		dev_err(dev, "failed to ctrl picoPHY reset\n");
+		return PTR_ERR(phy_dev->rstport);
+	}
+
+	/* Reset port by default: only deassert it in phy init */
+	reset_control_assert(phy_dev->rstport);
+
+	phy_dev->regmap = syscon_regmap_lookup_by_phandle(np, "st,syscfg");
+	if (IS_ERR(phy_dev->regmap)) {
+		dev_err(dev, "No syscfg phandle specified\n");
+		return PTR_ERR(phy_dev->regmap);
+	}
+
+	res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "ctrl");
+	if (!res) {
+		dev_err(dev, "No ctrl reg found\n");
+		return -ENXIO;
+	}
+	phy_dev->ctrl = res->start;
+
+	res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "param");
+	if (!res) {
+		dev_err(dev, "No param reg found\n");
+		return -ENXIO;
+	}
+	phy_dev->param = res->start;
+
+	phy = devm_phy_create(dev, NULL, match->data, NULL);
+	if (IS_ERR(phy)) {
+		dev_err(dev, "failed to create Display Port PHY\n");
+		return PTR_ERR(phy);
+	}
+
+	phy_dev->phy = phy;
+	phy_set_drvdata(phy, phy_dev);
+
+	phy_provider = devm_of_phy_provider_register(dev, of_phy_simple_xlate);
+	if (IS_ERR(phy_provider))
+		return PTR_ERR(phy_provider);
+
+	dev_info(dev, "STiH407 USB Generic picoPHY driver probed!");
+
+	return 0;
+}
+
+static const struct of_device_id stih407_usb2_picophy_of_match[] = {
+	{ .compatible = "st,stih407-usb2-phy",
+	  .data = &stih407_usb2_picophy_data },
+	{ /*sentinel */ },
+};
+
+MODULE_DEVICE_TABLE(of, stih407_usb2_picophy_of_match);
+
+static struct platform_driver stih407_usb2_picophy_driver = {
+	.probe = stih407_usb2_picophy_probe,
+	.driver = {
+		   .name = "stih407-usb-genphy",
+		   .of_match_table = stih407_usb2_picophy_of_match,
+		   }
+};
+
+module_platform_driver(stih407_usb2_picophy_driver);
+
+MODULE_AUTHOR("Giuseppe Cavallaro <peppe.cavallaro@st.com>");
+MODULE_DESCRIPTION("STMicroelectronics Generic picoPHY driver for STiH407");
+MODULE_LICENSE("GPL v2");
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH 1/3] phy: phy-stih407-usb: Add usb picoPHY driver found on stih407 SoC family
@ 2014-09-03 10:27   ` Peter Griffin
  0 siblings, 0 replies; 23+ messages in thread
From: Peter Griffin @ 2014-09-03 10:27 UTC (permalink / raw)
  To: linux-arm-kernel

This is the generic phy driver for the picoPHY ports used by the
USB2 and USB3 Host controllers available on STiH407 consumer electronic
SoC families available from STMicroelectronics.

Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com>
Signed-off-by: Peter Griffin <peter.griffin@linaro.org>
---
 drivers/phy/Kconfig           |   8 ++
 drivers/phy/Makefile          |   2 +
 drivers/phy/phy-stih407-usb.c | 185 ++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 195 insertions(+)
 create mode 100644 drivers/phy/phy-stih407-usb.c

diff --git a/drivers/phy/Kconfig b/drivers/phy/Kconfig
index 0dd7427..58018f7 100644
--- a/drivers/phy/Kconfig
+++ b/drivers/phy/Kconfig
@@ -230,4 +230,12 @@ config PHY_XGENE
 	help
 	  This option enables support for APM X-Gene SoC multi-purpose PHY.
 
+config PHY_STIH407_USB
+	tristate "STMicroelectronics USB2 picoPHY driver for STiH407 family"
+	depends on ARCH_STI
+	depends on GENERIC_PHY
+	help
+	  Enable this support to enable the picoPHY device used by USB2
+	  and USB3 controllers on STMicroelectronics STiH407 SoC families.
+
 endmenu
diff --git a/drivers/phy/Makefile b/drivers/phy/Makefile
index 95c69ed..c82ac59 100644
--- a/drivers/phy/Makefile
+++ b/drivers/phy/Makefile
@@ -28,3 +28,5 @@ obj-$(CONFIG_PHY_QCOM_IPQ806X_SATA)	+= phy-qcom-ipq806x-sata.o
 obj-$(CONFIG_PHY_ST_SPEAR1310_MIPHY)	+= phy-spear1310-miphy.o
 obj-$(CONFIG_PHY_ST_SPEAR1340_MIPHY)	+= phy-spear1340-miphy.o
 obj-$(CONFIG_PHY_XGENE)			+= phy-xgene.o
+obj-$(CONFIG_PHY_STIH407_USB)		+= phy-stih407-usb.o
+
diff --git a/drivers/phy/phy-stih407-usb.c b/drivers/phy/phy-stih407-usb.c
new file mode 100644
index 0000000..8019e3b
--- /dev/null
+++ b/drivers/phy/phy-stih407-usb.c
@@ -0,0 +1,185 @@
+/*
+ * Copyright (C) 2014 STMicroelectronics
+ *
+ * STMicroelectronics Generic PHY driver for STiH407 USB2.
+ *
+ * Author: Giuseppe Cavallaro <peppe.cavallaro@st.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2, as
+ * published by the Free Software Foundation.
+ *
+ */
+#include <linux/platform_device.h>
+#include <linux/io.h>
+#include <linux/kernel.h>
+#include <linux/module.h>
+#include <linux/of.h>
+#include <linux/of_platform.h>
+#include <linux/clk.h>
+#include <linux/regmap.h>
+#include <linux/reset.h>
+#include <linux/mfd/syscon.h>
+#include <linux/phy/phy.h>
+
+/* Default PHY_SEL and REFCLKSEL configuration */
+#define STIH407_USB_PICOPHY_CTRL_PORT_CONF	0x6
+#define STIH407_USB_PICOPHY_CTRL_PORT_MASK	0x1f
+
+/* ports parameters overriding */
+#define STIH407_USB_PICOPHY_PARAM_DEF		0x39a4dc
+#define STIH407_USB_PICOPHY_PARAM_MASK		0xffffffff
+
+struct stih407_usb2_picophy {
+	struct phy *phy;
+	struct regmap *regmap;
+	struct device *dev;
+	struct reset_control *rstc;
+	struct reset_control *rstport;
+	int ctrl;
+	int param;
+};
+
+static int stih407_usb2_pico_ctrl(struct stih407_usb2_picophy *phy_dev)
+{
+	reset_control_deassert(phy_dev->rstc);
+
+	return regmap_update_bits(phy_dev->regmap, phy_dev->ctrl,
+				  STIH407_USB_PICOPHY_CTRL_PORT_MASK,
+				  STIH407_USB_PICOPHY_CTRL_PORT_CONF);
+}
+
+static int stih407_usb2_init_port(struct phy *phy)
+{
+	int ret;
+	struct stih407_usb2_picophy *phy_dev = phy_get_drvdata(phy);
+
+	stih407_usb2_pico_ctrl(phy_dev);
+
+	ret = regmap_update_bits(phy_dev->regmap,
+				 phy_dev->param,
+				 STIH407_USB_PICOPHY_PARAM_MASK,
+				 STIH407_USB_PICOPHY_PARAM_DEF);
+	if (ret)
+		return ret;
+
+	return reset_control_deassert(phy_dev->rstport);
+}
+
+static int stih407_usb2_exit_port(struct phy *phy)
+{
+	struct stih407_usb2_picophy *phy_dev = phy_get_drvdata(phy);
+
+	/*
+	 * Only port reset is asserted, phy global reset is kept untouched
+	 * as other ports may still be active. When all ports are in reset
+	 * state, assumption is made that power will be cut off on the phy, in
+	 * case of suspend for instance. Theoretically, asserting individual
+	 * reset (like here) or global reset should be equivalent.
+	 */
+	return reset_control_assert(phy_dev->rstport);
+}
+
+static const struct phy_ops stih407_usb2_picophy_data = {
+	.init = stih407_usb2_init_port,
+	.exit = stih407_usb2_exit_port,
+	.owner = THIS_MODULE,
+};
+
+static const struct of_device_id stih407_usb2_picophy_of_match[];
+
+static int stih407_usb2_picophy_probe(struct platform_device *pdev)
+{
+	const struct of_device_id *match;
+	struct stih407_usb2_picophy *phy_dev;
+	struct device *dev = &pdev->dev;
+	struct device_node *np = dev->of_node;
+	struct phy_provider *phy_provider;
+	struct phy *phy;
+	struct resource *res;
+
+	phy_dev = devm_kzalloc(dev, sizeof(*phy_dev), GFP_KERNEL);
+	if (!phy_dev)
+		return -ENOMEM;
+
+	match = of_match_device(stih407_usb2_picophy_of_match, dev);
+	if (!match)
+		return -ENODEV;
+
+	phy_dev->dev = dev;
+	dev_set_drvdata(dev, phy_dev);
+
+	phy_dev->rstc = devm_reset_control_get(dev, "global");
+	if (IS_ERR(phy_dev->rstc)) {
+		dev_err(dev, "failed to ctrl picoPHY reset\n");
+		return PTR_ERR(phy_dev->rstc);
+	}
+
+	phy_dev->rstport = devm_reset_control_get(dev, "port");
+	if (IS_ERR(phy_dev->rstport)) {
+		dev_err(dev, "failed to ctrl picoPHY reset\n");
+		return PTR_ERR(phy_dev->rstport);
+	}
+
+	/* Reset port by default: only deassert it in phy init */
+	reset_control_assert(phy_dev->rstport);
+
+	phy_dev->regmap = syscon_regmap_lookup_by_phandle(np, "st,syscfg");
+	if (IS_ERR(phy_dev->regmap)) {
+		dev_err(dev, "No syscfg phandle specified\n");
+		return PTR_ERR(phy_dev->regmap);
+	}
+
+	res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "ctrl");
+	if (!res) {
+		dev_err(dev, "No ctrl reg found\n");
+		return -ENXIO;
+	}
+	phy_dev->ctrl = res->start;
+
+	res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "param");
+	if (!res) {
+		dev_err(dev, "No param reg found\n");
+		return -ENXIO;
+	}
+	phy_dev->param = res->start;
+
+	phy = devm_phy_create(dev, NULL, match->data, NULL);
+	if (IS_ERR(phy)) {
+		dev_err(dev, "failed to create Display Port PHY\n");
+		return PTR_ERR(phy);
+	}
+
+	phy_dev->phy = phy;
+	phy_set_drvdata(phy, phy_dev);
+
+	phy_provider = devm_of_phy_provider_register(dev, of_phy_simple_xlate);
+	if (IS_ERR(phy_provider))
+		return PTR_ERR(phy_provider);
+
+	dev_info(dev, "STiH407 USB Generic picoPHY driver probed!");
+
+	return 0;
+}
+
+static const struct of_device_id stih407_usb2_picophy_of_match[] = {
+	{ .compatible = "st,stih407-usb2-phy",
+	  .data = &stih407_usb2_picophy_data },
+	{ /*sentinel */ },
+};
+
+MODULE_DEVICE_TABLE(of, stih407_usb2_picophy_of_match);
+
+static struct platform_driver stih407_usb2_picophy_driver = {
+	.probe = stih407_usb2_picophy_probe,
+	.driver = {
+		   .name = "stih407-usb-genphy",
+		   .of_match_table = stih407_usb2_picophy_of_match,
+		   }
+};
+
+module_platform_driver(stih407_usb2_picophy_driver);
+
+MODULE_AUTHOR("Giuseppe Cavallaro <peppe.cavallaro@st.com>");
+MODULE_DESCRIPTION("STMicroelectronics Generic picoPHY driver for STiH407");
+MODULE_LICENSE("GPL v2");
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH 2/3] phy: phy-stih407-usb: Add dt documentation for USB picophy found on stih407 SoC family
  2014-09-03 10:27 ` Peter Griffin
@ 2014-09-03 10:27   ` Peter Griffin
  -1 siblings, 0 replies; 23+ messages in thread
From: Peter Griffin @ 2014-09-03 10:27 UTC (permalink / raw)
  To: linux-arm-kernel, linux-kernel, srinivas.kandagatla,
	maxime.coquelin, patrice.chotard, kishon
  Cc: peter.griffin, lee.jones, devicetree, Giuseppe Cavallaro

This patch adds the dt documentation for the usb picophy found on stih407 SoC family
available from STMicroelectronics.

Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com>
Signed-off-by: Peter Griffin <peter.griffin@linaro.org>
---
 .../devicetree/bindings/phy/phy-stih407-usb.txt    | 37 ++++++++++++++++++++++
 1 file changed, 37 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/phy/phy-stih407-usb.txt

diff --git a/Documentation/devicetree/bindings/phy/phy-stih407-usb.txt b/Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
new file mode 100644
index 0000000..650d346
--- /dev/null
+++ b/Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
@@ -0,0 +1,37 @@
+ST STiH407 USB-PHY controller
+
+This file documents the dt bindings for the picoPHY driver which is the PHY for both USB2 and USB3 host controllers
+controllers available on STiH407 SoC families.
+
+On STiH410, we have to use the DWC3 port#2 with a picoPHY to manage USB2
+devices. The USB2 Controller will use the ports #0 and #1.
+
+This is to document the DT parameters to be passed from the blob in that case.
+
+Required properties:
+- compatible		: should be "st,stih407-usb2-phy"
+- reg			: contain the offset and length of the system configuration registers
+			  used as glue logic to control & parameter phy
+- reg-names		: the names of the system configuration registers in "reg", should be "param" and "reg"
+- st,syscfg		: sysconfig register to manage phy parameter at driver level
+- resets		: list of phandle and reset specifier pairs. There should be two entries, one
+			  for the whole phy and one for the port
+- reset-names		: list of reset signal names. Should be "global" and "port"
+See: Documentation/devicetree/bindings/reset/st,sti-powerdown.txt
+See: Documentation/devicetree/bindings/reset/reset.txt
+
+Example:
+
+usb2_picophy0: usbpicophy@0 {
+	compatible	= "st,stih407-usb2-phy";
+	reg		= <0xf8 0x04>,	/* syscfg 5062 */
+			  <0xf4 0x04>;	/* syscfg 5061 */
+	reg-names	= "param",
+			  "ctrl";
+			  #phy-cells = <0>;
+	st,syscfg	= <&syscfg_core>;
+	resets		= <&softreset STIH407_PICOPHY_SOFTRESET>,
+			  <&picophyreset STIH407_PICOPHY0_RESET>;
+	reset-names	= "global",
+			  "port";
+};
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH 2/3] phy: phy-stih407-usb: Add dt documentation for USB picophy found on stih407 SoC family
@ 2014-09-03 10:27   ` Peter Griffin
  0 siblings, 0 replies; 23+ messages in thread
From: Peter Griffin @ 2014-09-03 10:27 UTC (permalink / raw)
  To: linux-arm-kernel

This patch adds the dt documentation for the usb picophy found on stih407 SoC family
available from STMicroelectronics.

Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com>
Signed-off-by: Peter Griffin <peter.griffin@linaro.org>
---
 .../devicetree/bindings/phy/phy-stih407-usb.txt    | 37 ++++++++++++++++++++++
 1 file changed, 37 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/phy/phy-stih407-usb.txt

diff --git a/Documentation/devicetree/bindings/phy/phy-stih407-usb.txt b/Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
new file mode 100644
index 0000000..650d346
--- /dev/null
+++ b/Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
@@ -0,0 +1,37 @@
+ST STiH407 USB-PHY controller
+
+This file documents the dt bindings for the picoPHY driver which is the PHY for both USB2 and USB3 host controllers
+controllers available on STiH407 SoC families.
+
+On STiH410, we have to use the DWC3 port#2 with a picoPHY to manage USB2
+devices. The USB2 Controller will use the ports #0 and #1.
+
+This is to document the DT parameters to be passed from the blob in that case.
+
+Required properties:
+- compatible		: should be "st,stih407-usb2-phy"
+- reg			: contain the offset and length of the system configuration registers
+			  used as glue logic to control & parameter phy
+- reg-names		: the names of the system configuration registers in "reg", should be "param" and "reg"
+- st,syscfg		: sysconfig register to manage phy parameter at driver level
+- resets		: list of phandle and reset specifier pairs. There should be two entries, one
+			  for the whole phy and one for the port
+- reset-names		: list of reset signal names. Should be "global" and "port"
+See: Documentation/devicetree/bindings/reset/st,sti-powerdown.txt
+See: Documentation/devicetree/bindings/reset/reset.txt
+
+Example:
+
+usb2_picophy0: usbpicophy at 0 {
+	compatible	= "st,stih407-usb2-phy";
+	reg		= <0xf8 0x04>,	/* syscfg 5062 */
+			  <0xf4 0x04>;	/* syscfg 5061 */
+	reg-names	= "param",
+			  "ctrl";
+			  #phy-cells = <0>;
+	st,syscfg	= <&syscfg_core>;
+	resets		= <&softreset STIH407_PICOPHY_SOFTRESET>,
+			  <&picophyreset STIH407_PICOPHY0_RESET>;
+	reset-names	= "global",
+			  "port";
+};
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH 3/3] MAINTAINERS: Add phy-stih407-usb.c file to ARCH/STI architecture
  2014-09-03 10:27 ` Peter Griffin
@ 2014-09-03 10:27   ` Peter Griffin
  -1 siblings, 0 replies; 23+ messages in thread
From: Peter Griffin @ 2014-09-03 10:27 UTC (permalink / raw)
  To: linux-arm-kernel, linux-kernel, srinivas.kandagatla,
	maxime.coquelin, patrice.chotard, kishon
  Cc: peter.griffin, lee.jones, devicetree

This patch adds the new phy-stih407-usb.c usb phy driver found on
STMicroelectronics stih407 consumer electronics SoC's into the STI
arch section of the maintainers file.

Signed-off-by: Peter Griffin <peter.griffin@linaro.org>
---
 MAINTAINERS | 1 +
 1 file changed, 1 insertion(+)

diff --git a/MAINTAINERS b/MAINTAINERS
index 55381955..0d0818a 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -1399,6 +1399,7 @@ F:	drivers/i2c/busses/i2c-st.c
 F:	drivers/tty/serial/st-asc.c
 F:	drivers/mmc/host/sdhci-st.c
 F:	drivers/usb/dwc3/dwc3-st.c
+F:	drivers/phy/phy-stih407-usb.c
 
 ARM/TECHNOLOGIC SYSTEMS TS7250 MACHINE SUPPORT
 M:	Lennert Buytenhek <kernel@wantstofly.org>
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH 3/3] MAINTAINERS: Add phy-stih407-usb.c file to ARCH/STI architecture
@ 2014-09-03 10:27   ` Peter Griffin
  0 siblings, 0 replies; 23+ messages in thread
From: Peter Griffin @ 2014-09-03 10:27 UTC (permalink / raw)
  To: linux-arm-kernel

This patch adds the new phy-stih407-usb.c usb phy driver found on
STMicroelectronics stih407 consumer electronics SoC's into the STI
arch section of the maintainers file.

Signed-off-by: Peter Griffin <peter.griffin@linaro.org>
---
 MAINTAINERS | 1 +
 1 file changed, 1 insertion(+)

diff --git a/MAINTAINERS b/MAINTAINERS
index 55381955..0d0818a 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -1399,6 +1399,7 @@ F:	drivers/i2c/busses/i2c-st.c
 F:	drivers/tty/serial/st-asc.c
 F:	drivers/mmc/host/sdhci-st.c
 F:	drivers/usb/dwc3/dwc3-st.c
+F:	drivers/phy/phy-stih407-usb.c
 
 ARM/TECHNOLOGIC SYSTEMS TS7250 MACHINE SUPPORT
 M:	Lennert Buytenhek <kernel@wantstofly.org>
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 23+ messages in thread

* Re: [PATCH 0/3]  Add picoPHY usb phy driver found on stih407 family SoC's
  2014-09-03 10:27 ` Peter Griffin
  (?)
@ 2014-09-08 15:23   ` Kishon Vijay Abraham I
  -1 siblings, 0 replies; 23+ messages in thread
From: Kishon Vijay Abraham I @ 2014-09-08 15:23 UTC (permalink / raw)
  To: Peter Griffin, linux-arm-kernel, linux-kernel,
	srinivas.kandagatla, maxime.coquelin, patrice.chotard
  Cc: lee.jones, devicetree

Hi,

On Wednesday 03 September 2014 03:57 PM, Peter Griffin wrote:
> This series adds support for the picoPHY usb phy which is used by the usb2
> and usb3 host controllers when controlling usb2/1.1 devices. It is found on
> stih407 family SoC's from the consumer electronics devision of STMicroelectronics.

So miphy28lp is the PHY controller for USB3 device controller and picoPHY is
the PHY controller for USB3 host controller?

Thanks
Kishon

> 
> Peter Griffin (3):
>   phy: phy-stih407-usb: Add usb picoPHY driver found on stih407 SoC
>     family
>   phy: phy-stih407-usb: Add dt documentation for USB picophy found on
>     stih407 SoC family
>   MAINTAINERS: Add phy-stih407-usb.c file to ARCH/STI architecture
> 
>  .../devicetree/bindings/phy/phy-stih407-usb.txt    |  37 +++++
>  MAINTAINERS                                        |   1 +
>  drivers/phy/Kconfig                                |   8 +
>  drivers/phy/Makefile                               |   2 +
>  drivers/phy/phy-stih407-usb.c                      | 185 +++++++++++++++++++++
>  5 files changed, 233 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
>  create mode 100644 drivers/phy/phy-stih407-usb.c
> 

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH 0/3]  Add picoPHY usb phy driver found on stih407 family SoC's
@ 2014-09-08 15:23   ` Kishon Vijay Abraham I
  0 siblings, 0 replies; 23+ messages in thread
From: Kishon Vijay Abraham I @ 2014-09-08 15:23 UTC (permalink / raw)
  To: Peter Griffin, linux-arm-kernel, linux-kernel,
	srinivas.kandagatla, maxime.coquelin, patrice.chotard
  Cc: lee.jones, devicetree

Hi,

On Wednesday 03 September 2014 03:57 PM, Peter Griffin wrote:
> This series adds support for the picoPHY usb phy which is used by the usb2
> and usb3 host controllers when controlling usb2/1.1 devices. It is found on
> stih407 family SoC's from the consumer electronics devision of STMicroelectronics.

So miphy28lp is the PHY controller for USB3 device controller and picoPHY is
the PHY controller for USB3 host controller?

Thanks
Kishon

> 
> Peter Griffin (3):
>   phy: phy-stih407-usb: Add usb picoPHY driver found on stih407 SoC
>     family
>   phy: phy-stih407-usb: Add dt documentation for USB picophy found on
>     stih407 SoC family
>   MAINTAINERS: Add phy-stih407-usb.c file to ARCH/STI architecture
> 
>  .../devicetree/bindings/phy/phy-stih407-usb.txt    |  37 +++++
>  MAINTAINERS                                        |   1 +
>  drivers/phy/Kconfig                                |   8 +
>  drivers/phy/Makefile                               |   2 +
>  drivers/phy/phy-stih407-usb.c                      | 185 +++++++++++++++++++++
>  5 files changed, 233 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
>  create mode 100644 drivers/phy/phy-stih407-usb.c
> 

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH 0/3]  Add picoPHY usb phy driver found on stih407 family SoC's
@ 2014-09-08 15:23   ` Kishon Vijay Abraham I
  0 siblings, 0 replies; 23+ messages in thread
From: Kishon Vijay Abraham I @ 2014-09-08 15:23 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

On Wednesday 03 September 2014 03:57 PM, Peter Griffin wrote:
> This series adds support for the picoPHY usb phy which is used by the usb2
> and usb3 host controllers when controlling usb2/1.1 devices. It is found on
> stih407 family SoC's from the consumer electronics devision of STMicroelectronics.

So miphy28lp is the PHY controller for USB3 device controller and picoPHY is
the PHY controller for USB3 host controller?

Thanks
Kishon

> 
> Peter Griffin (3):
>   phy: phy-stih407-usb: Add usb picoPHY driver found on stih407 SoC
>     family
>   phy: phy-stih407-usb: Add dt documentation for USB picophy found on
>     stih407 SoC family
>   MAINTAINERS: Add phy-stih407-usb.c file to ARCH/STI architecture
> 
>  .../devicetree/bindings/phy/phy-stih407-usb.txt    |  37 +++++
>  MAINTAINERS                                        |   1 +
>  drivers/phy/Kconfig                                |   8 +
>  drivers/phy/Makefile                               |   2 +
>  drivers/phy/phy-stih407-usb.c                      | 185 +++++++++++++++++++++
>  5 files changed, 233 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
>  create mode 100644 drivers/phy/phy-stih407-usb.c
> 

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH 2/3] phy: phy-stih407-usb: Add dt documentation for USB picophy found on stih407 SoC family
  2014-09-03 10:27   ` Peter Griffin
  (?)
@ 2014-09-08 15:30     ` Kishon Vijay Abraham I
  -1 siblings, 0 replies; 23+ messages in thread
From: Kishon Vijay Abraham I @ 2014-09-08 15:30 UTC (permalink / raw)
  To: Peter Griffin, linux-arm-kernel, linux-kernel,
	srinivas.kandagatla, maxime.coquelin, patrice.chotard
  Cc: lee.jones, devicetree, Giuseppe Cavallaro

Hi,

On Wednesday 03 September 2014 03:57 PM, Peter Griffin wrote:
> This patch adds the dt documentation for the usb picophy found on stih407 SoC family
> available from STMicroelectronics.
> 
> Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com>
> Signed-off-by: Peter Griffin <peter.griffin@linaro.org>
> ---
>  .../devicetree/bindings/phy/phy-stih407-usb.txt    | 37 ++++++++++++++++++++++
>  1 file changed, 37 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
> 
> diff --git a/Documentation/devicetree/bindings/phy/phy-stih407-usb.txt b/Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
> new file mode 100644
> index 0000000..650d346
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
> @@ -0,0 +1,37 @@
> +ST STiH407 USB-PHY controller
> +
> +This file documents the dt bindings for the picoPHY driver which is the PHY for both USB2 and USB3 host controllers
> +controllers available on STiH407 SoC families.
> +
> +On STiH410, we have to use the DWC3 port#2 with a picoPHY to manage USB2
> +devices. The USB2 Controller will use the ports #0 and #1.
> +
> +This is to document the DT parameters to be passed from the blob in that case.
> +
> +Required properties:
> +- compatible		: should be "st,stih407-usb2-phy"

If STiH410 also uses the same driver then you should add a new compatibility
value for it.
> +- reg			: contain the offset and length of the system configuration registers
> +			  used as glue logic to control & parameter phy
> +- reg-names		: the names of the system configuration registers in "reg", should be "param" and "reg"
> +- st,syscfg		: sysconfig register to manage phy parameter at driver level
> +- resets		: list of phandle and reset specifier pairs. There should be two entries, one
> +			  for the whole phy and one for the port
> +- reset-names		: list of reset signal names. Should be "global" and "port"
> +See: Documentation/devicetree/bindings/reset/st,sti-powerdown.txt
> +See: Documentation/devicetree/bindings/reset/reset.txt
> +
> +Example:
> +
> +usb2_picophy0: usbpicophy@0 {
usbpicophy@f8 since you have a reg property ;-)

> +	compatible	= "st,stih407-usb2-phy";
> +	reg		= <0xf8 0x04>,	/* syscfg 5062 */
> +			  <0xf4 0x04>;	/* syscfg 5061 */
> +	reg-names	= "param",
> +			  "ctrl";
> +			  #phy-cells = <0>;

alignment seems to have gone wrong here.

Thanks
Kishon

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH 2/3] phy: phy-stih407-usb: Add dt documentation for USB picophy found on stih407 SoC family
@ 2014-09-08 15:30     ` Kishon Vijay Abraham I
  0 siblings, 0 replies; 23+ messages in thread
From: Kishon Vijay Abraham I @ 2014-09-08 15:30 UTC (permalink / raw)
  To: Peter Griffin, linux-arm-kernel, linux-kernel,
	srinivas.kandagatla, maxime.coquelin, patrice.chotard
  Cc: lee.jones, devicetree, Giuseppe Cavallaro

Hi,

On Wednesday 03 September 2014 03:57 PM, Peter Griffin wrote:
> This patch adds the dt documentation for the usb picophy found on stih407 SoC family
> available from STMicroelectronics.
> 
> Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com>
> Signed-off-by: Peter Griffin <peter.griffin@linaro.org>
> ---
>  .../devicetree/bindings/phy/phy-stih407-usb.txt    | 37 ++++++++++++++++++++++
>  1 file changed, 37 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
> 
> diff --git a/Documentation/devicetree/bindings/phy/phy-stih407-usb.txt b/Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
> new file mode 100644
> index 0000000..650d346
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
> @@ -0,0 +1,37 @@
> +ST STiH407 USB-PHY controller
> +
> +This file documents the dt bindings for the picoPHY driver which is the PHY for both USB2 and USB3 host controllers
> +controllers available on STiH407 SoC families.
> +
> +On STiH410, we have to use the DWC3 port#2 with a picoPHY to manage USB2
> +devices. The USB2 Controller will use the ports #0 and #1.
> +
> +This is to document the DT parameters to be passed from the blob in that case.
> +
> +Required properties:
> +- compatible		: should be "st,stih407-usb2-phy"

If STiH410 also uses the same driver then you should add a new compatibility
value for it.
> +- reg			: contain the offset and length of the system configuration registers
> +			  used as glue logic to control & parameter phy
> +- reg-names		: the names of the system configuration registers in "reg", should be "param" and "reg"
> +- st,syscfg		: sysconfig register to manage phy parameter at driver level
> +- resets		: list of phandle and reset specifier pairs. There should be two entries, one
> +			  for the whole phy and one for the port
> +- reset-names		: list of reset signal names. Should be "global" and "port"
> +See: Documentation/devicetree/bindings/reset/st,sti-powerdown.txt
> +See: Documentation/devicetree/bindings/reset/reset.txt
> +
> +Example:
> +
> +usb2_picophy0: usbpicophy@0 {
usbpicophy@f8 since you have a reg property ;-)

> +	compatible	= "st,stih407-usb2-phy";
> +	reg		= <0xf8 0x04>,	/* syscfg 5062 */
> +			  <0xf4 0x04>;	/* syscfg 5061 */
> +	reg-names	= "param",
> +			  "ctrl";
> +			  #phy-cells = <0>;

alignment seems to have gone wrong here.

Thanks
Kishon

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH 2/3] phy: phy-stih407-usb: Add dt documentation for USB picophy found on stih407 SoC family
@ 2014-09-08 15:30     ` Kishon Vijay Abraham I
  0 siblings, 0 replies; 23+ messages in thread
From: Kishon Vijay Abraham I @ 2014-09-08 15:30 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

On Wednesday 03 September 2014 03:57 PM, Peter Griffin wrote:
> This patch adds the dt documentation for the usb picophy found on stih407 SoC family
> available from STMicroelectronics.
> 
> Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com>
> Signed-off-by: Peter Griffin <peter.griffin@linaro.org>
> ---
>  .../devicetree/bindings/phy/phy-stih407-usb.txt    | 37 ++++++++++++++++++++++
>  1 file changed, 37 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
> 
> diff --git a/Documentation/devicetree/bindings/phy/phy-stih407-usb.txt b/Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
> new file mode 100644
> index 0000000..650d346
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/phy/phy-stih407-usb.txt
> @@ -0,0 +1,37 @@
> +ST STiH407 USB-PHY controller
> +
> +This file documents the dt bindings for the picoPHY driver which is the PHY for both USB2 and USB3 host controllers
> +controllers available on STiH407 SoC families.
> +
> +On STiH410, we have to use the DWC3 port#2 with a picoPHY to manage USB2
> +devices. The USB2 Controller will use the ports #0 and #1.
> +
> +This is to document the DT parameters to be passed from the blob in that case.
> +
> +Required properties:
> +- compatible		: should be "st,stih407-usb2-phy"

If STiH410 also uses the same driver then you should add a new compatibility
value for it.
> +- reg			: contain the offset and length of the system configuration registers
> +			  used as glue logic to control & parameter phy
> +- reg-names		: the names of the system configuration registers in "reg", should be "param" and "reg"
> +- st,syscfg		: sysconfig register to manage phy parameter at driver level
> +- resets		: list of phandle and reset specifier pairs. There should be two entries, one
> +			  for the whole phy and one for the port
> +- reset-names		: list of reset signal names. Should be "global" and "port"
> +See: Documentation/devicetree/bindings/reset/st,sti-powerdown.txt
> +See: Documentation/devicetree/bindings/reset/reset.txt
> +
> +Example:
> +
> +usb2_picophy0: usbpicophy at 0 {
usbpicophy at f8 since you have a reg property ;-)

> +	compatible	= "st,stih407-usb2-phy";
> +	reg		= <0xf8 0x04>,	/* syscfg 5062 */
> +			  <0xf4 0x04>;	/* syscfg 5061 */
> +	reg-names	= "param",
> +			  "ctrl";
> +			  #phy-cells = <0>;

alignment seems to have gone wrong here.

Thanks
Kishon

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH 0/3]  Add picoPHY usb phy driver found on stih407 family SoC's
@ 2014-09-08 15:53     ` Peter Griffin
  0 siblings, 0 replies; 23+ messages in thread
From: Peter Griffin @ 2014-09-08 15:53 UTC (permalink / raw)
  To: Kishon Vijay Abraham I
  Cc: linux-arm-kernel, linux-kernel, srinivas.kandagatla,
	maxime.coquelin, patrice.chotard, lee.jones, devicetree

Hi Kishon,

> On Wednesday 03 September 2014 03:57 PM, Peter Griffin wrote:
> > This series adds support for the picoPHY usb phy which is used by the usb2
> > and usb3 host controllers when controlling usb2/1.1 devices. It is found on
> > stih407 family SoC's from the consumer electronics devision of STMicroelectronics.
> 
> So miphy28lp is the PHY controller for USB3 device controller and picoPHY is
> the PHY controller for USB3 host controller?

No, miphy28lp is the usb3 phy and picoPHY is the usb2 phy.

With a usb2 host controller only picoPHY is used. With the usb3 host controller both usb2 and usb3 phys
are used depending on what type of device is plugged in.

Hope that clarifies things,

regards,

Peter.

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH 0/3]  Add picoPHY usb phy driver found on stih407 family SoC's
@ 2014-09-08 15:53     ` Peter Griffin
  0 siblings, 0 replies; 23+ messages in thread
From: Peter Griffin @ 2014-09-08 15:53 UTC (permalink / raw)
  To: Kishon Vijay Abraham I
  Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	srinivas.kandagatla-Re5JQEeQqe8AvxtiuMwx3w,
	maxime.coquelin-qxv4g6HH51o, patrice.chotard-qxv4g6HH51o,
	lee.jones-QSEj5FYQhm4dnm+yROfE0A,
	devicetree-u79uwXL29TY76Z2rM5mHXA

Hi Kishon,

> On Wednesday 03 September 2014 03:57 PM, Peter Griffin wrote:
> > This series adds support for the picoPHY usb phy which is used by the usb2
> > and usb3 host controllers when controlling usb2/1.1 devices. It is found on
> > stih407 family SoC's from the consumer electronics devision of STMicroelectronics.
> 
> So miphy28lp is the PHY controller for USB3 device controller and picoPHY is
> the PHY controller for USB3 host controller?

No, miphy28lp is the usb3 phy and picoPHY is the usb2 phy.

With a usb2 host controller only picoPHY is used. With the usb3 host controller both usb2 and usb3 phys
are used depending on what type of device is plugged in.

Hope that clarifies things,

regards,

Peter.
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH 0/3]  Add picoPHY usb phy driver found on stih407 family SoC's
@ 2014-09-08 15:53     ` Peter Griffin
  0 siblings, 0 replies; 23+ messages in thread
From: Peter Griffin @ 2014-09-08 15:53 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Kishon,

> On Wednesday 03 September 2014 03:57 PM, Peter Griffin wrote:
> > This series adds support for the picoPHY usb phy which is used by the usb2
> > and usb3 host controllers when controlling usb2/1.1 devices. It is found on
> > stih407 family SoC's from the consumer electronics devision of STMicroelectronics.
> 
> So miphy28lp is the PHY controller for USB3 device controller and picoPHY is
> the PHY controller for USB3 host controller?

No, miphy28lp is the usb3 phy and picoPHY is the usb2 phy.

With a usb2 host controller only picoPHY is used. With the usb3 host controller both usb2 and usb3 phys
are used depending on what type of device is plugged in.

Hope that clarifies things,

regards,

Peter.

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH 2/3] phy: phy-stih407-usb: Add dt documentation for USB picophy found on stih407 SoC family
  2014-09-08 15:30     ` Kishon Vijay Abraham I
@ 2014-09-09  7:34       ` Peter Griffin
  -1 siblings, 0 replies; 23+ messages in thread
From: Peter Griffin @ 2014-09-09  7:34 UTC (permalink / raw)
  To: Kishon Vijay Abraham I
  Cc: linux-arm-kernel, linux-kernel, srinivas.kandagatla,
	maxime.coquelin, patrice.chotard, lee.jones, devicetree,
	Giuseppe Cavallaro

Hi Kishon,

Thanks for reviewing :-)

> > +On STiH410, we have to use the DWC3 port#2 with a picoPHY to manage USB2
> > +devices. The USB2 Controller will use the ports #0 and #1.
> > +
> > +This is to document the DT parameters to be passed from the blob in that case.
> > +
> > +Required properties:
> > +- compatible		: should be "st,stih407-usb2-phy"
> 
> If STiH410 also uses the same driver then you should add a new compatibility
> value for it.

I will remove the reference to stih410 in V2, as currently it is not supported
upstream, and I'm not sure what ST's plans are regarding upstreaming it. If/
when it is upstreamed, we can add this and a compabible property back in.

<snip>
> > +
> > +usb2_picophy0: usbpicophy@0 {
> usbpicophy@f8 since you have a reg property ;-)

will fix in V2

> 
> > +	compatible	= "st,stih407-usb2-phy";
> > +	reg		= <0xf8 0x04>,	/* syscfg 5062 */
> > +			  <0xf4 0x04>;	/* syscfg 5061 */
> > +	reg-names	= "param",
> > +			  "ctrl";
> > +			  #phy-cells = <0>;
> 
> alignment seems to have gone wrong here.

Will fix in v2

regards,

Peter.

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH 2/3] phy: phy-stih407-usb: Add dt documentation for USB picophy found on stih407 SoC family
@ 2014-09-09  7:34       ` Peter Griffin
  0 siblings, 0 replies; 23+ messages in thread
From: Peter Griffin @ 2014-09-09  7:34 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Kishon,

Thanks for reviewing :-)

> > +On STiH410, we have to use the DWC3 port#2 with a picoPHY to manage USB2
> > +devices. The USB2 Controller will use the ports #0 and #1.
> > +
> > +This is to document the DT parameters to be passed from the blob in that case.
> > +
> > +Required properties:
> > +- compatible		: should be "st,stih407-usb2-phy"
> 
> If STiH410 also uses the same driver then you should add a new compatibility
> value for it.

I will remove the reference to stih410 in V2, as currently it is not supported
upstream, and I'm not sure what ST's plans are regarding upstreaming it. If/
when it is upstreamed, we can add this and a compabible property back in.

<snip>
> > +
> > +usb2_picophy0: usbpicophy at 0 {
> usbpicophy at f8 since you have a reg property ;-)

will fix in V2

> 
> > +	compatible	= "st,stih407-usb2-phy";
> > +	reg		= <0xf8 0x04>,	/* syscfg 5062 */
> > +			  <0xf4 0x04>;	/* syscfg 5061 */
> > +	reg-names	= "param",
> > +			  "ctrl";
> > +			  #phy-cells = <0>;
> 
> alignment seems to have gone wrong here.

Will fix in v2

regards,

Peter.

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH 0/3]  Add picoPHY usb phy driver found on stih407 family SoC's
  2014-09-08 15:53     ` Peter Griffin
  (?)
@ 2014-09-10  8:38       ` Kishon Vijay Abraham I
  -1 siblings, 0 replies; 23+ messages in thread
From: Kishon Vijay Abraham I @ 2014-09-10  8:38 UTC (permalink / raw)
  To: Peter Griffin
  Cc: linux-arm-kernel, linux-kernel, srinivas.kandagatla,
	maxime.coquelin, patrice.chotard, lee.jones, devicetree



On Monday 08 September 2014 09:23 PM, Peter Griffin wrote:
> Hi Kishon,
> 
>> On Wednesday 03 September 2014 03:57 PM, Peter Griffin wrote:
>>> This series adds support for the picoPHY usb phy which is used by the usb2
>>> and usb3 host controllers when controlling usb2/1.1 devices. It is found on
>>> stih407 family SoC's from the consumer electronics devision of STMicroelectronics.
>>
>> So miphy28lp is the PHY controller for USB3 device controller and picoPHY is
>> the PHY controller for USB3 host controller?
> 
> No, miphy28lp is the usb3 phy and picoPHY is the usb2 phy.
> 
> With a usb2 host controller only picoPHY is used. With the usb3 host controller both usb2 and usb3 phys
> are used depending on what type of device is plugged in.
> 
> Hope that clarifies things,

indeed. thanks for the explanation :-)

Cheers
Kishon

^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: [PATCH 0/3]  Add picoPHY usb phy driver found on stih407 family SoC's
@ 2014-09-10  8:38       ` Kishon Vijay Abraham I
  0 siblings, 0 replies; 23+ messages in thread
From: Kishon Vijay Abraham I @ 2014-09-10  8:38 UTC (permalink / raw)
  To: Peter Griffin
  Cc: linux-arm-kernel, linux-kernel, srinivas.kandagatla,
	maxime.coquelin, patrice.chotard, lee.jones, devicetree



On Monday 08 September 2014 09:23 PM, Peter Griffin wrote:
> Hi Kishon,
> 
>> On Wednesday 03 September 2014 03:57 PM, Peter Griffin wrote:
>>> This series adds support for the picoPHY usb phy which is used by the usb2
>>> and usb3 host controllers when controlling usb2/1.1 devices. It is found on
>>> stih407 family SoC's from the consumer electronics devision of STMicroelectronics.
>>
>> So miphy28lp is the PHY controller for USB3 device controller and picoPHY is
>> the PHY controller for USB3 host controller?
> 
> No, miphy28lp is the usb3 phy and picoPHY is the usb2 phy.
> 
> With a usb2 host controller only picoPHY is used. With the usb3 host controller both usb2 and usb3 phys
> are used depending on what type of device is plugged in.
> 
> Hope that clarifies things,

indeed. thanks for the explanation :-)

Cheers
Kishon

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH 0/3]  Add picoPHY usb phy driver found on stih407 family SoC's
@ 2014-09-10  8:38       ` Kishon Vijay Abraham I
  0 siblings, 0 replies; 23+ messages in thread
From: Kishon Vijay Abraham I @ 2014-09-10  8:38 UTC (permalink / raw)
  To: linux-arm-kernel



On Monday 08 September 2014 09:23 PM, Peter Griffin wrote:
> Hi Kishon,
> 
>> On Wednesday 03 September 2014 03:57 PM, Peter Griffin wrote:
>>> This series adds support for the picoPHY usb phy which is used by the usb2
>>> and usb3 host controllers when controlling usb2/1.1 devices. It is found on
>>> stih407 family SoC's from the consumer electronics devision of STMicroelectronics.
>>
>> So miphy28lp is the PHY controller for USB3 device controller and picoPHY is
>> the PHY controller for USB3 host controller?
> 
> No, miphy28lp is the usb3 phy and picoPHY is the usb2 phy.
> 
> With a usb2 host controller only picoPHY is used. With the usb3 host controller both usb2 and usb3 phys
> are used depending on what type of device is plugged in.
> 
> Hope that clarifies things,

indeed. thanks for the explanation :-)

Cheers
Kishon

^ permalink raw reply	[flat|nested] 23+ messages in thread

end of thread, other threads:[~2014-09-10  8:39 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-03 10:27 [PATCH 0/3] Add picoPHY usb phy driver found on stih407 family SoC's Peter Griffin
2014-09-03 10:27 ` Peter Griffin
2014-09-03 10:27 ` Peter Griffin
2014-09-03 10:27 ` [PATCH 1/3] phy: phy-stih407-usb: Add usb picoPHY driver found on stih407 SoC family Peter Griffin
2014-09-03 10:27   ` Peter Griffin
2014-09-03 10:27 ` [PATCH 2/3] phy: phy-stih407-usb: Add dt documentation for USB picophy " Peter Griffin
2014-09-03 10:27   ` Peter Griffin
2014-09-08 15:30   ` Kishon Vijay Abraham I
2014-09-08 15:30     ` Kishon Vijay Abraham I
2014-09-08 15:30     ` Kishon Vijay Abraham I
2014-09-09  7:34     ` Peter Griffin
2014-09-09  7:34       ` Peter Griffin
2014-09-03 10:27 ` [PATCH 3/3] MAINTAINERS: Add phy-stih407-usb.c file to ARCH/STI architecture Peter Griffin
2014-09-03 10:27   ` Peter Griffin
2014-09-08 15:23 ` [PATCH 0/3] Add picoPHY usb phy driver found on stih407 family SoC's Kishon Vijay Abraham I
2014-09-08 15:23   ` Kishon Vijay Abraham I
2014-09-08 15:23   ` Kishon Vijay Abraham I
2014-09-08 15:53   ` Peter Griffin
2014-09-08 15:53     ` Peter Griffin
2014-09-08 15:53     ` Peter Griffin
2014-09-10  8:38     ` Kishon Vijay Abraham I
2014-09-10  8:38       ` Kishon Vijay Abraham I
2014-09-10  8:38       ` Kishon Vijay Abraham I

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.