net: dsa: qca8k: initial conversion to regmap helper
authorAnsuel Smith <ansuelsmth@gmail.com>
Mon, 22 Nov 2021 15:23:44 +0000 (16:23 +0100)
committerDavid S. Miller <davem@davemloft.net>
Mon, 22 Nov 2021 15:35:16 +0000 (15:35 +0000)
commit8b5f3f29a81a71934d004e21a1292c1148b05926
treec5032b631e6c286066edc93545cb5613215eeac0
parent36b8af12f424e7a7f60a935c60a0fd4aa0822378
net: dsa: qca8k: initial conversion to regmap helper

Convert any qca8k set/clear/pool to regmap helper and add
missing config to regmap_config struct.
Read/write/rmw operation are reworked to use the regmap helper
internally to keep the delta of this patch low. These additional
function will then be dropped when the code split will be proposed.

Ipq40xx SoC have the internal switch based on the qca8k regmap but use
mmio for read/write/rmw operation instead of mdio.
In preparation for the support of this internal switch, convert the
driver to regmap API to later split the driver to common and specific
code. The overhead introduced by the use of regamp API is marginal as the
internal mdio will bypass it by using its direct access and regmap will be
used only by configuration functions or fdb access.

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/dsa/qca8k.c