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 DC90AA00C3 for ; Thu, 23 Jun 2022 09:43:14 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id B422D4067B; Thu, 23 Jun 2022 09:43:14 +0200 (CEST) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mails.dpdk.org (Postfix) with ESMTP id 389F14067B for ; Thu, 23 Jun 2022 09:43:13 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1655970192; 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: in-reply-to:in-reply-to:references:references; bh=dPPEwX9ONyIEJkFWHDgOZZlsoRPh5JlE5y+pOK6tItY=; b=UEIX66qCNG0fEF5mqApjB8VOkUHSJMt0VkseiwoloGaeZ+f1+p+Hr5tMSU6GNUyJ1bH0Hf xHX3GoAAN1v3twbe7X5L4u+w/rYZ9HBBkQaTsAko66HDURO0UZTSQsabK4+OF5gOGd+iDv rr09BnG4dFqlxNz7KFUG0JPFYWi13ck= Received: from mail-lf1-f71.google.com (mail-lf1-f71.google.com [209.85.167.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-467-tbPpH6ElP_SD0iYDUYTgqA-1; Thu, 23 Jun 2022 03:43:09 -0400 X-MC-Unique: tbPpH6ElP_SD0iYDUYTgqA-1 Received: by mail-lf1-f71.google.com with SMTP id cf10-20020a056512280a00b0047f5a295656so7043010lfb.15 for ; Thu, 23 Jun 2022 00:43:09 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=dPPEwX9ONyIEJkFWHDgOZZlsoRPh5JlE5y+pOK6tItY=; b=UwoolXqGYPM09gAbFfXoPibJ9WK80AIx/RsZA5Nqkijbxhq60mM+EKQWgqXm335k1A E7npv7T3M17TzGtazNOQWCPbCnxPR350cs5heqfTrAVTCPpbTJubFyN9xoHA7ECsQ3xV QzNalgM7uOSFC9lRZBwERxkoNJq0D/Hg848ouo9yqva6tZewj5aVRTjqorB81f4rJOKi oC8iQYWRF6HUyQtzRg3HAvfrb/8DC8VcFBumNjUARnStCKRhazCe3JmzI+gDvUamxR+I 01jsBWJHY2dEPg0f3FuHoMNjx7rm1QxXtCVdwkvNYnANswC4itGjeIdDTxMN1OdcWEwI nsiQ== X-Gm-Message-State: AJIora+uf7nAfXEwiL5tVK7haQoFY5wAzvYfgN9eI6RnEfe4YE4SgRHl 1Q2Em9CNQrzxSOci+k3sWohFNbdVecWNsHMfj0wlaV//GXoxC6Elhm/xJWSNT6NT9slrdQwJjWr Ey8IAlXCpV9gqEhdDkijUxUQ= X-Received: by 2002:a2e:6e0c:0:b0:255:98fb:cb45 with SMTP id j12-20020a2e6e0c000000b0025598fbcb45mr4107127ljc.55.1655970187843; Thu, 23 Jun 2022 00:43:07 -0700 (PDT) X-Google-Smtp-Source: AGRyM1so3hvdlyUsSFBfPDogHLJPrSh11jGzChAN4l6WOzQ4fyTrTtQtuqLRCyTxhquN6ghg8IvrJKCbSDyw99c3rx0= X-Received: by 2002:a2e:6e0c:0:b0:255:98fb:cb45 with SMTP id j12-20020a2e6e0c000000b0025598fbcb45mr4107112ljc.55.1655970187593; Thu, 23 Jun 2022 00:43:07 -0700 (PDT) MIME-Version: 1.0 References: <20220616103304.132368-1-wenxuanx.wu@intel.com> In-Reply-To: From: David Marchand Date: Thu, 23 Jun 2022 09:42:56 +0200 Message-ID: Subject: Re: [PATCH] ice/base: fix gcc 12 warning stringop-overflow To: "Wu, WenxuanX" , "Zhang, Qi Z" Cc: "Yang, Qiming" , "dev@dpdk.org" , "thomas@monjalon.net" , "stephen@networkplumber.org" , "stable@dpdk.org" , Ferruh Yigit Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=dmarchan@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="UTF-8" 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 Mon, Jun 20, 2022 at 7:06 AM Wu, WenxuanX wrote: > > > > diff --git a/drivers/net/ice/base/ice_protocol_type.h > > > > b/drivers/net/ice/base/ice_protocol_type.h > > > > index 0e6e5990be..cfe3b62630 100644 > > > > --- a/drivers/net/ice/base/ice_protocol_type.h > > > > +++ b/drivers/net/ice/base/ice_protocol_type.h > > > > @@ -421,7 +421,7 @@ struct ice_recp_grp_entry { #define > > > > ICE_INVAL_CHAIN_IND 0xFF > > > > u16 rid; > > > > u8 chain_idx; > > > > - u16 fv_idx[ICE_NUM_WORDS_RECIPE]; > > > > + u8 fv_idx[ICE_NUM_WORDS_RECIPE]; > > > > > > If you change the data type from u16 to u8 for the FV index, you'd > > > better also change the type of all the symbols to store the same > > > thing. e.g. the parameter "fv_idx" of ice_find_prot_off. > > > So, what's exactly the issue that GCC 12 reported? can we fix it from > > > the other side without changing a type in the base code? > change from u8 lkup_indx[5] to u16 lkup_indx[5] can also resolve this issue. Any update? Thanks. -- David Marchand