octeontx2-af: Skip CGX/RPM probe incase of zero lmac count
authorHariprasad Kelam <hkelam@marvell.com>
Tue, 12 Jul 2022 06:42:50 +0000 (12:12 +0530)
committerDavid S. Miller <davem@davemloft.net>
Wed, 13 Jul 2022 12:41:31 +0000 (13:41 +0100)
commit3e35d198cee665efcf7b9ee01f443c263be73296
treee7b4995d7eb13a87764b982254e3258ff86c3757
parent4fb56d8508ed1aa078ef1076c8df3c147f4d8421
octeontx2-af: Skip CGX/RPM probe incase of zero lmac count

In few error cases MAC(CGX/RPM) block is having 0 lmacs.
AF driver uses MAC block with lmac pair to get firmware
data etc. These commands will fail as there is no LMAC
associated with MAC block.

This patch skips the probe of these MAC blocks such that AF driver
uses correct MAC block and LMAC pair for firmware communication and
define new LMAC_AF_ERROR types for command timeout etc.

This patch also enables channel back pressure for all LMACs.

Signed-off-by: Hariprasad Kelam <hkelam@marvell.com>
Signed-off-by: Sunil Kovvuri Goutham <sgoutham@marvell.com>
Signed-off-by: Geetha sowjanya <gakula@marvell.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/marvell/octeontx2/af/cgx.c
drivers/net/ethernet/marvell/octeontx2/af/mbox.h
drivers/net/ethernet/marvell/octeontx2/af/rpm.c
drivers/net/ethernet/marvell/octeontx2/af/rpm.h
drivers/net/ethernet/marvell/octeontx2/af/rvu_cgx.c