Yocto Marvell 88e6xxx driver

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Yocto Marvell 88e6xxx driver

387 Views
MJaroc
Contributor II

Hi,

i attach marvell switch to board, configure it in device tree:

&mdio1 {
 #address-cells = <1>;
 #size-cells = <0>;
 
 switch0: switch0@0 {
	compatible = "marvell,mv88e6085";
	reg = <0>;
	dsa,member = <0 0>;

 	ports {
	 	#address-cells = <1>;
		#size-cells = <0>;
		port@0 {
			reg = <0>;
			label = "lan0";
			fixed-link {
				speed = <1000>;
				full-duplex;
			};			
		};
        
		port@1 {
			reg = <1>;
			label = "lan1";
			fixed-link {
				speed = <1000>;
				full-duplex;
			};
		};
		
		port@3 {
			reg = <3>;
			label = "nmi";
		};

		switch0cpu5: port@5 {
			reg = <5>;
			label = "cpu";
			ethernet = <&fec1>;
			phy-mode = "rgmii";
			fixed-link {
				speed = <1000>;
				full-duplex;
			};			
        };
	};
					
 };
};

I can read PHY registry by tools like mdio-tool, phytool ect, but i need to modify registry in port. Ethtool can dump port registers by "ethtool -d nmi", but there is no method to write. I need to modify reg 6 (Port-based vlan) to separate ports in switch. How can i do that? In older linux kernels i have /dev/mdio and i can write direct to mdio, in Yocto kirkstone (linux-imx 5.15) i must use ioctl with predefinied structures and commands.

 

0 Kudos
Reply
2 Replies

312 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hi @MJaroc 

The kernel update could also update the phy driver and mdio framework which will casue older interface can't work. Use ioctl with predefinied structures and commands is also another way to access registers.

 

Best Regards

Zhiming

0 Kudos
Reply

303 Views
MJaroc
Contributor II
Hi @Zhiming_Liu
I sad that there is no predefined structure and command to save registry. I need to add it on my own and modify driver.
0 Kudos
Reply