29/09/2022 09:01, Akhil Goyal: > > Adds the __extension__ attribute to resolve the following warning > > with gcc 4.8.5 on CentOS 7: > > lib/net/rte_macsec.h:38:2: error: type of bit-field 'short_length' is > > a GCC extension [-Werror=pedantic] > > > > Fixes: 0aaf097585a6 ("ethdev: add MACsec flow item") > > Cc: gak...@marvell.com > > > > Signed-off-by: Ali Alnubani <alia...@nvidia.com> > > --- > > --- a/lib/net/rte_macsec.h > > +++ b/lib/net/rte_macsec.h > > @@ -28,6 +28,7 @@ extern "C" { > > /** > > * MACsec Header (SecTAG) > > */ > > +__extension__ > > RTE_STD_C11 ??
We use RTE_STD_C11 only for anonymous struct and union. I don't know why we don't use it for bitfield in struct. It seems to be part of C11 standard, right? In doubt, I would continue with __extension__ and we can replace all similar occurences in a separate patch, if confirmed it is well defined in C11.