]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
octeontx2-af: Fix initialization of mcam's entry2target_pffunc field
authorSuman Ghosh <sumang@marvell.com>
Fri, 29 May 2026 11:37:05 +0000 (17:07 +0530)
committerJakub Kicinski <kuba@kernel.org>
Thu, 4 Jun 2026 01:12:02 +0000 (18:12 -0700)
commit9a85ec3dc28b6df246801c19e4d9bae6297a25b0
tree5df474986ca676b19690f5cd844b9bdea27ad4ec
parenta910fb8f7b9e4c566db363e6c2ec378dc7153995
octeontx2-af: Fix initialization of mcam's entry2target_pffunc field

NPC mcam entry stores a mapping between mcam entry and target pcifunc.
During initialization of this field, API kmalloc_array has been used which
caused some junk values to array. Whereas, the array is expected to be
initialized by 0. This patch fixes the same by using kcalloc instead of
kmalloc_array.

Fixes: 55307fcb9258 ("octeontx2-af: Add mbox messages to install and delete MCAM rules")
Signed-off-by: Suman Ghosh <sumang@marvell.com>
Signed-off-by: Subbaraya Sundeep <sbhatta@marvell.com>
Reviewed-by: Simon Horman <horms@kernel.org>
Link: https://patch.msgid.link/1780054625-17090-1-git-send-email-sbhatta@marvell.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/marvell/octeontx2/af/rvu_npc.c