ARM: dts: turris-omnia: configure LED[0] pin function to link/activity
PATCH 1/2 ARM: dts: turris-omnia: configure LED[0] pin function to link/activity
The marvell PHY driver changes the LED[0] pin function to "On - 1000 Mbps Link, Off - Else".
Turris Omnia expects that the function is "On - Link, Blink - Activity, Off - No link".
Use the marvell,reg-init DT property to change the function.
In the future, once netdev trigger will support HW offloading, we will be able to have this configured via the combination of PHY driver and leds-turris-omnia driver.
--- arch/arm/boot/dts/armada-385-turris-omnia.dts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
arch/arm/boot/dts/armada-385-turris-omnia.dts +2 -1
@@ -397,7 +397,8 @@ &mdio { phy1: ethernet-phy@1 { compatible = "ethernet-phy-ieee802.3-c22"; reg = <1>; - marvell,reg-init = <3 18 0 0x4985>; + marvell,reg-init = <3 18 0 0x4985>, + <3 16 0xfff0 0x0001>; /* irq is connected to &pcawan pin 7 */ };
Signature · 7 lines
2.35.1 _______________________________________________ linux-arm-kernel mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
PATCH 2/2 ARM: dts: turris-omnia: enable LED controller node
The LED controller node is disabled because the leds-turris-omnia driver does not support setting the LED blinking to be controlled by the MCU.
The patches for that have now been sent [1], so let's enable the node.
[1] https://lore.kernel.org/linux-leds/[email protected]/T/
--- arch/arm/boot/dts/armada-385-turris-omnia.dts | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)
arch/arm/boot/dts/armada-385-turris-omnia.dts +2 -5
@@ -191,15 +191,13 @@ led-controller@2b { reg = <0x2b>; #address-cells = <1>; #size-cells = <0>; + status = "okay"; /* * LEDs are controlled by MCU (STM32F0) at * address 0x2b. * - * The driver does not support HW control mode - * for the LEDs yet. Disable the LEDs for now. - * - * Also LED functions are not stable yet: + * LED functions are not stable yet: * - there are 3 LEDs connected via MCU to PCIe * ports. One of these ports supports mSATA. * There is no mSATA nor PCIe function.
@@ -210,7 +208,6 @@ led-controller@2b { * B. Again there is no such function defined. * For now we use LED_FUNCTION_INDICATOR */ - status = "disabled"; multi-led@0 { reg = <0x0>;
Signature · 7 lines
2.35.1 _______________________________________________ linux-arm-kernel mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Quoted 6 lines · Marek Behún
The marvell PHY driver changes the LED[0] pin function to "On - 1000 Mbps Link, Off - Else".
Turris Omnia expects that the function is "On - Link, Blink - Activity, Off - No link".
Quoted 7 lines
Use the
marvell,reg-initDT property to change the function.In the future, once netdev trigger will support HW offloading, we will be able to have this configured via the combination of PHY driver and leds-turris-omnia driver.
Signed-off-by Marek Behún <[email protected]>
Applied on mvebu/dt
Thanks,
Gregory
Quoted 21 lines
--- arch/arm/boot/dts/armada-385-turris-omnia.dts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)arch/arm/boot/dts/armada-385-turris-omnia.dts +2
-1@@ -397,7 +397,8 @@ &mdio { phy1: ethernet-phy@1 { compatible = "ethernet-phy-ieee802.3-c22"; reg = <1>; - marvell,reg-init = <3 18 0 0x4985>; + marvell,reg-init = <3 18 0 0x4985>, + <3 16 0xfff0 0x0001>; /* irq is connected to &pcawan pin 7 */ };Signature · 1 line
2.35.1
Signature · 8 lines
Gregory Clement, Bootlin Embedded Linux and Kernel engineering http://bootlin.com _______________________________________________ linux-arm-kernel mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Re: [PATCH mvebu/dt 2/2] ARM: dts: turris-omnia: enable LED controller node
In reply to Marek BehúnQuoted 8 lines · Marek Behún
The LED controller node is disabled because the leds-turris-omnia driver does not support setting the LED blinking to be controlled by the MCU.
The patches for that have now been sent [1], so let's enable the node.
[1] https://lore.kernel.org/linux-leds/[email protected]/T/
Signed-off-by Marek Behún <[email protected]>
Applied on mvebu/dt
Thanks,
Gregory
Quoted 37 lines
--- arch/arm/boot/dts/armada-385-turris-omnia.dts | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)arch/arm/boot/dts/armada-385-turris-omnia.dts +2
-5@@ -191,15 +191,13 @@ led-controller@2b { reg = <0x2b>; #address-cells = <1>; #size-cells = <0>; + status = "okay"; /* * LEDs are controlled by MCU (STM32F0) at * address 0x2b. * - * The driver does not support HW control mode - * for the LEDs yet. Disable the LEDs for now. - * - * Also LED functions are not stable yet: + * LED functions are not stable yet: * - there are 3 LEDs connected via MCU to PCIe * ports. One of these ports supports mSATA. * There is no mSATA nor PCIe function.@@ -210,7 +208,6 @@ led-controller@2b { * B. Again there is no such function defined. * For now we use LED_FUNCTION_INDICATOR */ - status = "disabled"; multi-led@0 { reg = <0x0>;Signature · 1 line
2.35.1
Signature · 8 lines
Gregory Clement, Bootlin Embedded Linux and Kernel engineering http://bootlin.com _______________________________________________ linux-arm-kernel mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-arm-kernel