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 7B746A0503 for ; Wed, 18 May 2022 12:18:17 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 747A242B83; Wed, 18 May 2022 12:18:17 +0200 (CEST) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mails.dpdk.org (Postfix) with ESMTP id DBC7842B6F for ; Wed, 18 May 2022 12:18:14 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1652869094; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=dp47vNQsjcDqvx78LnQOiHpVNC0tzvJ86tJG/uIg9Ck=; b=K89SFAMFaD1mxTxyEikCHpp8BWi5gXYRs37QqIe5Q2T41S/rGq5eTYNTWuisozmv/hFFv4 NlDB4cpUOwIs1D1sXppGkqfp9gtH3Bwruzg4vdZ1A5W5r1bzqO742QLuWV/xBV2hRtcEv+ zNPjvGN1dPhw1GqIB3a5NL0SfhzqiqQ= Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-356-k7ZCweX_PwClvlTHG3fgxQ-1; Wed, 18 May 2022 06:18:03 -0400 X-MC-Unique: k7ZCweX_PwClvlTHG3fgxQ-1 Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.rdu2.redhat.com [10.11.54.10]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 870A43C1618C; Wed, 18 May 2022 10:18:03 +0000 (UTC) Received: from fchome.home (unknown [10.40.195.61]) by smtp.corp.redhat.com (Postfix) with ESMTP id 710BB492C14; Wed, 18 May 2022 10:18:00 +0000 (UTC) From: David Marchand To: dev@dpdk.org Cc: thomas@monjalon.net, ferruh.yigit@xilinx.com, stable@dpdk.org, Rasesh Mody , Devendra Singh Rawat Subject: [PATCH 08/12] net/qede/base: fix build with GCC 12 Date: Wed, 18 May 2022 12:16:53 +0200 Message-Id: <20220518101657.1230416-9-david.marchand@redhat.com> In-Reply-To: <20220518101657.1230416-1-david.marchand@redhat.com> References: <20220518101657.1230416-1-david.marchand@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.85 on 10.11.54.10 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=david.marchand@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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 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@dpdk.org Signed-off-by: David Marchand --- drivers/net/qede/base/meson.build | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/net/qede/base/meson.build b/drivers/net/qede/base/meson.build index 4ad177b478..c7b19be20a 100644 --- a/drivers/net/qede/base/meson.build +++ b/drivers/net/qede/base/meson.build @@ -44,6 +44,11 @@ error_cflags = [ '-Wno-sometimes-uninitialized', '-Wno-pointer-bool-conversion', ] +# FIXME +if (toolchain == 'gcc' and cc.version().version_compare('>=12.0.0')) + error_cflags += ['-Wno-array-bounds'] +endif + c_args = cflags foreach flag: error_cflags if cc.has_argument(flag) -- 2.36.1