octeontx2-af: Clear NPC MCAM entries before update
authorNithin Dabilpuram <ndabilpuram@marvell.com>
Thu, 14 Nov 2019 05:26:27 +0000 (10:56 +0530)
committerDavid S. Miller <davem@davemloft.net>
Fri, 15 Nov 2019 02:09:16 +0000 (18:09 -0800)
commit8cc89ae92518cac06afc0faf58d15322d88043e2
tree48936e393f3c902198a3c20415a833ea4d225281
parent922584f607525982e5c99a772bae408ad9407c69
octeontx2-af: Clear NPC MCAM entries before update

Writing into NPC MCAM1 and MCAM0 registers are suppressed if
they happened to form a reserved combination. Hence
clear and disable MCAM entries before update.

For HRM:
[CAM(1)]<n>=1, [CAM(0)]<n>=1: Reserved.
The reserved combination is not allowed. Hardware suppresses any
write to CAM(0) or CAM(1) that would result in the reserved combination for
any CAM bit.

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