net: mscc: ocelot: split assignment of the cpu port into a separate function
authorVladimir Oltean <vladimir.oltean@nxp.com>
Sat, 9 Nov 2019 13:03:00 +0000 (15:03 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 11 Nov 2019 20:59:10 +0000 (12:59 -0800)
commit21468199016f4e4983c7c22368d1cfba3914facb
treef885e56527e0a0100c4b5186426706409eac4b50
parent26f4dbab7de240f697cbe4d46dfc37b8a7e58d70
net: mscc: ocelot: split assignment of the cpu port into a separate function

Now that the places that configure routing destinations for the CPU port
have been marked as such, allow callers to specify their own CPU port
that is different than ocelot->num_phys_ports. A user will be the Felix
DSA driver, where the CPU port is one of the physical ports (NPI mode).

Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mscc/ocelot.c
drivers/net/ethernet/mscc/ocelot.h
drivers/net/ethernet/mscc/ocelot_board.c