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 430DEA046B for ; Tue, 28 May 2019 15:14:19 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id ABB231B995; Tue, 28 May 2019 15:13:07 +0200 (CEST) Received: from EUR01-VE1-obe.outbound.protection.outlook.com (mail-eopbgr140043.outbound.protection.outlook.com [40.107.14.43]) by dpdk.org (Postfix) with ESMTP id 94EDB1B9ED for ; Tue, 28 May 2019 14:10:03 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Mellanox.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=AL+t4D4MNsVwODra1O/OjYtyozxXghcyk797+IZj9VQ=; b=G4vnr4JeGjPCMcsoOp5Xe5XANgANLIZ+i46WURltg9LIdPk/sEzzzGiDnqxUTciLfB6GH5kDzKx34cOPitontHHH5GQLR8lQGHyvZK8UI1/N6TU/thsZnTRvvLSk0Y7ENtROcEsMtPuX/InJ5cfU0jRjzCBRNio/66SqhQA+cXU= Received: from AM0PR05MB4435.eurprd05.prod.outlook.com (52.134.95.151) by AM0PR05MB4385.eurprd05.prod.outlook.com (52.134.126.151) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1922.18; Tue, 28 May 2019 12:09:57 +0000 Received: from AM0PR05MB4435.eurprd05.prod.outlook.com ([fe80::c40a:d6fe:1246:7278]) by AM0PR05MB4435.eurprd05.prod.outlook.com ([fe80::c40a:d6fe:1246:7278%4]) with mapi id 15.20.1922.021; Tue, 28 May 2019 12:09:57 +0000 From: Moti Haimovsky To: Shahaf Shuler CC: "dev@dpdk.org" , Moti Haimovsky Thread-Topic: [PATCH v2] net/mlx5: remove TCF support from PMD Thread-Index: AQHVFU5DcuGi0sBR8EC70TCX9DlSkw== Date: Tue, 28 May 2019 12:09:56 +0000 Message-ID: References: <1559042301-73445-2-git-send-email-motih@mellanox.com> In-Reply-To: <1559042301-73445-2-git-send-email-motih@mellanox.com> Accept-Language: he-IL, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: VI1PR0602CA0012.eurprd06.prod.outlook.com (2603:10a6:800:bc::22) To AM0PR05MB4435.eurprd05.prod.outlook.com (2603:10a6:208:61::23) authentication-results: spf=none (sender IP is ) smtp.mailfrom=motih@mellanox.com; x-ms-exchange-messagesentrepresentingtype: 1 x-mailer: git-send-email 1.7.1 x-originating-ip: [37.142.13.130] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: aeacc93f-aeca-4a4d-2807-08d6e36565e4 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600148)(711020)(4605104)(1401327)(4618075)(2017052603328)(7193020); SRVR:AM0PR05MB4385; x-ms-traffictypediagnostic: AM0PR05MB4385: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:67; x-forefront-prvs: 00514A2FE6 x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(366004)(396003)(376002)(39860400002)(346002)(136003)(189003)(199004)(52314003)(68736007)(66066001)(53946003)(26005)(102836004)(6862004)(54906003)(14454004)(66946007)(8676002)(50226002)(6636002)(53936002)(2616005)(186003)(71190400001)(8936002)(316002)(81166006)(37006003)(71200400001)(6512007)(107886003)(446003)(11346002)(81156014)(52116002)(25786009)(256004)(5660300002)(14444005)(5024004)(7736002)(2906002)(478600001)(476003)(305945005)(64756008)(6506007)(486006)(66556008)(386003)(66446008)(6436002)(36756003)(4326008)(66476007)(73956011)(86362001)(30864003)(6486002)(6116002)(3846002)(76176011)(118296001)(99286004)(21314003)(559001)(569006); DIR:OUT; SFP:1101; SCL:1; SRVR:AM0PR05MB4385; H:AM0PR05MB4435.eurprd05.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; received-spf: None (protection.outlook.com: mellanox.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: wnXKwgNXlOSwD/zIhl6pM8u5V6eCdSxqkML5dwcIiIQ+IR8MjvJYfSgYKOOL95EW2ieTqM/XidT8aUF+SDKyKrXGcV9SZbrOEdTRZIGukcggbx31z3AykuG7iXu76zbxp0fuqRzC6G/P82FxjXadhBhBiG/3ADx7EiW0DTKmQVg8+eMALwrAD+Xwn/YFgQypNTo07WBLhfflpKJF0twAnp1i93Ix1oUoUgPUHrRZEPBU0KpsotRrIrHRbVI781QpEDGMhRnAVHbJ9ZjRrSO61EmYql3qiQjISjmIR8D+SvHiLhqIzSRhEMx8K6kd+BqUqkwOHdp7RC4JHWZ1an2b9aVZ/EhBQQqmUmrT/hLtHRLvSAVo8lOuVeeZqz0CAYf9jAY+Ftr0e01bAE300fP3Bozy43+OjHmlp4fV29gvXfI= Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-OriginatorOrg: Mellanox.com X-MS-Exchange-CrossTenant-Network-Message-Id: aeacc93f-aeca-4a4d-2807-08d6e36565e4 X-MS-Exchange-CrossTenant-originalarrivaltime: 28 May 2019 12:09:56.8532 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a652971c-7d2e-4d9b-a6a4-d149256f461b X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: motih@mellanox.com X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR05MB4385 X-Mailman-Approved-At: Tue, 28 May 2019 15:12:47 +0200 Subject: [dpdk-dev] [PATCH v2] net/mlx5: remove TCF support from PMD 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" VGhpcyBjb21taXQgcmVtb3ZlcyB0aGUgc3VwcG9ydCBvZiBjb25maWd1cmluZyB0aGUgZGV2aWNl IEUtc3dpdGNoDQp1c2luZyBUQ0Ygc2luY2UgaXQgaXMgbm93IHBvc3NpYmxlIHRvIGNvbmZpZ3Vy ZSBpdCB2aWEgRFIgKGRpcmVjdA0KdmVyYnMgcnVsZXMpLCBhbmQgYnkgdGhhdCB0byBhbHNvIHJl bW92ZSB0aGUgUE1EIGRlcGVuZGVuY3kgaW4gbGlibW5sLg0KDQpTaWduZWQtb2ZmLWJ5OiBNb3Rp IEhhaW1vdnNreSA8bW90aWhAbWVsbGFub3guY29tPg0KLS0tDQp2MjoNCiAqIEZpeCBjaGVja3Bh dGNoIHdhcm5pbmdzLg0KLS0tDQogZG9jL2J1aWxkLXNkay1tZXNvbi50eHQgICAgICAgICAgIHwg ICAgMiArLQ0KIGRvYy9ndWlkZXMvbmljcy9tbHg1LnJzdCAgICAgICAgICB8ICAgMTkgLQ0KIGRv Yy9ndWlkZXMvcGxhdGZvcm0vYmx1ZWZpZWxkLnJzdCB8ICAgIDQgLQ0KIGRyaXZlcnMvbmV0L21s eDUvTWFrZWZpbGUgICAgICAgICB8ICAzMDMgLS0NCiBkcml2ZXJzL25ldC9tbHg1L21lc29uLmJ1 aWxkICAgICAgfCAgMTIzICstDQogZHJpdmVycy9uZXQvbWx4NS9tbHg1LmMgICAgICAgICAgIHwg ICAzMiAtDQogZHJpdmVycy9uZXQvbWx4NS9tbHg1LmggICAgICAgICAgIHwgICAgMyAtDQogZHJp dmVycy9uZXQvbWx4NS9tbHg1X2Zsb3cuYyAgICAgIHwgICAxNCArLQ0KIGRyaXZlcnMvbmV0L21s eDUvbWx4NV9mbG93LmggICAgICB8ICAgMjUgLQ0KIGRyaXZlcnMvbmV0L21seDUvbWx4NV9mbG93 X3RjZi5jICB8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CiByZXF1aXJl ZDoNCiANCiAgICAtIGxpYmlidmVyYnMNCi0gICAtIGxpYm1ubA0KICAgIC0gbGlibWx4NQ0KICAg IC0gbGlibmwtMw0KICAgIC0gbGlibmwtcm91dGUtMw0KQEAgLTEwNSwxOSArMTA0LDE2IEBAIHRh cmJhbGwgZm9yIHRoZSBjcm9zcyB0b29sY2hhaW4uDQogICAgICAgICAjIENvcHkgbGlicmFyaWVz DQogICAgICAgICBta2RpciAtcCBsaWI2NA0KICAgICAgICAgY3AgLWEgL2xpYjY0L2xpYmlidmVy YnMqIGxpYjY0Lw0KLSAgICAgICAgY3AgLWEgL2xpYjY0L2xpYm1ubCogbGliNjQvDQogICAgICAg ICBjcCAtYSAvbGliNjQvbGlibWx4NSogbGliNjQvDQogICAgICAgICBjcCAtYSAvbGliNjQvbGli bmwtMyogbGliNjQvDQogICAgICAgICBjcCAtYSAvbGliNjQvbGlibmwtcm91dGUtMyogbGliNjQv DQogDQogICAgICAgICAjIENvcHkgaGVhZGVyIGZpbGVzDQogICAgICAgICBta2RpciAtcCB1c3Iv aW5jbHVkZS9pbmZpbmliYW5kDQotICAgICAgICBta2RpciAtcCB1c3IvaW5jbHVkZS9saWJtbmwN CiAgICAgICAgIGNwIC1hIC91c3IvaW5jbHVkZS9pbmZpbmliYW5kL2liX3VzZXJfaW9jdGxfdmVy YnMuaCB1c3IvaW5jbHVkZS9pbmZpbmliYW5kLw0KICAgICAgICAgY3AgLWEgL3Vzci9pbmNsdWRl L2luZmluaWJhbmQvbWx4NSouaCB1c3IvaW5jbHVkZS9pbmZpbmliYW5kLw0KICAgICAgICAgY3Ag LWEgL3Vzci9pbmNsdWRlL2luZmluaWJhbmQvdG1fdHlwZXMuaCB1c3IvaW5jbHVkZS9pbmZpbmli YW5kLw0KICAgICAgICAgY3AgLWEgL3Vzci9pbmNsdWRlL2luZmluaWJhbmQvdmVyYnMqLmggdXNy L2luY2x1ZGUvaW5maW5pYmFuZC8NCi0gICAgICAgIGNwIC1hI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