patches for DPDK stable branches
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas@monjalon.net>
To: Gregory Etelson <getelson@nvidia.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>, Matan Azrad <matan@nvidia.com>,
	Raslan Darawsheh <rasland@nvidia.com>,
	"stable@dpdk.org" <stable@dpdk.org>,
	Anatoly Burakov <anatoly.burakov@intel.com>,
	"david.marchand@redhat.com" <david.marchand@redhat.com>
Subject: Re: [dpdk-stable] [PATCH v2] examples/multi_proces: fix Rx packets distribution
Date: Tue, 09 Nov 2021 15:17:00 +0100
Message-ID: <2265443.MuN2qLDJi8@thomas> (raw)
In-Reply-To: <BYAPR12MB263126DCF313C5582850BB24A5929@BYAPR12MB2631.namprd12.prod.outlook.com>

09/11/2021 12:49, Gregory Etelson:
> Hello Thomas,
> 
> > 09/11/2021 10:58, Gregory Etelson:
> > > -     uint8_t client = 0;
> > > +     /*
> > > +      * C99: All objects with static storage
> > duration
> > > +      * shall be initialized (set to their initial
> > values) before
> > > +      * program startup.
> > > +      */
> > 
> > Why adding this comment?
> > 
> > > +     static uint8_t client;
> > 
> > 
> 
> C99 optimization that was used here is not obvious.
> The patch relies on client=0 initialization.
> I added the comment to clarify why the client was not initialized.

I think it is the C standard, not only C99.
As far as I know, having static as 0 is obvious for a lot of people.



  reply	other threads:[~2021-11-09 14:17 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20211026095037.17557-1-getelson@nvidia.com>
2021-11-09  9:58 ` Gregory Etelson
2021-11-09 11:35   ` Thomas Monjalon
2021-11-09 11:49     ` Gregory Etelson
2021-11-09 14:17       ` Thomas Monjalon [this message]
2021-11-10 16:52 ` [PATCH v3] " Gregory Etelson
2021-11-10 16:57 ` [PATCH v4] examples/multi_process: " Gregory Etelson
2021-11-16 15:07   ` David Marchand

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2265443.MuN2qLDJi8@thomas \
    --to=thomas@monjalon.net \
    --cc=anatoly.burakov@intel.com \
    --cc=david.marchand@redhat.com \
    --cc=dev@dpdk.org \
    --cc=getelson@nvidia.com \
    --cc=matan@nvidia.com \
    --cc=rasland@nvidia.com \
    --cc=stable@dpdk.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

patches for DPDK stable branches

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://inbox.dpdk.org/stable/0 stable/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 stable stable/ http://inbox.dpdk.org/stable \
		stable@dpdk.org
	public-inbox-index stable

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://inbox.dpdk.org/inbox.dpdk.stable


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git