[PATCH 09/12] vdpa/ifc: fix build with GCC 12

Stephen Hemminger stephen at networkplumber.org
Sat Jun 11 17:36:33 CEST 2022


On Wed, 18 May 2022 12:16:54 +0200
David Marchand <david.marchand at redhat.com> wrote:

> GCC 12 raises the following warning:
> 
> ../drivers/vdpa/ifc/ifcvf_vdpa.c: In function ‘vdpa_enable_vfio_intr’:
> ../drivers/vdpa/ifc/ifcvf_vdpa.c:383:62: error: writing 4 bytes into a
>     region of size 0 [-Werror=stringop-overflow=]
>   383 |                         fd_ptr[RTE_INTR_VEC_RXTX_OFFSET + i] = fd;
>       |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~
> ../drivers/vdpa/ifc/ifcvf_vdpa.c:348:14: note: at offset 32 into
>     destination object ‘irq_set_buf’ of size 32
>   348 |         char irq_set_buf[MSIX_IRQ_SET_BUF_LEN];
>       |              ^~~~~~~~~~~
> 
> Validate number of vrings to avoid out of bound access.
> 
> Cc: stable at dpdk.org
> 
> Signed-off-by: David Marchand <david.marchand at redhat.com>


Acked-by: Stephen Hemminger <stephen at networkplumber.org>


More information about the stable mailing list