amd-xgbe: Move the PHY support into amd-xgbe
authorLendacky, Thomas <Thomas.Lendacky@amd.com>
Thu, 14 May 2015 16:44:15 +0000 (11:44 -0500)
committerDavid S. Miller <davem@davemloft.net>
Fri, 15 May 2015 19:21:43 +0000 (15:21 -0400)
The AMD XGBE device is intended to work with a specific integrated PHY
and that PHY is not meant to be a standalone PHY for use by other
devices. As such this patch removes the phylib driver and implements
the PHY support in the amd-xgbe driver (the majority of the logic from
the phylib driver is moved into the amd-xgbe driver).

Update the driver version to 1.0.1.

Signed-off-by: Tom Lendacky <thomas.lendacky@amd.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 files changed:
Documentation/devicetree/bindings/net/amd-xgbe-phy.txt [deleted file]
Documentation/devicetree/bindings/net/amd-xgbe.txt
MAINTAINERS
drivers/net/ethernet/amd/Kconfig
drivers/net/ethernet/amd/xgbe/xgbe-common.h
drivers/net/ethernet/amd/xgbe/xgbe-dev.c
drivers/net/ethernet/amd/xgbe/xgbe-drv.c
drivers/net/ethernet/amd/xgbe/xgbe-ethtool.c
drivers/net/ethernet/amd/xgbe/xgbe-main.c
drivers/net/ethernet/amd/xgbe/xgbe-mdio.c
drivers/net/ethernet/amd/xgbe/xgbe.h
drivers/net/phy/Kconfig
drivers/net/phy/Makefile
drivers/net/phy/amd-xgbe-phy.c [deleted file]

diff --git a/Documentation/devicetree/bindings/net/amd-xgbe-phy.txt b/Documentation/devicetree/bindings/net/amd-xgbe-phy.txt
deleted file mode 100644 (file)
index 8db3238..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-* AMD 10GbE PHY driver (amd-xgbe-phy)
-
-Required properties:
-- compatible: Should be "amd,xgbe-phy-seattle-v1a" and
-  "ethernet-phy-ieee802.3-c45"
-- reg: Address and length of the register sets for the device
-   - SerDes Rx/Tx registers
-   - SerDes integration registers (1/2)
-   - SerDes integration registers (2/2)
-- interrupt-parent: Should be the phandle for the interrupt controller
-  that services interrupts for this device
-- interrupts: Should contain the amd-xgbe-phy interrupt.
-
-Optional properties:
-- amd,speed-set: Speed capabilities of the device
-    0 - 1GbE and 10GbE (default)
-    1 - 2.5GbE and 10GbE
-
-The following optional properties are represented by an array with each
-value corresponding to a particular speed. The first array value represents
-the setting for the 1GbE speed, the second value for the 2.5GbE speed and
-the third value for the 10GbE speed.  All three values are required if the
-property is used.
-- amd,serdes-blwc: Baseline wandering correction enablement
-    0 - Off
-    1 - On
-- amd,serdes-cdr-rate: CDR rate speed selection
-- amd,serdes-pq-skew: PQ (data sampling) skew
-- amd,serdes-tx-amp: TX amplitude boost
-- amd,serdes-dfe-tap-config: DFE taps available to run
-- amd,serdes-dfe-tap-enable: DFE taps to enable
-
-Example:
-       xgbe_phy@e1240800 {
-               compatible = "amd,xgbe-phy-seattle-v1a", "ethernet-phy-ieee802.3-c45";
-               reg = <0 0xe1240800 0 0x00400>,
-                     <0 0xe1250000 0 0x00060>,
-                     <0 0xe1250080 0 0x00004>;
-               interrupt-parent = <&gic>;
-               interrupts = <0 323 4>;
-               amd,speed-set = <0>;
-               amd,serdes-blwc = <1>, <1>, <0>;
-               amd,serdes-cdr-rate = <2>, <2>, <7>;
-               amd,serdes-pq-skew = <10>, <10>, <30>;
-               amd,serdes-tx-amp = <15>, <15>, <10>;
-               amd,serdes-dfe-tap-config = <3>, <3>, <1>;
-               amd,serdes-dfe-tap-enable = <0>, <0>, <127>;
-       };
index 26efd52..5dbc55a 100644 (file)
@@ -1,6 +1,6 @@
 * AMD 10GbE driver (amd-xgbe)
 
-Required properties:
+Required properties (ethernet device):
 - compatible: Should be "amd,xgbe-seattle-v1a"
 - reg: Address and length of the register sets for the device
    - MAC registers
@@ -22,7 +22,7 @@ Required properties:
 - phy-handle: See ethernet.txt file in the same directory
 - phy-mode: See ethernet.txt file in the same directory
 
-Optional properties:
+Optional properties (ethernet device):
 - mac-address: mac address to be assigned to the device. Can be overridden
   by UEFI.
 - dma-coherent: Present if dma operations are coherent
@@ -30,6 +30,35 @@ Optional properties:
   a unique interrupt for each DMA channel - this requires an additional
   interrupt be configured for each DMA channel
 
+Required properties (phy device):
+- compatible: Should be "amd,xgbe-phy-seattle-v1a"
+- reg: Address and length of the register sets for the device
+   - SerDes Rx/Tx registers
+   - SerDes integration registers (1/2)
+   - SerDes integration registers (2/2)
+- interrupt-parent: Should be the phandle for the interrupt controller
+  that services interrupts for this device
+- interrupts: Should contain the amd-xgbe-phy interrupt.
+
+Optional properties (phy device):
+- amd,speed-set: Speed capabilities of the device
+    0 - 1GbE and 10GbE (default)
+    1 - 2.5GbE and 10GbE
+
+The following optional properties are represented by an array with each
+value corresponding to a particular speed. The first array value represents
+the setting for the 1GbE speed, the second value for the 2.5GbE speed and
+the third value for the 10GbE speed.  All three values are required if the
+property is used.
+- amd,serdes-blwc: Baseline wandering correction enablement
+    0 - Off
+    1 - On
+- amd,serdes-cdr-rate: CDR rate speed selection
+- amd,serdes-pq-skew: PQ (data sampling) skew
+- amd,serdes-tx-amp: TX amplitude boost
+- amd,serdes-dfe-tap-config: DFE taps available to run
+- amd,serdes-dfe-tap-enable: DFE taps to enable
+
 Example:
        xgbe@e0700000 {
                compatible = "amd,xgbe-seattle-v1a";
@@ -41,7 +70,23 @@ Example:
                amd,per-channel-interrupt;
                clocks = <&xgbe_dma_clk>, <&xgbe_ptp_clk>;
                clock-names = "dma_clk", "ptp_clk";
-               phy-handle = <&phy>;
+               phy-handle = <&xgbe_phy>;
                phy-mode = "xgmii";
                mac-address = [ 02 a1 a2 a3 a4 a5 ];
        };
+
+       xgbe_phy@e1240800 {
+               compatible = "amd,xgbe-phy-seattle-v1a";
+               reg = <0 0xe1240800 0 0x00400>,
+                     <0 0xe1250000 0 0x00060>,
+                     <0 0xe1250080 0 0x00004>;
+               interrupt-parent = <&gic>;
+               interrupts = <0 323 4>;
+               amd,speed-set = <0>;
+               amd,serdes-blwc = <1>, <1>, <0>;
+               amd,serdes-cdr-rate = <2>, <2>, <7>;
+               amd,serdes-pq-skew = <10>, <10>, <30>;
+               amd,serdes-tx-amp = <15>, <15>, <10>;
+               amd,serdes-dfe-tap-config = <3>, <3>, <1>;
+               amd,serdes-dfe-tap-enable = <0>, <0>, <127>;
+       };
index 5d87ccb..38abdb2 100644 (file)
@@ -652,7 +652,6 @@ M:  Tom Lendacky <thomas.lendacky@amd.com>
 L:     netdev@vger.kernel.org
 S:     Supported
 F:     drivers/net/ethernet/amd/xgbe/
-F:     drivers/net/phy/amd-xgbe-phy.c
 
 AMS (Apple Motion Sensor) DRIVER
 M:     Michael Hanselmann <linux-kernel@hansmi.ch>
Simple merge
Simple merge
Simple merge
Simple merge
diff --cc drivers/net/phy/amd-xgbe-phy.c
Simple merge