On 4/6/25 3:02 PM, Lucien.Jheng wrote:
Add the driver for the Airoha EN8811H 2.5 Gigabit PHY. The PHY supports
100/1000/2500 Mbps with auto negotiation only.

The driver uses two firmware files, for which updated versions are added to
linux-firmware already.

Based on the Linux upstream 8811 driver code(air_en8811h.c),
I have modified the relevant process to align with the U-Boot boot sequence.
and have validated this on Banana Pi BPI-R3 Mini.

The MD32 FW is currently stored in eMMC partition 1 on Banana Pi BPI-R3 Mini,
and it is loaded from there.

If this is ported from Linux, please include Linux commit SHA from which this is ported.

diff --git a/drivers/net/phy/Kconfig b/drivers/net/phy/Kconfig
index 3132718e4f8..5b4cf30b0a3 100644
--- a/drivers/net/phy/Kconfig
+++ b/drivers/net/phy/Kconfig
@@ -79,6 +79,40 @@ config PHY_ADIN
        help
                Add support for configuring RGMII on Analog Devices ADIN PHYs.
+menuconfig PHY_AIROHA
+       bool "Airoha Ethernet PHYs support"
+
+config PHY_AIROHA_EN8811H
+       bool "Airoha Ethernet EN8811H support"
+       depends on PHY_AIROHA
+       help
+               AIROHA EN8811H supported.
+
+choice
+       prompt "Location of the Airoha PHY firmware"

Can this do the same thing as Aquatia PHY and load the PHY firmware from filesystem on block device instead , using the blk* or fs* commands ? Then the hard-coded filesize and co. won't be necessary.

If you need board specific loading override, implement __weak default loading from file on filesystem by default (see what Aquatia does) and then override the loading function on board or architecture level.

U-Boot really needs a proper generic firmware loader, because this firmware stuff keeps showing up more and more, but I cannot ask you to write one only because of this PHY ... but if you are up for a challenge ...

[...]

Reply via email to