From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR01-VE1-obe.outbound.protection.outlook.com (mail-ve1eur01on0072.outbound.protection.outlook.com [104.47.1.72]) by dpdk.org (Postfix) with ESMTP id 7F90A1B85E for ; Thu, 10 May 2018 14:03:19 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Mellanox.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=75DVQmrprs4QxaVGMYof6PsEpNZQsKNvFm5+LMZJ2Hw=; b=lLIFrEI9LgZQBrdwIxCf36W9MAu4qOquOfLY4y61/cDQwO0HDt1ABG9OGPnXFZEZF2huXGwiD36qF1D8VW6nBRQlBipjpnGnYotqgT65gUQKZ5JkmmZbhJFFpTghDyodUQbrMQCOJaebop27/4PmIoFPf+mKNNs9Twf2FA+fC8I= Received: from VI1PR0501MB2608.eurprd05.prod.outlook.com (10.168.137.20) by VI1PR0501MB2237.eurprd05.prod.outlook.com (10.169.134.148) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.755.16; Thu, 10 May 2018 12:03:18 +0000 Received: from VI1PR0501MB2608.eurprd05.prod.outlook.com ([fe80::49ca:b540:8f36:c063]) by VI1PR0501MB2608.eurprd05.prod.outlook.com ([fe80::49ca:b540:8f36:c063%17]) with mapi id 15.20.0755.012; Thu, 10 May 2018 12:03:18 +0000 From: Matan Azrad To: Andrew Rybchenko , Thomas Monjalon , "dev@dpdk.org" Thread-Topic: [dpdk-dev] [PATCH v2 10/11] net/failsafe: fix sub-device ownership race Thread-Index: AQHT5+cv/S8o/S/Tck+6SfdOVkaqPKQo0KsAgAAFc2A= Date: Thu, 10 May 2018 12:03:18 +0000 Message-ID: References: <20180509094337.26112-1-thomas@monjalon.net> <20180509224313.27289-1-thomas@monjalon.net> <20180509224313.27289-11-thomas@monjalon.net> <6fd5308e-9566-b220-7ec9-175d82a4aded@solarflare.com> In-Reply-To: <6fd5308e-9566-b220-7ec9-175d82a4aded@solarflare.com> Accept-Language: en-US, he-IL Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=matan@mellanox.com; x-originating-ip: [193.47.165.251] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1; VI1PR0501MB2237; 7:UDAzkVwq5ck6p0cmq07Z2BDVOAF0V+fSpPh2IawXZD8e+ttNvuQ+tdz7I5M+hzB3jKw4jru8TSctEePsKuTYaccad8XriUSB99TqkEjTRvRkij/K9nrD4DqK1j3It8SCD4rr+ljAl4ttua/44AALhOamhq9wxyH9cLWJ3uToA6yPQuFDapgfcIxJZOO+jOY5/VyaLK2qsr5eFF/o2WVozIP43tDaHk9PzneT9bKG7x1lrEXz42MPS/4uLYHTxfin x-ms-exchange-antispam-srfa-diagnostics: SOS; x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(48565401081)(4534165)(4627221)(201703031133081)(201702281549075)(2017052603328)(7153060)(7193020); SRVR:VI1PR0501MB2237; x-ms-traffictypediagnostic: VI1PR0501MB2237: x-ld-processed: a652971c-7d2e-4d9b-a6a4-d149256f461b,ExtAddr x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(60795455431006)(278428928389397); x-ms-exchange-senderadcheck: 1 x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(93006095)(93001095)(3002001)(10201501046)(3231254)(944501410)(52105095)(6055026)(149027)(150027)(6041310)(20161123560045)(20161123564045)(20161123562045)(20161123558120)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(6072148)(201708071742011); SRVR:VI1PR0501MB2237; BCL:0; PCL:0; RULEID:; SRVR:VI1PR0501MB2237; x-forefront-prvs: 066898046A x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(39860400002)(396003)(366004)(39380400002)(376002)(346002)(199004)(189003)(51914003)(229853002)(3846002)(6116002)(478600001)(66066001)(33656002)(25786009)(110136005)(86362001)(5250100002)(76176011)(316002)(575784001)(2501003)(6246003)(7736002)(305945005)(53936002)(74316002)(55016002)(9686003)(7696005)(99286004)(97736004)(2900100001)(8936002)(81156014)(81166006)(8676002)(5660300001)(6436002)(2906002)(68736007)(186003)(93886005)(53546011)(476003)(3280700002)(102836004)(446003)(6506007)(11346002)(106356001)(59450400001)(3660700001)(486006)(26005)(14454004)(105586002); DIR:OUT; SFP:1101; SCL:1; SRVR:VI1PR0501MB2237; H:VI1PR0501MB2608.eurprd05.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; received-spf: None (protection.outlook.com: mellanox.com does not designate permitted sender hosts) x-microsoft-antispam-message-info: 0Sp0Hx3zpZ02/IdYJ2JkHEpqMY6+wW/aAa5Q0uN6Y8Au2zdIkRArUEtBsDojsxOqtnSObzK5qq0d4R3PO8Xos7659OJ2Cd492UM+JBMtlEuAKvgMIVZZi2ZjBY1TSZRAeh3YWAA2hbekj5oP0FqZhcWLBv2XUTuf1IjFGkyi1JSk7LsVWLIXUzVb4hgqkc6F spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-MS-Office365-Filtering-Correlation-Id: a71175ff-b68a-4176-0a24-08d5b66e048c X-OriginatorOrg: Mellanox.com X-MS-Exchange-CrossTenant-Network-Message-Id: a71175ff-b68a-4176-0a24-08d5b66e048c X-MS-Exchange-CrossTenant-originalarrivaltime: 10 May 2018 12:03:18.0487 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a652971c-7d2e-4d9b-a6a4-d149256f461b X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0501MB2237 Subject: Re: [dpdk-dev] [PATCH v2 10/11] net/failsafe: fix sub-device ownership race 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: , X-List-Received-Date: Thu, 10 May 2018 12:03:19 -0000 SGkgQW5kcmV3DQoNCj4gRnJvbTogQW5kcmV3IFJ5YmNoZW5rbw0KPiBPbiAwNS8xMC8yMDE4IDAx OjQzIEFNLCBUaG9tYXMgTW9uamFsb24gd3JvdGU6DQo+IEZyb206IE1hdGFuIEF6cmFkIDxtYXRh bkBtZWxsYW5veC5jb20+DQo+IA0KPiBUaGVyZSBpcyB0aW1lIGJldHdlZW4gdGhlIHN1Yi1kZXZp Y2UgcG9ydCBwcm9iaW5nIGJ5IHRoZSBzdWItZGV2aWNlIFBNRCB0bw0KPiB0aGUgc3ViLWRldmlj ZSBwb3J0IG93bmVyc2hpcCB0YWtpbmcgYnkgYSBmYWlsLXNhZmUgcG9ydC4NCj4gDQo+IEluIHRo aXMgdGltZSwgdGhlIHBvcnQgaXMgYXZhaWxhYmxlIGZvciB0aGUgYXBwbGljYXRpb24gdXNhZ2Uu IEZvciBleGFtcGxlLCB0aGUNCj4gcG9ydCB3aWxsIGJlIGV4cG9zZWQgdG8gdGhlIGFwcGxpY2F0 aW9ucyB3aGljaCB1c2UgUlRFX0VUSF9GT1JFQUNIX0RFVg0KPiBpdGVyYXRvci4NCj4gDQo+IFRo dXMsIG93bmVyc2hpcCB1bmF3YXJlIGFwcGxpY2F0aW9ucyBtYXkgbWFuYWdlIHRoZSBwb3J0IGlu IHRoaXMgdGltZSB3aGF0DQo+IG1heSBjYXVzZSBhIGxvdCBvZiBwcm9ibGVtYXRpYyBiZWhhdmlv cnMgaW4gdGhlIGZhaWwtc2FmZSBzdWItZGV2aWNlDQo+IGluaXRpYWxpemF0aW9uLg0KPiANCj4g UmVnaXN0ZXIgdG8gdGhlIGV0aGRldiBORVcgZXZlbnQgdG8gdGFrZSB0aGUgc3ViLWRldmljZSBw b3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