diff options
| author | Markus Stockhausen | 2025-06-03 14:35:29 +0000 |
|---|---|---|
| committer | Robert Marko | 2025-06-11 20:27:22 +0000 |
| commit | debb69ccb5cf5a0c677d27187af20ce7bcce2c18 (patch) | |
| tree | cb4f612c823696540c4345773a9c2efd42a2ff99 | |
| parent | 8917301b7260c6092cbda2bf50c9e7fdc834a589 (diff) | |
| download | openwrt-debb69ccb5cf5a0c677d27187af20ce7bcce2c18.tar.gz | |
realtek: 6.12: enhance mdio max port patch (once again)
Some bits where missed during the last enhancement of the mdio
patch. In the forthcoming patches the phy_mask will be populated
to avoid unwanted ports (>= cpu port) from being scanned. Add
additional locations where 32 bit values need to be converted
to 64 bits.
Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/18935
Signed-off-by: Robert Marko <robimarko@gmail.com>
| -rw-r--r-- | target/linux/realtek/patches-6.12/700-dsa-mdio-increase-max-ports-for-rtl839x-rtl931x.patch | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/target/linux/realtek/patches-6.12/700-dsa-mdio-increase-max-ports-for-rtl839x-rtl931x.patch b/target/linux/realtek/patches-6.12/700-dsa-mdio-increase-max-ports-for-rtl839x-rtl931x.patch index 3db46a2285..1485b79263 100644 --- a/target/linux/realtek/patches-6.12/700-dsa-mdio-increase-max-ports-for-rtl839x-rtl931x.patch +++ b/target/linux/realtek/patches-6.12/700-dsa-mdio-increase-max-ports-for-rtl839x-rtl931x.patch @@ -130,3 +130,23 @@ Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de> return ds->ops->phy_write(ds, addr, reg, val); return 0; +--- a/drivers/net/phy/mdio_bus.c ++++ b/drivers/net/phy/mdio_bus.c +@@ -611,7 +611,7 @@ static int mdiobus_scan_bus_c22(struct m + int i; + + for (i = 0; i < PHY_MAX_ADDR; i++) { +- if ((bus->phy_mask & BIT(i)) == 0) { ++ if ((bus->phy_mask & BIT_ULL(i)) == 0ULL) { + struct phy_device *phydev; + + phydev = mdiobus_scan_c22(bus, i); +@@ -627,7 +627,7 @@ static int mdiobus_scan_bus_c45(struct m + int i; + + for (i = 0; i < PHY_MAX_ADDR; i++) { +- if ((bus->phy_mask & BIT(i)) == 0) { ++ if ((bus->phy_mask & BIT_ULL(i)) == 0ULL) { + struct phy_device *phydev; + + /* Don't scan C45 if we already have a C22 device */ |