net: dsa: mt7530: use priv->ds->num_ports instead of MT7530_NUM_PORTS
authorArınç ÜNAL <arinc.unal@arinc9.com>
Mon, 22 Apr 2024 07:15:20 +0000 (10:15 +0300)
committerDavid S. Miller <davem@davemloft.net>
Wed, 24 Apr 2024 10:57:03 +0000 (11:57 +0100)
commit318c1944710a90ab8734aa2d87472e2bc3f98677
tree16bf4476286a97c232b515aab87b9b7274852e90
parentaa16e1fc9ea808130ecf72bd6fac2ad481002ffb
net: dsa: mt7530: use priv->ds->num_ports instead of MT7530_NUM_PORTS

Use priv->ds->num_ports on all for loops which configure the switch
registers. In the future, the value of MT7530_NUM_PORTS will depend on
priv->id. Therefore, this change prepares the subdriver for a simpler
implementation.

Signed-off-by: Arınç ÜNAL <arinc.unal@arinc9.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/dsa/mt7530.c