Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ec777e6b authored by Andrew Lunn's avatar Andrew Lunn Committed by David S. Miller
Browse files

dsa: dsa: Fix freeing of fixed-phys from user ports.



All ports types can have a fixed PHY associated with it. Remove the
check which limits removal to only CPU and DSA ports.

Signed-off-by: default avatarAndrew Lunn <andrew@lunn.ch>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 3a44514f
Loading
Loading
Loading
Loading
+0 −3
Original line number Diff line number Diff line
@@ -443,9 +443,6 @@ static void dsa_switch_destroy(struct dsa_switch *ds)

	/* Remove any fixed link PHYs */
	for (port = 0; port < DSA_MAX_PORTS; port++) {
		if (!(dsa_is_cpu_port(ds, port) || dsa_is_dsa_port(ds, port)))
			continue;

		port_dn = cd->port_dn[port];
		if (of_phy_is_fixed_link(port_dn)) {
			phydev = of_phy_find_device(port_dn);