[lkml]   [2018]   [May]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCHv9] gpio: Remove VLA from gpiolib
On Mon, May 21, 2018 at 7:57 PM, Laura Abbott <> wrote:

> The new challenge is to remove VLAs from the kernel
> (see to eventually
> turn on -Wvla.
> Using a kmalloc array is the easy way to fix this but kmalloc is still
> more expensive than stack allocation. Introduce a fast path with a
> fixed size stack array to cover most chip with gpios below some fixed
> amount. The slow path dynamically allocates an array to cover those
> chips with a large number of gpios.
> Reviewed-by: Geert Uytterhoeven <>
> Reviewed-by: Phil Reid <>
> Reviewed-and-tested-by: Lukas Wunner <>
> Signed-off-by: Lukas Wunner <>
> Signed-off-by: Laura Abbott <>
> ---
> v9: switch to bitmap_zero

This v9 applied with Andy's review tag on top and pushed to
the servers for testing!

THANKS A LOT for your tireless work on this, it looks really
really good now, and as it seems we cleaned up some other
code on the way.

Linus Walleij

 \ /
  Last update: 2018-05-23 14:03    [W:0.034 / U:2.924 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site