From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <thomas@monjalon.net>
Received: from out1-smtp.messagingengine.com (out1-smtp.messagingengine.com
 [66.111.4.25]) by dpdk.org (Postfix) with ESMTP id E891D1BB5F
 for <dev@dpdk.org>; Fri, 11 May 2018 01:47:13 +0200 (CEST)
Received: from compute1.internal (compute1.nyi.internal [10.202.2.41])
 by mailout.nyi.internal (Postfix) with ESMTP id 3AAF122971;
 Thu, 10 May 2018 19:47:13 -0400 (EDT)
Received: from mailfrontend1 ([10.202.2.162])
 by compute1.internal (MEProxy); Thu, 10 May 2018 19:47:13 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h=
 cc:content-transfer-encoding:content-type:date:from:in-reply-to
 :message-id:mime-version:references:subject:to:x-me-sender
 :x-me-sender:x-sasl-enc; s=mesmtp; bh=xLm64cyfHGRWygFUpHhlMfmGfD
 FQpqtlvxbrMpAxxK4=; b=cvUljZOPw5DpXuUPg85+uEypodN6wkrC7IaXPGFXsZ
 xjdVAV8m3Xp4NneE2dZgVxTecfgyGyqnO1R6Laf0+fCGDE0/siXVuUWmKVbXNwYd
 qL6Ii748i0fjOLn/HNBxGV8DwhYNs/Fr7U+PF2jKyiz3Dflsz2iglzAkHCRM3Qjq
 M=
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=
 messagingengine.com; h=cc:content-transfer-encoding:content-type
 :date:from:in-reply-to:message-id:mime-version:references
 :subject:to:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=xLm64c
 yfHGRWygFUpHhlMfmGfDFQpqtlvxbrMpAxxK4=; b=ffYD9HuF8UqkPNPY2tNrlp
 viuteOE0+tuJVo/iBbPcRgsgoEkPTa3HOkEO9mU3CSpLTFyZAf/qzzCt9IyPIOz8
 HsceHyHxxP+rvZ8FWSXd/yl9cVkiex5MrR6zVDYnJFovbsgr5p3LbLp/04d7H4c4
 U3Nc7fEZLmFAjKThhUvoaBGXce6kk41Gpayn7s4+jMgUh5m+dwzzrvAjmMQkDo+1
 ChJP7kAl7U2oGq7AhmnWFGhpsedoJtOqaI6/H1J+NaZHl8Bzhtz9hELZZdxO9GLE
 stWwVY9gewUO+IsUKwZk3x3YDsSDD6dhDmfL3CAuzD+tKeiUzKdXulJ/AnAiuS2A
 ==
X-ME-Sender: <xms:Adr0Wk-sYLjntTHYYugqJURUULMZUJ8Jaalat0Qf1P-TEeJhL5yhaw>
Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184])
 by mail.messagingengine.com (Postfix) with ESMTPA id 82FC5E4488;
 Thu, 10 May 2018 19:47:12 -0400 (EDT)
From: Thomas Monjalon <thomas@monjalon.net>
To: Stephen Hemminger <stephen@networkplumber.org>
Cc: dev@dpdk.org, =?ISO-8859-1?Q?Ga=EBtan?= Rivet <gaetan.rivet@6wind.com>,
 Matan Azrad <matan@mellanox.com>
Date: Fri, 11 May 2018 01:47:11 +0200
Message-ID: <4197647.NnQ7NCaPt5@xps>
In-Reply-To: <8877388.Xvcb3uZcyi@xps>
References: <20180509094337.26112-1-thomas@monjalon.net>
 <20180510133516.6552e936@xeon-e3> <8877388.Xvcb3uZcyi@xps>
MIME-Version: 1.0
Content-Transfer-Encoding: quoted-printable
Content-Type: text/plain; charset="iso-8859-1"
Subject: Re: [dpdk-dev] [PATCH 07/11] ethdev: add lock to port allocation
	check
X-BeenThere: dev@dpdk.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: DPDK patches and discussions <dev.dpdk.org>
List-Unsubscribe: <https://dpdk.org/ml/options/dev>,
 <mailto:dev-request@dpdk.org?subject=unsubscribe>
List-Archive: <http://dpdk.org/ml/archives/dev/>
List-Post: <mailto:dev@dpdk.org>
List-Help: <mailto:dev-request@dpdk.org?subject=help>
List-Subscribe: <https://dpdk.org/ml/listinfo/dev>,
 <mailto:dev-request@dpdk.org?subject=subscribe>
X-List-Received-Date: Thu, 10 May 2018 23:47:14 -0000

11/05/2018 00:13, Thomas Monjalon:
> 10/05/2018 22:35, Stephen Hemminger:
> > On Wed, 9 May 2018 14:21:17 +0200
> > Ga=EBtan Rivet <gaetan.rivet@6wind.com> wrote:
> >=20
> > > A suggestion about the naming here.
> > > Reading subsequent patches, we can see this function being used during
> > > ethdev allocation routines. The _lock_free suffix is a little
> > > misleading, as for an instant one can think that there is something
> > > being freed about an allocated ethdev lock.
> > >=20
> > > I would suggest
> > >=20
> > >   * rte_eth_dev_allocated_nolock
> > >     or
> > >   * rte_eth_dev_allocated_lockless
> > >     (or even rte_eth_lockless_dev_allocated)
> > >=20
> > > instead.
> >=20
> > Personally, used to the convention of:
> >     rte_eth_dev_find(name)
> > and
> >     _rte_eth_dev_find(name)
> >=20
> > The _ implies internal version without lock.
>=20
> It is a matter of taste.
> We have chosen "nolock" in v2, and I think it is explicit.

After a second thought, I have decided to follow the underscore convention:
	_rte_eth_dev_allocated