[PATCH 5/7] nfp: replace zero length array with flex array
Niklas Söderlund
niklas.soderlund at corigine.com
Sun Jan 15 16:22:05 CET 2023
Hi Stephen,
Thanks for your patch.
On 2023-01-13 13:52:03 -0800, Stephen Hemminger wrote:
> Zero length arrays are GNU extension. Replace with
> standard flex array.
>
> Signed-off-by: Stephen Hemminger <stephen at networkplumber.org>
I understand this works might depend on another work to raise the
minimum compiler versions to support this change. Provided this is
sorted out as part of the full series to move to flex arrays, for the
change itself.
Acked-by: Niklas Söderlund <niklas.soderlund at corigine.com>
> ---
> drivers/net/nfp/flower/nfp_flower_cmsg.h | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/nfp/flower/nfp_flower_cmsg.h b/drivers/net/nfp/flower/nfp_flower_cmsg.h
> index 04601cb0bd25..ee8b439d617f 100644
> --- a/drivers/net/nfp/flower/nfp_flower_cmsg.h
> +++ b/drivers/net/nfp/flower/nfp_flower_cmsg.h
> @@ -73,7 +73,7 @@ struct nfp_flower_cmsg_mac_repr {
> uint8_t info;
> uint8_t nbi_port;
> uint8_t phys_port;
> - } ports[0];
> + } ports[];
> };
>
> /*
> --
> 2.39.0
>
--
Kind Regards,
Niklas Söderlund
More information about the dev
mailing list