[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20180307.122541.1396477885969641264.davem@davemloft.net>
Date: Wed, 07 Mar 2018 12:25:41 -0500 (EST)
From: David Miller <davem@...emloft.net>
To: gustavo@...eddedor.com
Cc: santosh@...lsio.com, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org, garsilva@...eddedor.com
Subject: Re: [PATCH] cxgb3: remove VLA
From: "Gustavo A. R. Silva" <gustavo@...eddedor.com>
Date: Mon, 5 Mar 2018 23:39:34 -0600
> In preparation to enabling -Wvla, remove VLA and replace it
> with dynamic memory allocation.
>
> Signed-off-by: Gustavo A. R. Silva <gustavo@...eddedor.com>
All of these lengths are limited by the encoding of the field in the
VPD, which is a u8, and thus 255 bytes.
Please just change the 'len' argument to these functions to a u8 and
use a 256 byte buffer on the stack.
Thanks.
Powered by blists - more mailing lists