[PATCH 08/12] net/qede/base: fix build with GCC 12
Stephen Hemminger
stephen at networkplumber.org
Fri May 20 22:29:58 CEST 2022
On Wed, 18 May 2022 12:16:53 +0200
David Marchand <david.marchand at redhat.com> wrote:
> GCC raises the following warning:
>
> In function ‘_mm256_storeu_si256’,
> inlined from ‘rte_mov32’ at
> ../lib/eal/x86/include/rte_memcpy.h:320:2,
> inlined from ‘rte_mov128’ at
> ../lib/eal/x86/include/rte_memcpy.h:342:2,
> inlined from ‘rte_memcpy_generic’ at
> ../lib/eal/x86/include/rte_memcpy.h:438:4,
> inlined from ‘rte_memcpy’ at
> ../lib/eal/x86/include/rte_memcpy.h:882:10,
> inlined from ‘__ecore_mcp_cmd_and_union’ at
> ../drivers/net/qede/base/ecore_mcp.c:541:3,
> inlined from ‘_ecore_mcp_cmd_and_union’ at
> ../drivers/net/qede/base/ecore_mcp.c:638:2,
> inlined from ‘ecore_mcp_cmd_and_union’ at
> ../drivers/net/qede/base/ecore_mcp.c:742:9:
> /usr/lib/gcc/x86_64-redhat-linux/12/include/avxintrin.h:935:8: error:
> array subscript 1 is outside array bounds of
> ‘union drv_union_data[1]’ [-Werror=array-bounds]
> 935 | *__P = __A;
> | ~~~~~^~~~~
> ../drivers/net/qede/base/ecore_mcp.c: In function
> ‘ecore_mcp_cmd_and_union’:
> ../drivers/net/qede/base/ecore_mcp.c:533:30: note: at offset 32 into
> object ‘union_data’ of size 32
> 533 | union drv_union_data union_data;
> | ^~~~~~~~~~
>
> Since this code is in the base driver, waive the check until the base
> driver is fixed by the relevant people.
>
> Cc: stable at dpdk.org
>
> Signed-off-by: David Marchand <david.marchand at redhat.com>
Or mark driver broken with gcc-12 and get the maintainer to fix?
More information about the dev
mailing list