Re: [PATCH] net: stmmac: Avoid VLA usage

From: David Miller
Date: Wed May 02 2018 - 11:11:55 EST


From: Kees Cook <keescook@xxxxxxxxxxxx>
Date: Tue, 1 May 2018 14:01:30 -0700

> In the quest to remove all stack VLAs from the kernel[1], this switches
> the "status" stack buffer to use the existing small (8) upper bound on
> how many queues can be checked for DMA, and adds a sanity-check just to
> make sure it doesn't operate under pathological conditions.
>
> [1] http://lkml.kernel.org/r/CA+55aFzCG-zNmZwX4A2FQpadafLfEzK6CC=qPXydAacU1RqZWA@xxxxxxxxxxxxxx
>
> Signed-off-by: Kees Cook <keescook@xxxxxxxxxxxx>

Applied to net-next, thank you.