• Roelof Berg's avatar
    lan743x: Added fixed link and RGMII support · 6f197fb6
    Roelof Berg authored
    Microchip lan7431 is frequently connected to a phy. However, it
    can also be directly connected to a MII remote peer without
    any phy in between. For supporting such a phyless hardware setup
    in Linux we utilized phylib, which supports a fixed-link
    configuration via the device tree. And we added support for
    defining the connection type R/GMII in the device tree.
    
    New behavior:
    -------------
    . The automatic speed and duplex detection of the lan743x silicon
      between mac and phy is disabled. Instead phylib is used like in
      other typical Linux drivers. The usage of phylib allows to
      specify fixed-link parameters in the device tree.
    
    . The device tree entry phy-connection-type is supported now with
      the modes RGMII or (G)MII (default).
    
    Development state:
    ------------------
    . Tested with fixed-phy configurations. Not yet tested in normal
      configurations with phy. Microchip kindly offered testing
      as soon as the Corona measures allow this.
    
    . All review findings of Andrew Lunn are included
    
    Example:
    --------
    &pcie {
    	status = "okay";
    
    	host@0 {
    		reg = <0 0 0 0 0>;
    
    		#address-cells = <3>;
    		#size-cells = <2>;
    
    		ethernet@0 {
    			compatible = "weyland-yutani,noscom1", "microchip,lan743x";
    			status = "okay";
    			reg = <0 0 0 0 0>;
    			phy-connection-type = "rgmii";
    
    			fixed-link {
    				speed = <100>;
    				full-duplex;
    			};
    		};
    	};
    };
    Signed-off-by: default avatarRoelof Berg <rberg@berg-solutions.de>
    Signed-off-by: default avatarAndrew Lunn <andrew@lunn.ch>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    6f197fb6
lan743x_main.c 84.2 KB