OSDN Git Service

net: mscc: ocelot: use helpers for port VLAN membership
authorVladimir Oltean <vladimir.oltean@nxp.com>
Thu, 19 Aug 2021 17:40:08 +0000 (20:40 +0300)
committerDavid S. Miller <davem@davemloft.net>
Fri, 20 Aug 2021 13:39:52 +0000 (14:39 +0100)
commitbbf6a2d92361a126f77a29f70a773736c5339f6d
tree1d330fe817ec0dd8fa78f1539858e3e8748a39e6
parent3b95d1b29386dd4328e471fda2eee74b7fd4a4b3
net: mscc: ocelot: use helpers for port VLAN membership

This is a mostly cosmetic patch that creates some helpers for accessing
the VLAN table. These helpers are also a bit more careful in that they
do not modify the ocelot->vlan_mask unless the hardware operation
succeeded.

Not all callers check the return value (the init code doesn't), but anyway.

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