Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1413339 > unrolled thread

[PATCH v3 RESEND 0/7] Add MDIO bus multiplexer support for iProc SoCs

Started byPramod Kumar <pramod.kumar@broadcom.com>
First post2016-06-03 18:10 +0200
Last post2016-06-06 05:30 +0200
Articles 5 — 3 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH v3 RESEND 0/7] Add MDIO bus multiplexer support for iProc SoCs Pramod Kumar <pramod.kumar@broadcom.com> - 2016-06-03 18:10 +0200
    [PATCH v3 RESEND 4/7] dt:mdio-mux: Add mdio multiplexer driver node Pramod Kumar <pramod.kumar@broadcom.com> - 2016-06-03 18:10 +0200
    [PATCH v3 RESEND 2/7] binding: Make "mdio-parent-bus" property from mandatory to optional Pramod Kumar <pramod.kumar@broadcom.com> - 2016-06-03 18:10 +0200
    Re: [PATCH v3 RESEND 0/7] Add MDIO bus multiplexer support for iProc  SoCs Andrew Lunn <andrew@lunn.ch> - 2016-06-03 18:40 +0200
      Re: [PATCH v3 RESEND 0/7] Add MDIO bus multiplexer support for  iProc SoCs David Miller <davem@davemloft.net> - 2016-06-06 05:30 +0200

#1413339 — [PATCH v3 RESEND 0/7] Add MDIO bus multiplexer support for iProc SoCs

FromPramod Kumar <pramod.kumar@broadcom.com>
Date2016-06-03 18:10 +0200
Subject[PATCH v3 RESEND 0/7] Add MDIO bus multiplexer support for iProc SoCs
Message-ID<rFZPz-5sI-3@gated-at.bofh.it>
Broadcom iProc based SoCs use a MDIO bus multiplexer where child buses
could be internal as well external to SoCs. These buses could supports
MDIO transaction compatible to C-22/C-45.

Broadcom MDIO bus mulitplexer is an integrated multiplexer where child bus
selection and mdio transaction logic lies inside multiplexer itself.
To accommodate this multiplexer in existing mux framework below changes
were required-

1. Passed MDIO parent bus via mdio_mux_init to MDIO mux framework.

This patch set includes MDIO bus multiplexer driver along with above
framework change. It includes one external bus node having Ethernet PHY
attached and two internal bus node holding PCIe PHYs.

This patch series is based on v4.7-rc1 and is available from github-
repo: https://github.com/Broadcom/arm64-linux.git
branch:mdio-mux-v3-resend

Reason for resend:
-Rebased on v4.7-rc1

Changes from v2:
-Addressed Rob's comments in this patch regarding typo/grammers.
-Addressed David's comments regarding local variables order.
-Removed property "mdio-integrated-mux" and used mdiobus_register()
in place of of_mdiobus_regsiter().
-removed usage of IS_ERR_OR_NULL to IS_ERR in PCIe PHY driver.

Changes from v1:
- stop using "brcm,is_c45" from bus node as suggested by Andrew. MDIO
PHY driver will logically OR MII_ADDR_C45 into the address when issues
any C45 MDIO read/write transaction.

Pramod Kumar (7):
  mdio:mux: Enhanced MDIO mux framework for integrated multiplexers
  binding: Make "mdio-parent-bus" property from mandatory to optional
  binding: mdio-mux: Add DT binding doc for Broadcom MDIO bus mutiplexer
  dt:mdio-mux: Add mdio multiplexer driver node
  net:mdio-mux: Add MDIO mux driver for iProc SoCs
  Binding:PHY: Binding doc for NS2 PCIe PHYs.
  phy: Add Northstar2 PCI Phy support

 .../bindings/net/brcm,mdio-mux-iproc.txt           |  59 +++++
 Documentation/devicetree/bindings/net/mdio-mux.txt |   3 +-
 .../bindings/phy/brcm,mdio-mux-bus-pci.txt         |  27 +++
 arch/arm64/boot/dts/broadcom/ns2-svk.dts           |  12 +
 arch/arm64/boot/dts/broadcom/ns2.dtsi              |  31 +++
 drivers/net/phy/Kconfig                            |  11 +
 drivers/net/phy/Makefile                           |   1 +
 drivers/net/phy/mdio-mux-bcm-iproc.c               | 246 +++++++++++++++++++++
 drivers/net/phy/mdio-mux-gpio.c                    |   2 +-
 drivers/net/phy/mdio-mux-mmioreg.c                 |   2 +-
 drivers/net/phy/mdio-mux.c                         |  28 ++-
 drivers/phy/Kconfig                                |   8 +
 drivers/phy/Makefile                               |   2 +-
 drivers/phy/phy-bcm-ns2-pcie.c                     | 115 ++++++++++
 include/linux/mdio-mux.h                           |   4 +-
 15 files changed, 536 insertions(+), 15 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/net/brcm,mdio-mux-iproc.txt
 create mode 100644 Documentation/devicetree/bindings/phy/brcm,mdio-mux-bus-pci.txt
 create mode 100644 drivers/net/phy/mdio-mux-bcm-iproc.c
 create mode 100644 drivers/phy/phy-bcm-ns2-pcie.c

-- 
1.9.1

[toc] | [next] | [standalone]


#1413341 — [PATCH v3 RESEND 4/7] dt:mdio-mux: Add mdio multiplexer driver node

FromPramod Kumar <pramod.kumar@broadcom.com>
Date2016-06-03 18:10 +0200
Subject[PATCH v3 RESEND 4/7] dt:mdio-mux: Add mdio multiplexer driver node
Message-ID<rFZPA-5sI-31@gated-at.bofh.it>
In reply to#1413339
Add integrated MDIO multiplexer driver node which contains
two mux PCIe bus and one ethernet bus along with phys
lying on these bus.

Signed-off-by: Pramod Kumar <pramod.kumar@broadcom.com>
---
 arch/arm64/boot/dts/broadcom/ns2-svk.dts | 12 ++++++++++++
 arch/arm64/boot/dts/broadcom/ns2.dtsi    | 31 +++++++++++++++++++++++++++++++
 2 files changed, 43 insertions(+)

diff --git a/arch/arm64/boot/dts/broadcom/ns2-svk.dts b/arch/arm64/boot/dts/broadcom/ns2-svk.dts
index 54ca40c..71f8503 100644
--- a/arch/arm64/boot/dts/broadcom/ns2-svk.dts
+++ b/arch/arm64/boot/dts/broadcom/ns2-svk.dts
@@ -132,3 +132,15 @@
 		#size-cells = <1>;
 	};
 };
+
+&mdio_mux_iproc {
+	mdio@10 {
+		reg = <0x10>;
+		#address-cells = <1>;
+		#size-cells = <0>;
+
+		gphy0: eth-phy@10 {
+			reg = <0x10>;
+		};
+	};
+};
diff --git a/arch/arm64/boot/dts/broadcom/ns2.dtsi b/arch/arm64/boot/dts/broadcom/ns2.dtsi
index ec68ec1..9f20a66 100644
--- a/arch/arm64/boot/dts/broadcom/ns2.dtsi
+++ b/arch/arm64/boot/dts/broadcom/ns2.dtsi
@@ -263,6 +263,37 @@
 				      IRQ_TYPE_LEVEL_HIGH)>;
 		};
 
+		mdio_mux_iproc: mdio-mux@6602023c {
+			compatible = "brcm,mdio-mux-iproc";
+			reg = <0x6602023c 0x14>;
+			#address-cells = <1>;
+			#size-cells = <0>;
+
+			mdio@0 {
+				reg = <0x0>;
+				#address-cells = <1>;
+				#size-cells = <0>;
+
+				pci_phy0: pci-phy@0 {
+					compatible = "brcm,ns2-pcie-phy";
+					reg = <0x0>;
+					#phy-cells = <0>;
+				};
+			};
+
+			mdio@7 {
+				reg = <0x7>;
+				#address-cells = <1>;
+				#size-cells = <0>;
+
+				pci_phy1: pci-phy@0 {
+					compatible = "brcm,ns2-pcie-phy";
+					reg = <0x0>;
+					#phy-cells = <0>;
+				};
+			};
+		};
+
 		timer0: timer@66030000 {
 			compatible = "arm,sp804", "arm,primecell";
 			reg = <0x66030000 0x1000>;
-- 
1.9.1

[toc] | [prev] | [next] | [standalone]


#1413343 — [PATCH v3 RESEND 2/7] binding: Make "mdio-parent-bus" property from mandatory to optional

FromPramod Kumar <pramod.kumar@broadcom.com>
Date2016-06-03 18:10 +0200
Subject[PATCH v3 RESEND 2/7] binding: Make "mdio-parent-bus" property from mandatory to optional
Message-ID<rFZPA-5sI-33@gated-at.bofh.it>
In reply to#1413339
Change "mdio-parent-bus" from mandatory section to optional
as it won't be required by integrated MDIO multiplexer
which has bus selection and mdio transaction generation logic,
integrated inside.

Signed-off-by: Pramod Kumar <pramod.kumar@broadcom.com>
---
 Documentation/devicetree/bindings/net/mdio-mux.txt | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/net/mdio-mux.txt b/Documentation/devicetree/bindings/net/mdio-mux.txt
index 491f5bd..f58571f 100644
--- a/Documentation/devicetree/bindings/net/mdio-mux.txt
+++ b/Documentation/devicetree/bindings/net/mdio-mux.txt
@@ -5,11 +5,12 @@ numbered uniquely in a device dependent manner.  The nodes for an MDIO
 bus multiplexer/switch will have one child node for each child bus.
 
 Required properties:
-- mdio-parent-bus : phandle to the parent MDIO bus.
 - #address-cells = <1>;
 - #size-cells = <0>;
 
 Optional properties:
+- mdio-parent-bus : phandle to the parent MDIO bus.
+
 - Other properties specific to the multiplexer/switch hardware.
 
 Required properties for child nodes:
-- 
1.9.1

[toc] | [prev] | [next] | [standalone]


#1413351 — Re: [PATCH v3 RESEND 0/7] Add MDIO bus multiplexer support for iProc SoCs

FromAndrew Lunn <andrew@lunn.ch>
Date2016-06-03 18:40 +0200
SubjectRe: [PATCH v3 RESEND 0/7] Add MDIO bus multiplexer support for iProc SoCs
Message-ID<rG0iB-5Cj-7@gated-at.bofh.it>
In reply to#1413339
> Reason for resend:
> -Rebased on v4.7-rc1

How do you see this getting merged? Via netdev? If so, you should be
based on net-next/master, not v4.7-rc1.

      Andrew

[toc] | [prev] | [next] | [standalone]


#1414583 — Re: [PATCH v3 RESEND 0/7] Add MDIO bus multiplexer support for iProc SoCs

FromDavid Miller <davem@davemloft.net>
Date2016-06-06 05:30 +0200
SubjectRe: [PATCH v3 RESEND 0/7] Add MDIO bus multiplexer support for iProc SoCs
Message-ID<rGToJ-7AE-7@gated-at.bofh.it>
In reply to#1413351
From: Andrew Lunn <andrew@lunn.ch>
Date: Fri, 3 Jun 2016 18:32:47 +0200

>> Reason for resend:
>> -Rebased on v4.7-rc1
> 
> How do you see this getting merged? Via netdev? If so, you should be
> based on net-next/master, not v4.7-rc1.

Indeed, please respin.

Also, in your Subject lines, always have a space after the ":"
characters.

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web