]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5: DR, Handle ICM memory via buddy allocation instead of buckets
authorYevgeny Kliteynik <kliteyn@nvidia.com>
Mon, 14 Sep 2020 12:05:56 +0000 (15:05 +0300)
committerSaeed Mahameed <saeedm@nvidia.com>
Thu, 5 Nov 2020 20:09:29 +0000 (12:09 -0800)
commit38591a405eaed5e9269091ff5056daac2ee36f5d
treea6b37b4856075023255829b33393a6ec21d2e864
parent75e68072b102642891c629f33d6424dfaa68cda0
net/mlx5: DR, Handle ICM memory via buddy allocation instead of buckets

Till now in order to manage the ICM memory we used bucket
mechanism, which kept a bucket per specified size (sizes were
between 1 block to 2^21 blocks).

Now changing that with buddy-system mechanism, which gives us much
more flexible way to manage the ICM memory.
Its biggest advantage over the bucket is by using the same ICM memory
area for all the sizes of blocks, which reduces the memory consumption.

Signed-off-by: Erez Shitrit <erezsh@nvidia.com>
Signed-off-by: Yevgeny Kliteynik <kliteyn@nvidia.com>
Reviewed-by: Mark Bloch <mbloch@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
drivers/net/ethernet/mellanox/mlx5/core/steering/dr_icm_pool.c
drivers/net/ethernet/mellanox/mlx5/core/steering/dr_types.h