Re: [PATCH] gpio: dwapb: reduce allocation to single kzalloc
From: Linus Walleij
Date: Fri Mar 20 2026 - 09:40:52 EST
On Fri, Mar 20, 2026 at 1:53 AM Rosen Penev <rosenp@xxxxxxxxx> wrote:
> Instead of kzalloc + kcalloc, Combine the two using a flexible array
> member.
>
> Allows using __counted_by for extra runtime analysis. Move counting
> variable to right after allocation as required by __counted_by.
>
> Signed-off-by: Rosen Penev <rosenp@xxxxxxxxx>
Reviewed-by: Linus Walleij <linusw@xxxxxxxxxx>
Yours,
Linus Walleij