Skip to content
Commit 1006ebe9 authored by Atul Raut's avatar Atul Raut Committed by Greg Kroah-Hartman
Browse files

nvmem: u-boot-env:: Replace zero-length array with DECLARE_FLEX_ARRAY() helper



We are moving toward replacing zero-length arrays with C99 flexible-array
members since they are deprecated. Therefore, the new DECLARE_FLEX_ARRAY()
helper macro should be used to replace the zero-length array declaration.

This fixes warnings such as:
./drivers/nvmem/u-boot-env.c:50:9-13: WARNING use flexible-array member instead (https://www.kernel.org/doc/html/latest/process/deprecated.html#zero-length-and-one-element-arrays)

Signed-off-by: default avatarAtul Raut <rauji.raut@gmail.com>
Signed-off-by: default avatarSrinivas Kandagatla <srinivas.kandagatla@linaro.org>
Link: https://lore.kernel.org/r/20230823132744.350618-19-srinivas.kandagatla@linaro.org
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent c471245b
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment