From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 7F8C5A0554 for ; Sat, 11 Jun 2022 17:34:49 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 78CE64280B; Sat, 11 Jun 2022 17:34:49 +0200 (CEST) Received: from mail-pj1-f45.google.com (mail-pj1-f45.google.com [209.85.216.45]) by mails.dpdk.org (Postfix) with ESMTP id 4758040150 for ; Sat, 11 Jun 2022 17:34:47 +0200 (CEST) Received: by mail-pj1-f45.google.com with SMTP id o33-20020a17090a0a2400b001ea806e48c6so2010958pjo.1 for ; Sat, 11 Jun 2022 08:34:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20210112.gappssmtp.com; s=20210112; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=YsbEEOotqAUGUxiL8/qW20c7eMym5aNLl4setaDArpc=; b=EiLd04+Fy487+TgxLyU/++tbmv7DPCURI5DTnSt46Rv9hFwP3B7Egwaj8Dq+CVGjfc tcMjOIRcioD1l0pXp+RF8GV+9TR+p9mU9qgyOyqDbApNsn5Z6ZYMToqj2hLNyPCV/tiz 8HrwM30Cwpl7XWnuy05wUrnU2w/BH2yWH3rDvlSIYR0K//QorOJ+80G/YESeYDEhV9cW 5zoV+ifhFlmeBz7GG2+ftmtFjts2lXJ5N/lD2RPTTO7UypHsufAxswhQJ4Qbk7kFI4xS PrPYfTbicXnmD87F6wfEVvVKhkx/Uvov5NnxVOovwUmkbmWvAgIv8FmEk1mOowIDGynq fZmA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=YsbEEOotqAUGUxiL8/qW20c7eMym5aNLl4setaDArpc=; b=tbeSLOQveJGy/mODmzISco1KFocNmF6R3Q2q07eAhKAsnBJgHCzxu7scI4c8cjDuaU pvVgaNHeiqj52YhV/mA8aUvHl/JalDOPbV4iz/f7OG6eGKKyvbL+qSruqcS7wCmkxEqt smEh+sxAlXEcf6xoqdOmZ87v9MYsJQz641qC5fCo/SC0sXLR5qlbxpD/sQFQjOZnWRv+ EXVT3ht5784jKmuxSTwo7shjJTafnbxPHDjuXBMS8ekMdd6RmyZiY3kkMXKJOG2uhPCU pe30KSmaujoToMi72eHlwVFdslDyo4YmKIWaRIj9bwvBb3MFREFJN995WN550uJ5JxSr 6IvQ== X-Gm-Message-State: AOAM530KCM7owwwxcW92AO7sqSQqKhQgfSyEkaj7dagtDSl2/tEpdb3j 0+9W9hKUyAWfjWXyhbRmR0u8sw7gcivhj5Cs X-Google-Smtp-Source: ABdhPJxRpnFLbD8gVd6v1SFLjFAyyxdhq50VwFrSvrAxOPLNU0MUtcDV/wke8AxglXx0LUbKqxE0wA== X-Received: by 2002:a17:903:4045:b0:168:b7ca:19b0 with SMTP id n5-20020a170903404500b00168b7ca19b0mr9243753pla.66.1654961686470; Sat, 11 Jun 2022 08:34:46 -0700 (PDT) Received: from hermes.local (204-195-112-199.wavecable.com. [204.195.112.199]) by smtp.gmail.com with ESMTPSA id p11-20020a170903248b00b0015e8d4eb1c8sm1700441plw.18.2022.06.11.08.34.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 11 Jun 2022 08:34:46 -0700 (PDT) Date: Sat, 11 Jun 2022 08:34:43 -0700 From: Stephen Hemminger To: David Marchand Cc: dev@dpdk.org, thomas@monjalon.net, ferruh.yigit@xilinx.com, stable@dpdk.org, Marcin Wojtas , Michal Krawczyk , Shai Brandes , Evgeny Schemeilin , Igor Chauskin Subject: Re: [PATCH 04/12] net/ena: fix build with GCC 12 Message-ID: <20220611083443.0318ee73@hermes.local> In-Reply-To: <20220518101657.1230416-5-david.marchand@redhat.com> References: <20220518101657.1230416-1-david.marchand@redhat.com> <20220518101657.1230416-5-david.marchand@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org On Wed, 18 May 2022 12:16:49 +0200 David Marchand wrote: > GCC 12 raises the following warning: >=20 > In file included from ../lib/mempool/rte_mempool.h:46, > from ../lib/mbuf/rte_mbuf.h:38, > from ../lib/net/rte_ether.h:22, > from ../drivers/net/ena/ena_ethdev.h:10, > from ../drivers/net/ena/ena_rss.c:6: > ../drivers/net/ena/ena_rss.c: In function =E2=80=98ena_rss_key_fill=E2=80= =99: > ../lib/eal/x86/include/rte_memcpy.h:370:9: warning: array subscript 64 is > outside array bounds of =E2=80=98uint8_t[40]=E2=80=99 {aka =E2=80= =98unsigned char[40]=E2=80=99} > [-Warray-bounds] > 370 | rte_mov32((uint8_t *)dst + 2 * 32, (const uint8_t *)src + 2 * 32); > | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > ../drivers/net/ena/ena_rss.c:51:24: note: while referencing =E2=80=98defa= ult_key=E2=80=99 > 51 | static uint8_t default_key[ENA_HASH_KEY_SIZE]; > | ^~~~~~~~~~~ >=20 > This is a false positive because the copied size is checked against > ENA_HASH_KEY_SIZE in a (build) assert. > Silence this warning by calling memcpy with the minimal size. >=20 > Cc: stable@dpdk.org >=20 > Signed-off-by: David Marchand > --- Acked-by: Stephen Hemminger