[PATCH v2] nvme: fix incorrect sizeof
Jens Axboe
axboe at kernel.dk
Tue May 6 12:47:01 PDT 2025
On 5/6/25 12:48 PM, Kanchan Joshi wrote:
> The plid array, head->plids, is meant to store placement IDs, each of
> type u16. But its size has been incorrectly calculated, as the size of
> the pointer is being used instead of the size of the object it points
> to.
>
> Use the sizeof(*head->plids) in kcalloc so that we don't allocate extra.
For some reason this isn't on lore, I hand applied it.
--
Jens Axboe
More information about the Linux-nvme
mailing list