Skip to content

Commit b20b001

Browse files
committed
bmips: b53: enable bcm63268 internal PHYs
On the smartrg sr505n the bootloader only sets registers to enable the PHYs if it's interrupted. When Linux boots this results in a -EINVAL error when trying to read from the EPHYs and the GPHY doesn't work. This patch disables low power mode in the GPHY/EPHYs and properly resets the EPHYs. Signed-off-by: Kyle Hendry <kylehendrydev@gmail.com>
1 parent 31f5fc8 commit b20b001

1 file changed

Lines changed: 28 additions & 2 deletions

File tree

target/linux/bmips/dts/bcm63268.dtsi

Lines changed: 28 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -288,6 +288,11 @@
288288
pins = "dsl_gpio9";
289289
};
290290
};
291+
ephy_rst: reset-controller@3C {
292+
compatible = "brcm,bcm6345-reset";
293+
reg = <0x3C 0x4>;
294+
#reset-cells = <1>;
295+
};
291296
};
292297

293298
uart0: serial@10000180 {
@@ -481,8 +486,7 @@
481486
<&timer_clk BCM63268_TCLK_GPHY1>;
482487

483488
resets = <&periph_rst BCM63268_RST_ENETSW>,
484-
<&periph_rst BCM63268_RST_EPHY>,
485-
<&periph_rst BCM63268_RST_GPHY>;
489+
<&periph_rst BCM63268_RST_EPHY>;
486490

487491
power-domains = <&periph_pwr BCM63268_POWER_DOMAIN_ROBOSW>;
488492

@@ -532,6 +536,8 @@
532536
reg = <0x10700000 0x8000>;
533537
big-endian;
534538

539+
brcm,gpio-ctrl = <&gpio_cntl>;
540+
535541
ports {
536542
#address-cells = <1>;
537543
#size-cells = <0>;
@@ -564,21 +570,41 @@
564570
phy1: ethernet-phy@1 {
565571
compatible = "ethernet-phy-ieee802.3-c22";
566572
reg = <1>;
573+
574+
resets = <&ephy_rst 0>;
575+
reset-names = "phy";
576+
reset-assert-us = <2000>;
577+
reset-deassert-us = <2000>;
567578
};
568579

569580
phy2: ethernet-phy@2 {
570581
compatible = "ethernet-phy-ieee802.3-c22";
571582
reg = <2>;
583+
584+
resets = <&ephy_rst 1>;
585+
reset-names = "phy";
586+
reset-assert-us = <2000>;
587+
reset-deassert-us = <2000>;
572588
};
573589

574590
phy3: ethernet-phy@3 {
575591
compatible = "ethernet-phy-ieee802.3-c22";
576592
reg = <3>;
593+
594+
resets = <&ephy_rst 2>;
595+
reset-names = "phy";
596+
reset-assert-us = <2000>;
597+
reset-deassert-us = <2000>;
577598
};
578599

579600
phy4: ethernet-phy@4 {
580601
compatible = "ethernet-phy-ieee802.3-c22";
581602
reg = <4>;
603+
604+
resets = <&periph_rst BCM63268_RST_GPHY>;
605+
reset-names = "phy";
606+
reset-assert-us = <2000>;
607+
reset-deassert-us = <2000>;
582608
};
583609
};
584610

0 commit comments

Comments
 (0)