From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lj1-f195.google.com (mail-lj1-f195.google.com [209.85.208.195]) by dpdk.org (Postfix) with ESMTP id 5B1171B002 for ; Fri, 24 Aug 2018 19:53:41 +0200 (CEST) Received: by mail-lj1-f195.google.com with SMTP id p10-v6so7510338ljg.2 for ; Fri, 24 Aug 2018 10:53:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=semihalf-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to :user-agent; bh=QRbv7yj6l+s1ka2AcxOWu4aNsS3vRNwvixmfGQqC4mw=; b=fwjLN8JCIDOhMJIJpeTH5PrGYq11acAz71LqEZq9foTmcsBqsUvGbWwmKZEk99yYXN 6MoqvgZH91glimSsCdtjJcXqVfTU+xnaa0/YSCex0OVcUxDqlffHQVsfgrWvOV7Ge0pa HVJ66NfayAhKRcY563oMpOrfo9mlsTeyX9tvOl6tXmmu60rEAXVVuB6DeuV7J3zme2qW T/gvoeAz6P/j5Zbc8iASd8YD6f+c6BxS12+u1TEQht5D/d3tTEzqHGZV7iQMWE2X/Z8r zi3rXqhT3C1LenXYyh00uOt9ldYZFST0d+VhS8htm3TwbVSspo+HjRECG8Ly23qpP1Yp WwuQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to:user-agent; bh=QRbv7yj6l+s1ka2AcxOWu4aNsS3vRNwvixmfGQqC4mw=; b=h03qQpfArY03snPBw/7XBZWNmviUSRWxl9A6YUpFMnLkSn63bQNAXcxZ1T2MU8CPo5 33cKXfiYUJsnujL0jJ/vDeqYalXjNT4MoM0AkZjWC15Hey20gu1AVpGgG3ggV44hbyw2 2wPMqZTNFLVf6GLw5OFmbiS84BLPkm9GFJuB+UnqGv1NBrsHsGm3zygJqj/CfEM4xUAS fLLr98p2g24VrFx20akzFzospQboVQMUl0Le4KJMLBCSKwISV0rX1iK6QkP22ZIcXI5R 0Ok7Iw0ycGu2ufiTDRJTWsBpSESknxIIYg1XaGSremWxJ4/1Y+jmn7sGL3X1BWmda0Nn YS2A== X-Gm-Message-State: APzg51DzSHd8sr1xP3q9SEJDl3/399sgMauBCiQu0owMm5oyAqFSiy+U DOR40nR4qwftAJk0iGWG/5bVyUEdV8Y= X-Google-Smtp-Source: ANB0Vdbxy3UOf6MzBwedsroV7IO+cU+zcLo+XegWa7ii5eEQzkUPqhqWtAtmOTARdlQLuZYLd+Aihw== X-Received: by 2002:a2e:712:: with SMTP id 18-v6mr2115623ljh.101.1535133221045; Fri, 24 Aug 2018 10:53:41 -0700 (PDT) Received: from localhost (31-172-191-173.noc.fibertech.net.pl. [31.172.191.173]) by smtp.gmail.com with ESMTPSA id a66-v6sm1430615lfa.93.2018.08.24.10.53.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 24 Aug 2018 10:53:40 -0700 (PDT) Date: Fri, 24 Aug 2018 19:53:39 +0200 From: Tomasz Duszynski To: Ferruh Yigit Cc: Tomasz Duszynski , dev@dpdk.org, nsamsono@marvell.com, mw@semihalf.com, stable@dpdk.org Message-ID: <20180824175339.GC32439@sh> References: <1535113006-9393-1-git-send-email-tdu@semihalf.com> <1535122494-30249-1-git-send-email-tdu@semihalf.com> <1535122494-30249-4-git-send-email-tdu@semihalf.com> <19ae9e13-cd6f-2f77-fd29-efe54d43088e@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable In-Reply-To: <19ae9e13-cd6f-2f77-fd29-efe54d43088e@intel.com> User-Agent: Mutt/1.5.23.1 (2014-03-12) Subject: Re: [dpdk-stable] [dpdk-dev] [PATCH v2 3/6] net/mvpp2: fix array initialization X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 24 Aug 2018 17:53:41 -0000 On Fri, Aug 24, 2018 at 05:46:42PM +0100, Ferruh Yigit wrote: > On 8/24/2018 3:54 PM, Tomasz Duszynski wrote: > > Fix used_bpools array initialization by using range initializer. > > This way all necessary variables are properly initialized regardless > > of PP2_NUM_PKT_PROC value. > > > > Fixes: 0ddc9b815b11 ("net/mrvl: add net PMD skeleton") > > Cc: stable@dpdk.org > > > > Signed-off-by: Tomasz Duszynski > > --- > > drivers/net/mvpp2/mrvl_ethdev.c | 3 +-- > > 1 file changed, 1 insertion(+), 2 deletions(-) > > > > diff --git a/drivers/net/mvpp2/mrvl_ethdev.c b/drivers/net/mvpp2/mrvl_e= thdev.c > > index 7ea8946..60ca6e0 100644 > > --- a/drivers/net/mvpp2/mrvl_ethdev.c > > +++ b/drivers/net/mvpp2/mrvl_ethdev.c > > @@ -84,8 +84,7 @@ static const char * const valid_args[] =3D { > > static int used_hifs =3D MRVL_MUSDK_HIFS_RESERVED; > > static struct pp2_hif *hifs[RTE_MAX_LCORE]; > > static int used_bpools[PP2_NUM_PKT_PROC] =3D { > > - MRVL_MUSDK_BPOOLS_RESERVED, > > - MRVL_MUSDK_BPOOLS_RESERVED > > + [0 ... PP2_NUM_PKT_PROC - 1] =3D MRVL_MUSDK_BPOOLS_RESERVED > > range initializer is not part of standard, although I am sure this won't = be > first GCC extension we rely on, and I don't have any other option than me= mset > for this. > > So just a reminder about extension usage, if you are happy with this > implementation, lets keep it. I would prefer to leave it as is. As you pointed out DPDK has already started using it anyway. -- - Tomasz Duszy=C5=84ski