Re: [PATCH bpf-next v2 07/20] bpf: Use map_extra to indicate the max data size of dynptrs in map key

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Jan 25, 2025 at 2:59 AM Hou Tao <houtao@xxxxxxxxxxxxxxx> wrote:
>
> From: Hou Tao <houtao1@xxxxxxxxxx>
>
> For map with dynptr key support, it needs to use map_extra to specify
> the maximum data length of these dynptrs. The implementation of the map
> will check whether map_extra is smaller than the limitation imposed by
> memory allocation during map creation. It may also use map_extra to
> optimize the memory allocation for dynptr.

Why limit it?
The only piece of code I could find is:

uptr->size > map->map_extra

and it doesn't look necessary.
Let it consume whatever necessary ?





[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux