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 2F047A00C5; Fri, 8 Jul 2022 20:08:32 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id B1E2B406B4; Fri, 8 Jul 2022 20:08:31 +0200 (CEST) Received: from smartserver.smartsharesystems.com (smartserver.smartsharesystems.com [77.243.40.215]) by mails.dpdk.org (Postfix) with ESMTP id 8D8784021E for ; Fri, 8 Jul 2022 20:08:30 +0200 (CEST) X-MimeOLE: Produced By Microsoft Exchange V6.5 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: base64 Subject: RE: [PATCH 2/2] service: fix potential stats race-condition on MT services Date: Fri, 8 Jul 2022 20:08:26 +0200 Message-ID: <98CBD80474FA8B44BF855DF32C47DC35D871BA@smartserver.smartshare.dk> In-Reply-To: X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: [PATCH 2/2] service: fix potential stats race-condition on MT services Thread-Index: AQHYkso9CqvSXQ5m5kCgd1gUAmDVCq10lTCQgAASFcCAAARTYIAAA6LwgAAKj1CAAAegwA== References: <20220708125645.3141464-1-harry.van.haaren@intel.com> <20220708125645.3141464-2-harry.van.haaren@intel.com> <98CBD80474FA8B44BF855DF32C47DC35D871B8@smartserver.smartshare.dk> <98CBD80474FA8B44BF855DF32C47DC35D871B9@smartserver.smartshare.dk> From: =?UTF-8?B?TW9ydGVuIEJyw7hydXA=?= To: "Honnappa Nagarahalli" , "Harry van Haaren" , Cc: =?UTF-8?B?TWF0dGlhcyBSw7ZubmJsb20=?= , "nd" , "nd" X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org PiBGcm9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