octeontx2-af: Cleanup CGX config permission checks
authorSunil Goutham <sgoutham@marvell.com>
Wed, 19 Feb 2020 09:51:07 +0000 (15:21 +0530)
committerDavid S. Miller <davem@davemloft.net>
Wed, 19 Feb 2020 18:51:12 +0000 (10:51 -0800)
commit6fd2a71b273871897d5186e49e430a1f8a13e1ca
tree0a520ff49541572ee57686b597d1e686116100c5
parent07a835d939af8ed63077e2bac263f8d3ea162338
octeontx2-af: Cleanup CGX config permission checks

Most of the CGX register config is restricted to mapped RVU PFs,
this patch cleans up these permission checks spread across
the rvu_cgx.c file by moving the checks to a common fn().

Signed-off-by: Sunil Goutham <sgoutham@marvell.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/marvell/octeontx2/af/rvu_cgx.c