summaryrefslogtreecommitdiff
path: root/include/linux/mbcache.h
diff options
context:
space:
mode:
authorRatheesh Kannoth <rkannoth@marvell.com>2026-02-24 10:59:57 +0300
committerJakub Kicinski <kuba@kernel.org>2026-02-28 21:29:25 +0300
commit1396771b0b7741d517d591cfb63333d3f97a8f6d (patch)
treef8094e3906c45e83209cb9b265e61cb790b70ae8 /include/linux/mbcache.h
parentded4a02e7d0497c91ec8665e904c7dc817922993 (diff)
downloadlinux-1396771b0b7741d517d591cfb63333d3f97a8f6d.tar.xz
octeontx2-af: npc: cn20k: Index management
In CN20K silicon, the MCAM is divided vertically into two banks. Each bank has a depth of 8192. The MCAM is divided horizontally into 32 subbanks, with each subbank having a depth of 256. Each subbank can accommodate either x2 keys or x4 keys. x2 keys are 256 bits in size, and x4 keys are 512 bits in size. Bank1 Bank0 |-----------------------------| | | | subbank 31 { depth 256 } | | | |-----------------------------| | | | subbank 30 | | | ------------------------------ ............................... |-----------------------------| | | | subbank 0 | | | ------------------------------| This patch implements the following allocation schemes in NPC. The allocation API accepts reference (ref), limit, contig, priority, and count values. For example, specifying ref=100, limit=200, contig=1, priority=LOW, and count=20 will allocate 20 contiguous MCAM entries between entries 100 and 200. 1. Contiguous allocation with ref, limit, and priority. 2. Non-contiguous allocation with ref, limit, and priority. 3. Non-contiguous allocation without ref. 4. Contiguous allocation without ref. Signed-off-by: Ratheesh Kannoth <rkannoth@marvell.com> Link: https://patch.msgid.link/20260224080009.4147301-2-rkannoth@marvell.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'include/linux/mbcache.h')
0 files changed, 0 insertions, 0 deletions