From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 1A199A04BC; Thu, 8 Oct 2020 14:31:21 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 6B8281BEF9; Thu, 8 Oct 2020 14:31:18 +0200 (CEST) Received: from nat-hk.nvidia.com (nat-hk.nvidia.com [203.18.50.4]) by dpdk.org (Postfix) with ESMTP id 7F76E1BEE1 for ; Thu, 8 Oct 2020 14:31:15 +0200 (CEST) Received: from HKMAIL102.nvidia.com (Not Verified[10.18.92.77]) by nat-hk.nvidia.com (using TLS: TLSv1.2, AES256-SHA) id ; Thu, 08 Oct 2020 20:31:13 +0800 Received: from HKMAIL101.nvidia.com (10.18.16.10) by HKMAIL102.nvidia.com (10.18.16.11) with Microsoft SMTP Server (TLS) id 15.0.1473.3; Thu, 8 Oct 2020 12:31:08 +0000 Received: from NAM12-DM6-obe.outbound.protection.outlook.com (104.47.59.174) by HKMAIL101.nvidia.com (10.18.16.10) with Microsoft SMTP Server (TLS) id 15.0.1473.3 via Frontend Transport; Thu, 8 Oct 2020 12:31:08 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=g+HJKPd5qu1VmADs+Rcxn6FIgv/96Is6HwjgYRJPnq9GeVzmd8ybmAH2tlAyCavdeJvCTI5hT3eeoB1U58WqXvDYcCtD1LIGPTyDIZJKjGMaik+BMtHrosAWM3tXXigcJI+aGqA7Efc6/hs65/yTGbFtqpV0re3B8gVI/zZK64gQgJKE4unhL1O66GHBK0Arpz3pUh6M9NtzzFEdEwkK56j8kIxFEPgNwdxCjp+HQBtt2uudNmADcKmBzpLV5/cY3KXwFgnYaZoCVW8zq4ytXwB+nUCnflMoHa7CSTO/AHm+A2O1N/cRqdwiB58ad0rk8UEmeVIKO0ony0Sxl4/3ew== 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-SenderADCheck; bh=bfwIU0gBkV+9dJGAD8KiVvhB2Vg1DxuzK6kgSKfSFYA=; b=W7X1YLlUx4m2ilXWdKIPi/HUuwIng+3P76z8OVOIgezlwnVaSt4uTm9+y3BoDBbjkzUtf+Zp64SbvORpXewPaVuEtiIxFz8ByPhKWflyUEIPjE+4D5smDKPDp8l7cZ8Xtl2b/mVM9vlMrZrnfC/Ssu4nRPK8jIRn9lkbRLXrRJsteGLsKm/+CmAV/AxdMagdrnigcjlqaOWCd848G48pjpGmy3jFgxhKR8J1Qe0m51EoGHsdYRnSildBBgvoZ4R2fLH6AYRJvo6hZnz5Dt3oOeLliIUH7k8Ea8ZzezhGHcUyU9a8vDBjvcmWjIAhojbttKzNGpLhKOsJXHAphIUxYw== 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 Received: from MN2PR12MB4286.namprd12.prod.outlook.com (2603:10b6:208:199::22) by MN2PR12MB4344.namprd12.prod.outlook.com (2603:10b6:208:26e::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3455.23; Thu, 8 Oct 2020 12:31:05 +0000 Received: from MN2PR12MB4286.namprd12.prod.outlook.com ([fe80::61fd:a36e:cf4f:2d3f]) by MN2PR12MB4286.namprd12.prod.outlook.com ([fe80::61fd:a36e:cf4f:2d3f%9]) with mapi id 15.20.3455.023; Thu, 8 Oct 2020 12:31:05 +0000 From: Ori Kam To: Bing Zhao , NBU-Contact-Thomas Monjalon , "ferruh.yigit@intel.com" , "arybchenko@solarflare.com" , "mdr@ashroe.eu" , "nhorman@tuxdriver.com" , "bernard.iremonger@intel.com" , "beilei.xing@intel.com" , "wenzhuo.lu@intel.com" CC: "dev@dpdk.org" Thread-Topic: [PATCH v3 3/6] ethdev: add API to get hairpin peer ports list Thread-Index: AQHWnWtcAQFTJ1zNjkyn/eB/m99/OqmNooTA Date: Thu, 8 Oct 2020 12:31:04 +0000 Message-ID: References: <1602147098-9768-1-git-send-email-bingz@nvidia.com> <1602158717-32038-1-git-send-email-bingz@nvidia.com> <1602158717-32038-4-git-send-email-bingz@nvidia.com> In-Reply-To: <1602158717-32038-4-git-send-email-bingz@nvidia.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: nvidia.com; dkim=none (message not signed) header.d=none;nvidia.com; dmarc=none action=none header.from=nvidia.com; x-originating-ip: [147.236.152.129] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 9757ad98-3626-4326-9c8c-08d86b860672 x-ms-traffictypediagnostic: MN2PR12MB4344: x-ld-processed: 43083d15-7273-40c1-b7db-39efd9ccc17a,ExtAddr x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:7219; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: tYKM0vOZbwDAoDeKOGDBKAwMArgUbck3caH/gjyyPZnXYUuhrqzixXAz1k8s4ZyamlICuAou//YYSX2jeaIT68OK2Z8AWkC6G0xOloMQVnXvrLt8AyOlXJPq7jJia93FY+yBSBpnS0U8JWaklfoXwTv1yKBO+I91E9uLOAifWA9P3QT/KmDD6ripbPqQp7VRXNu367L4r0jzS3XPKzJT8GI6NqF9K6uIfhBqNpo59H74xe7rvxxHHGJlsYYu7NDdwG+yE+zNbMJcHrX8WIGF4h6hZfRkW7gk0f37pXQEEyASOHH4MYV7/sl5eI6B5N+p x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:MN2PR12MB4286.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(396003)(136003)(39860400002)(366004)(376002)(346002)(26005)(71200400001)(316002)(83380400001)(66446008)(66946007)(66476007)(64756008)(6506007)(53546011)(4326008)(66556008)(52536014)(5660300002)(2906002)(9686003)(110136005)(8936002)(8676002)(33656002)(186003)(76116006)(55016002)(7696005)(478600001)(86362001); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata: IqJuLusHIfLNBuAAgcikxseqQoxEsiIgPwHyR74dHWbO/PUkGOR9l5p8RLYvc97EZs2kiANTxZmMzCLsQ43xqcBhHONWcaG1Kr2LL0KZ7dwJebVOuldJ9b2Yr/VqG1aLqAvUt1+4oJgHBtVUPZ4BZ1/yRl0AreBIMRwMTMIFXbWKXn79vI6mHXNteNK1IKaHsP709A5P3uUSIyFgkXAOpjrtYCWOvbZlGVdwbYHhlIAkWB5Qe0IFeL0COgXW4EyLBDTHuhN3mta7/c5R1irou+1bn487nOy+Ie3qaVN/4mQalh8hViKoB6l4AM+zzgK/GJfFbJ7eDwJKaJ111JmnIYrXE25f6YSCH1PG30IeVKbpouWXLfsGQ5JZNQkH7ky/nI5TAf7pmM7xg81LZtYd9HQ/b57aK90aPdM7VOA2OYUyrizZIWZ+Y69d4/OXMyTqH1tDlgmXUOMYif7B8Ug3bsuyX6MjI/zzqziGkjgniUZWi1UfzyUxt8mfoJbSsVlNLWRh98tYZGDLhGmnG8SgLfTL1jzmHeh4Smebq7aqDJ58jnzb71GyGEPDFsx1vAtY/7XQx5oIUvU9VLwtHYELqSHluRGPhHL+gIuh2P3ZmyGVnC/umRFDVN05K+eBBieyR8sc5kK0YMSz+oOPO4HGUA== Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: MN2PR12MB4286.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 9757ad98-3626-4326-9c8c-08d86b860672 X-MS-Exchange-CrossTenant-originalarrivaltime: 08 Oct 2020 12:31:04.9465 (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: UX15X/nj3zh09y1LaWx9hFku+qOSN5iAORXd//mIYsokJjaOeI6Y5Pq3GPBiXxodbGo+oDVKwUTpGd9aCuvb7w== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR12MB4344 X-OriginatorOrg: Nvidia.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nvidia.com; s=n1; t=1602160273; bh=bfwIU0gBkV+9dJGAD8KiVvhB2Vg1DxuzK6kgSKfSFYA=; h=ARC-Seal:ARC-Message-Signature:ARC-Authentication-Results:From:To: CC:Subject:Thread-Topic:Thread-Index:Date:Message-ID:References: In-Reply-To:Accept-Language:Content-Language:X-MS-Has-Attach: X-MS-TNEF-Correlator:authentication-results:x-originating-ip: x-ms-publictraffictype:x-ms-office365-filtering-correlation-id: x-ms-traffictypediagnostic:x-ld-processed: x-ms-exchange-transport-forked:x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers:x-ms-exchange-senderadcheck: x-microsoft-antispam:x-microsoft-antispam-message-info: x-forefront-antispam-report:x-ms-exchange-antispam-messagedata: Content-Type:Content-Transfer-Encoding:MIME-Version: X-MS-Exchange-CrossTenant-AuthAs: X-MS-Exchange-CrossTenant-AuthSource: X-MS-Exchange-CrossTenant-Network-Message-Id: X-MS-Exchange-CrossTenant-originalarrivaltime: X-MS-Exchange-CrossTenant-fromentityheader: X-MS-Exchange-CrossTenant-id:X-MS-Exchange-CrossTenant-mailboxtype: X-MS-Exchange-CrossTenant-userprincipalname: X-MS-Exchange-Transport-CrossTenantHeadersStamped:X-OriginatorOrg; b=ggX0uIIMIrtFHPDvXEc6ZFdXlQ5kAuyo3BO3Glj9g8xVv4IaKPCRFssALkNAvPYG/ 5DXthKjcoeEhV42Q78wsYU5gRhAa+tL7ZP0S3stQKg/CbSq56lM3nphRjkB7IUwkN5 kyEtXNhuLVsCt5hY5/62qSFl1sbHuaDALguJshyI9Uk20dXJtfXZomrlv06mykjlLB FSm3Be3vePIWqz8SjfG0mX5jKlNKoSvMLYiFD4j3PhIAy0+OF5mnbZt/Plpi58h7Bp 8B+twQUwwD0CXF6hjLJCO80Fbg6n0DdlFDjCI9pXo8ggqf+CLMOtzCpATVLh7Lr0mp UEAUYrgAix8hw== Subject: Re: [dpdk-dev] [PATCH v3 3/6] ethdev: add API to get hairpin peer ports list 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" Hi Bing, > -----Original Message----- > From: Bing Zhao > Sent: Thursday, October 8, 2020 3:05 PM > Subject: [PATCH v3 3/6] ethdev: add API to get hairpin peer ports list >=20 > After hairpin queues are configured, in general, the application will > maintain the ports topology and even the queues configuration for > hairpin. But sometimes it will not. >=20 > If there is no hot-plug, it is easy to bind and unbind hairpin among > all the ports. The application can just connect or disconnect the > hairpin egress ports to / from all the probed ingress ports. Then > all the connections could be handled properly. >=20 > But with hot-plug / hot-unplug, one port could be probed and removed > dynamically. With two ports hairpin, all the connections from and to > this port should be handled after start(bind) or before stop(unbind). > It is necessary to know the hairpin topology with this port. >=20 > This API will return the ports list with the actual peer ports number > after configuration. Either peer RX or TX ports will be gotten with > this function call. >=20 > Signed-off-by: Bing Zhao > --- > v3: > 1. change the direction from bool to unsigned int type > 2. add length to protect the array from getting corrupted > --- Acked-by: Ori Kam Thanks, Ori