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 4F61641C23; Mon, 6 Feb 2023 16:29:32 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 21FC042B7E; Mon, 6 Feb 2023 16:29:32 +0100 (CET) Received: from NAM10-DM6-obe.outbound.protection.outlook.com (mail-dm6nam10on2053.outbound.protection.outlook.com [40.107.93.53]) by mails.dpdk.org (Postfix) with ESMTP id 3BFC9427E9 for ; Mon, 6 Feb 2023 16:29:30 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=AZP7mYQGBAD6nJf5eDdC58ErANoLNLSW1omgmj0KgltbYLUBPUTuvxOI9tGy6wC7kMpQBrr2xnwHnA0Vzw2WpxmmeKJEubFoN8gTxh8t7qGBiJN2xY737pWdBhRrLqiSg8BpsiOVLsf1eA4jysA0qDmzeRYbuCTLwtO8C77VjW7CVB8T2UqbOKuoI6VDwOb2lbFh3/zDTANfLH7IOFWx0dUwG2IhWoOGv2oija/fJe4WXXMyNhywbvUrekWw4tvm672C2Qin4q7hZhqkWFq2gaA27UdzhLW78VNIy9fvW+g8eI5A75TNdsWgyZOI2OKdHfvm1LbvwXOWgi3M5eh7+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=sqv7/0giE8RCe+myAiil4XAPgl+oVJsO2NJAoFN7tsk=; b=aQLgTLFbHuo88pJoH21TRAOtT8N0RMqP3dUjzZbgo01TcCM5Ytbq5rnF0/KdS/SFJuGTsZuECxyFXMNV8iM5TRoqTMr/J+Q610uTdcisz5+hYtM0pHGaGfRzYuc8cBd4xoHlLYUsgJ1nelWZzvvi2NNVvoJQG60OCFIJtEQCGS8bfTDW3Kn3+eSO8kQ5YBFEGDHc7IHNdOcjoC+bYnAvJ/j6pNoN0zSVQ+VYEuhunwdUjcq/qOMGMifRDMLApTWuPMyfLXAFPzHkXsbP96GsVJfgjP8sADHLexHrZnQeLSL/pOKDRUbqNvplW9IJSCyV1nDt9c5MAT7Ea2lleSJjXw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nvidia.com; dmarc=pass action=none header.from=nvidia.com; dkim=pass header.d=nvidia.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=sqv7/0giE8RCe+myAiil4XAPgl+oVJsO2NJAoFN7tsk=; b=N/xoiQLStDBfGlmlykDhv2sOJM/MPWS52ht3YjdQQBP+kE25zGCnSoqzLq24M1CHXkstMcsdxUxYPD1XZFHy7RpBRMVn7wiizwVs/lcGjETRVLxuggoCzADXPy1fLa9hnXRRRzjcpivBzcDBiWdsSFBnbbkTrFWBeJ/iu0m5Y+bfw3jiVMrDGUAhulp3QR1inHiYsdyeWcUViMP2JPiC49e+qmT0RQ/Nwre7KPZusSiwXmJBsL46P1SY6y6lpxYBS+uXUA4WEi3fNi/tjBFkmVqY9g8/7lvDMi07GhnryvZ/efzin+zIEyGIcOZhow2pxym41z8Mojjm5/PF6SqMog== Received: from PH0PR12MB5451.namprd12.prod.outlook.com (2603:10b6:510:ee::20) by DS0PR12MB8444.namprd12.prod.outlook.com (2603:10b6:8:128::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6064.31; Mon, 6 Feb 2023 15:29:28 +0000 Received: from PH0PR12MB5451.namprd12.prod.outlook.com ([fe80::fd7d:5f69:a136:a51d]) by PH0PR12MB5451.namprd12.prod.outlook.com ([fe80::fd7d:5f69:a136:a51d%5]) with mapi id 15.20.6064.034; Mon, 6 Feb 2023 15:29:28 +0000 From: "Jiawei(Jonny) Wang" To: "Jiawei(Jonny) Wang" , Slava Ovsiienko , Ori Kam , "NBU-Contact-Thomas Monjalon (EXTERNAL)" , "andrew.rybchenko@oktetlabs.ru" , Aman Singh , Yuying Zhang , Ferruh Yigit CC: "dev@dpdk.org" , Raslan Darawsheh Subject: RE: [PATCH v4 1/2] ethdev: introduce the PHY affinity field in Tx queue API Thread-Topic: [PATCH v4 1/2] ethdev: introduce the PHY affinity field in Tx queue API Thread-Index: AQHZN9Q4XKYML/HSVUC75oLIdCXXZa7CD5qQ Date: Mon, 6 Feb 2023 15:29:28 +0000 Message-ID: References: <20230203050717.46914-1-jiaweiw@nvidia.com> <20230203133339.30271-1-jiaweiw@nvidia.com> <20230203133339.30271-2-jiaweiw@nvidia.com> In-Reply-To: <20230203133339.30271-2-jiaweiw@nvidia.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nvidia.com; x-ms-publictraffictype: Email x-ms-traffictypediagnostic: PH0PR12MB5451:EE_|DS0PR12MB8444:EE_ x-ms-office365-filtering-correlation-id: 38008bc0-372b-4e89-f3ba-08db0856ef8f x-ld-processed: 43083d15-7273-40c1-b7db-39efd9ccc17a,ExtAddr x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: wwAbX43ZxXHqIiYCVOmXAKc1t96pjGjZ5jaN8e48OAvLEC3ZWGUhH86VjxkhjsPx4iYK+Zi7zvkGW2oEMWMP41778V2hoj0fP66E8k8JIng5S2B0++q9zibSV3enfK7j4p8Yy082ZbvEe06mccXyXRLg2vZUVSGhcwAmZixEDr0aR/lnxwyarMT/qKzqRuFEKSa3qluXksxNTDusSBoRzm/CIzSziPsC9hBt9qsoAA07y8Wkp6dtaOXm2tHj901ZUQPD9yF0etjkGorzSkRErj+JYiJLIQdYTc7oS2qRmG9yMg2OktZpbcZl2wM2W6vD0RqZ4PsD0RGiQeJUlG9DebxT6F5due8gj/El1wo3DunkL/vn94ZMe88j9RMLpfMzhwDNK3JUlXvU5jXRUjs+JSTI2Eu3WrvfrfgevRw+sWvtjcbjRC99D1V2TRjOFjvbFJG5p9A1oQ84ooKxCp+w8SU1rTnyh2NoPeHYSLpAYoxdXPtPg4lU7ywCrcXeqVYPMkUWnOFXNV9UTT5tF3sttER0tgK/uMBGEe/yUsz3SdrKvATdYkxrCrO96jq2VhComFexS5/6fj3DZ2U0T8uLm/UwqCDm1Whw1X3zhp7JyTt4DXBLLI5UNDM4q00EvFZk3QSrqNqMFFU5v53hDIoZpxdzC2JwNGV39XvhzZ+e0JT4jYCbs8DhJPNk2OAoSmDgbqS2BAXPJYNst+BGrJi27g== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:PH0PR12MB5451.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230025)(4636009)(376002)(346002)(396003)(136003)(39860400002)(366004)(451199018)(7696005)(26005)(9686003)(53546011)(6506007)(2906002)(71200400001)(41300700001)(107886003)(38100700002)(122000001)(66556008)(66476007)(66446008)(316002)(66946007)(4326008)(76116006)(186003)(55016003)(64756008)(83380400001)(478600001)(38070700005)(8936002)(54906003)(110136005)(8676002)(5660300002)(86362001)(52536014)(33656002); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?2yeNguucqaM+/csMsMNokbwux55RjaRnoCHJIo2JP7M7SHT5JxAZM7hIcF26?= =?us-ascii?Q?iMluSH8O1Ct6Ivi54PoR0g+HBja2HUHuszoIwk5mxKSG55xKHher/Bj8MZLE?= =?us-ascii?Q?cmMK2tCz9EatNMisLwebXF4k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ff3Dav4b/PLRe/W3NYCrHbxdLUwmK/47NGPlaD0oQ2Zd5Ur4S2UWvUB?= =?us-ascii?Q?xj2CFq0c/YOGy4pOk5TfTcunTmyXz74uCTfN4YeWVEIFVMBBLb/ffkM3IJen?= =?us-ascii?Q?CZMYncciGZy4hTWpIcAwwgDSs5k/kePaoOcJYKgJeVwwGUlUfH52cjdHCpEF?= =?us-ascii?Q?EiKgeEaW9oTP0wi9izwK1j+cQjmoV/ZUJYON45lSZGuitXygarvTgDyUUqsS?= =?us-ascii?Q?3gBX8O49t9+unOdWLz/0c79S4eYYpnSRJhmNicHpsL3/5K+vTCQsI1szka3y?= =?us-ascii?Q?2zklhWtEwnq4XsK/vXUWh2C3rjHgCT98myScZrbIxonwqQorOxWDpjISC4y9?= =?us-ascii?Q?AJF3xr1RFBx75eRRFBiLvE33/2h1ZvJdodMiKJzQxaFycuG1+O2UkCygUhIm?= =?us-ascii?Q?Y1Tfil05C5WiMLNWpcFmZZWT5m1t4Y7yg3c6auApIW/JwIxZmhFdBvSYCXay?= =?us-ascii?Q?qGD9Kay0QW+ArHuHwgEjUoKKo0JGdV656rdYHG9WSa8eUZIfPtsLJGhHLH0J?= =?us-ascii?Q?2TlXz25jSnyScOu3KFmcujw4YzRoSCXJP7j3GybZ?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: PH0PR12MB5451.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 38008bc0-372b-4e89-f3ba-08db0856ef8f X-MS-Exchange-CrossTenant-originalarrivaltime: 06 Feb 2023 15:29:28.2143 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: HlCBSC+zC5D07EHVhOsCmkSspRZFXzgncf+SaUuAn5iQwkh4DxW/mmjhmCse1HwO3wV7ofZShff+h0slZdEeVg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DS0PR12MB8444 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 Hi, @Andrew, @Thomas, @Ori,=20 Could you lease help to review the patch? Thanks. > -----Original Message----- > From: Jiawei Wang > Sent: Friday, February 3, 2023 9:34 PM > To: Slava Ovsiienko ; Ori Kam ; > NBU-Contact-Thomas Monjalon (EXTERNAL) ; > andrew.rybchenko@oktetlabs.ru; Aman Singh ; > Yuying Zhang ; Ferruh Yigit > Cc: dev@dpdk.org; Raslan Darawsheh > Subject: [PATCH v4 1/2] ethdev: introduce the PHY affinity field in Tx qu= eue > API >=20 > When multiple physical ports are connected to a single DPDK port, > (example: kernel bonding, DPDK bonding, failsafe, etc.), we want to know > which physical port is used for Rx and Tx. >=20 > This patch maps a DPDK Tx queue with a physical port, by adding > tx_phy_affinity setting in Tx queue. > The affinity number is the physical port ID where packets will be sent. > Value 0 means no affinity and traffic could be routed to any connected > physical ports, this is the default current behavior. >=20 > The number of physical ports is reported with rte_eth_dev_info_get(). >=20 > The new tx_phy_affinity field is added into the padding hole of rte_eth_t= xconf > structure, the size of rte_eth_txconf keeps the same. > An ABI check rule needs to be added to avoid false warning. >=20 > Add the testpmd command line: > testpmd> port config (port_id) txq (queue_id) phy_affinity (value) >=20 > For example, there're two physical ports connected to a single DPDK port > (port id 0), and phy_affinity 1 stood for the first physical port and phy= _affinity > 2 stood for the second physical port. > Use the below commands to config tx phy affinity for per Tx Queue: > port config 0 txq 0 phy_affinity 1 > port config 0 txq 1 phy_affinity 1 > port config 0 txq 2 phy_affinity 2 > port config 0 txq 3 phy_affinity 2 >=20 > These commands config the Tx Queue index 0 and Tx Queue index 1 with phy > affinity 1, uses Tx Queue 0 or Tx Queue 1 send packets, these packets wil= l be > sent from the first physical port, and similar with the second physical p= ort if > sending packets with Tx Queue 2 or Tx Queue 3. >=20 > Signed-off-by: Jiawei Wang > --- snip > 2.18.1