From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by dpdk.space (Postfix) with ESMTP id 473EFA0679 for ; Mon, 29 Apr 2019 22:06:03 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 9824C5F51; Mon, 29 Apr 2019 22:06:01 +0200 (CEST) Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-eopbgr30053.outbound.protection.outlook.com [40.107.3.53]) by dpdk.org (Postfix) with ESMTP id 319B95F36 for ; Mon, 29 Apr 2019 22:06:00 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector1-arm-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=BzSHGZZ+Sm2Xx24QK9rRuE2cEKbJTjRQtL1r/dnh66A=; b=IeA3SgCqMVGywD1Kx43PE9vT38+iF++vZ8ohXckoT8v5IMHnfGS7WIO6NIiw/1yIbc02ETIm2TTNYWKn+M3Wda1qFOqawF9aK0DGXl1aaelC9Fi+rGEYbwhjtkJHHHuERqpJynzhdDAvXk9CyLztLOIofpJPq0xX6dGer/jqWF4= Received: from AM6PR08MB3383.eurprd08.prod.outlook.com (20.177.116.29) by AM6PR08MB4438.eurprd08.prod.outlook.com (20.179.7.139) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1835.13; Mon, 29 Apr 2019 20:05:59 +0000 Received: from AM6PR08MB3383.eurprd08.prod.outlook.com ([fe80::f837:e302:7328:2172]) by AM6PR08MB3383.eurprd08.prod.outlook.com ([fe80::f837:e302:7328:2172%2]) with mapi id 15.20.1835.016; Mon, 29 Apr 2019 20:05:59 +0000 From: Dharmik Thakkar To: Yipeng Wang CC: Pablo de Lara , "gentoorion@gmail.com" , "anatoly.burakov@intel.com" , "dev@dpdk.org" , nd Thread-Topic: [dpdk-dev] [PATCH] doc: fix rte_hash_hash comment for ambiguity Thread-Index: AQHU/rXZ+8QhohDHyUyhpENZU4jOg6ZTkH8A Date: Mon, 29 Apr 2019 20:05:58 +0000 Message-ID: <4D954DB3-ACAF-468E-B6C8-51C3E6D9D4DC@arm.com> References: <1556530816-423522-1-git-send-email-yipeng1.wang@intel.com> In-Reply-To: <1556530816-423522-1-git-send-email-yipeng1.wang@intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=Dharmik.Thakkar@arm.com; x-originating-ip: [217.140.111.135] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: a6bbe165-b9f3-4ad8-3e6a-08d6ccde18d0 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600141)(711020)(4605104)(4618075)(2017052603328)(7193020); SRVR:AM6PR08MB4438; x-ms-traffictypediagnostic: AM6PR08MB4438: nodisclaimer: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:949; x-forefront-prvs: 0022134A87 x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(396003)(39860400002)(366004)(346002)(376002)(136003)(189003)(199004)(71200400001)(2616005)(71190400001)(6512007)(11346002)(76176011)(14454004)(305945005)(53546011)(8936002)(7736002)(26005)(6506007)(33656002)(82746002)(6436002)(36756003)(476003)(446003)(486006)(102836004)(8676002)(6486002)(81166006)(81156014)(68736007)(316002)(5660300002)(478600001)(4326008)(25786009)(6116002)(3846002)(256004)(66066001)(91956017)(76116006)(66556008)(64756008)(66476007)(66946007)(6916009)(66446008)(73956011)(54906003)(99286004)(229853002)(83716004)(97736004)(72206003)(86362001)(6246003)(2906002)(186003)(53936002); DIR:OUT; SFP:1101; SCL:1; SRVR:AM6PR08MB4438; H:AM6PR08MB3383.eurprd08.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; received-spf: None (protection.outlook.com: arm.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: YFDtQuu4vU1cdpqRb1KUl3lPb+irlVKy/DFWSHWRhw/R92jDgVBK3M883ktBBcd9exua+uRUOL4DV2q0T5SEUj8mKmyVwNmKRAfnyu63GRdgxbuklV5k5PTOFTaa1METGMndFzzkVde+lZi6YQI5m+u9iyPo2u6u5Qm2L/a7ml6HIBB4ybXFCW7gXcnrKGwxsaxjRTkEWltulJId3xXybu9Q93KPfd9dW1anNeNZB0ARl9qiVa2JMhxnfNkc3Rl7X06CmDTW59VQOLuyYRF3xiB7hQezHPWTQOagZaReHcey716GIHjCfjEwDp/xcZlmSzZapGsRyMxng7w+51lBaPxRPxEQl4SgUBBWXt/hkibOM52KnrkLYdeKO6gc5vxDnrQdLLqGyeBWo2qBqK2JPVxOQhimcrF+Vr3MuW9gwhc= Content-Type: text/plain; charset="UTF-8" Content-ID: <35EE40F25BFC3C4290A535710DBD1B13@eurprd08.prod.outlook.com> Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-Network-Message-Id: a6bbe165-b9f3-4ad8-3e6a-08d6ccde18d0 X-MS-Exchange-CrossTenant-originalarrivaltime: 29 Apr 2019 20:05:58.9169 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM6PR08MB4438 Subject: Re: [dpdk-dev] [PATCH] doc: fix rte_hash_hash comment for ambiguity X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Message-ID: <20190429200558.LKpAVf8ShgSLtlH2b_bXbtCKWsziPa6HTsT23u9yWuE@z> > On Apr 29, 2019, at 4:40 AM, Yipeng Wang wrote: >=20 > rte_hash_hash is multi-thread safe but not multi-process safe > because of the use of function pointers. Previous document > and comment says the other way around. This commit fixes > the issue. >=20 > Fixes: fc1f2750a3ec ("doc: programmers guide") > Fixes: 48a399119619 ("hash: replace with cuckoo hash implementation") > Cc: stable@dpdk.org >=20 > Signed-off-by: Yipeng Wang > Suggested-by: Pablo de Lara > Reported-by: Andrey Nikolaev > --- > doc/guides/prog_guide/multi_proc_support.rst | 2 +- > lib/librte_hash/rte_hash.h | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) >=20 > diff --git a/doc/guides/prog_guide/multi_proc_support.rst b/doc/guides/pr= og_guide/multi_proc_support.rst > index 1384fe3..761fca9 100644 > --- a/doc/guides/prog_guide/multi_proc_support.rst > +++ b/doc/guides/prog_guide/multi_proc_support.rst > @@ -176,7 +176,7 @@ Some of these are documented below: >=20 > * The use of function pointers between multiple processes running based= of different compiled binaries is not supported, > since the location of a given function in one process may be differen= t to its location in a second. > - This prevents the librte_hash library from behaving properly as in a= multi-threaded instance, > + This prevents the librte_hash library from behaving properly as in a= multi-process instance, > since it uses a pointer to the hash function internally. >=20 > To work around this issue, it is recommended that multi-process applicati= ons perform the hash calculations by directly calling > diff --git a/lib/librte_hash/rte_hash.h b/lib/librte_hash/rte_hash.h > index c93d1a1..abba8d7 100644 > --- a/lib/librte_hash/rte_hash.h > +++ b/lib/librte_hash/rte_hash.h > @@ -463,7 +463,7 @@ rte_hash_lookup_with_hash(const struct rte_hash *h, >=20 > /** > * Calc a hash value by key. > - * This operation is not multi-thread safe. > + * This operation is not multi-process safe. > * > * @param h > * Hash table to look in. > --=20 > 2.7.4 >=20 Acked-by: Dharmik Thakkar