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 04E78A04A7; Mon, 24 Jan 2022 10:32:42 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 92AB8427B4; Mon, 24 Jan 2022 10:32:42 +0100 (CET) Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by mails.dpdk.org (Postfix) with ESMTP id 2EB70410F5 for ; Mon, 24 Jan 2022 10:32:41 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1643016761; x=1674552761; h=message-id:date:to:cc:references:from:subject: in-reply-to:content-transfer-encoding:mime-version; bh=+v8XBYZQc8LvEnjfYqczkkfLtH+6trIGQtWftaccmUA=; b=QZk9BG+Y/gIwoPTieG935JUOXBWMecbmKocZ8CLjjCY1R0LhymjYQYtL FGYKVIQhrfqSJE0S3S8E4FlNZH2sj7BNQz1FQP0uVTztMxaWsPDlDGMz+ USYPPvePxBOZefdLPb7clNq4Ew6KdVRYcvTVG5ZqbAmm5PKbi0bTvHAoA f3wkEU3qvVbGTJMKe4KsARZrb4KaIl/hqAPGusrH2XGYoFgPtV5MWtTvG JBypK1ZTN2GxuX/ft9oOC1P+chqady7ro3oCBDOdU83J8TxK9EbLHtVyZ WYt0vLJHo0ZCP7+kh3kOFsKayVlk1vjYs8m+pXAPaD+wTtmCP7bEPtCQB g==; X-IronPort-AV: E=McAfee;i="6200,9189,10236"; a="270440496" X-IronPort-AV: E=Sophos;i="5.88,311,1635231600"; d="scan'208";a="270440496" Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 Jan 2022 01:32:40 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.88,311,1635231600"; d="scan'208";a="476658802" Received: from orsmsx603.amr.corp.intel.com ([10.22.229.16]) by orsmga003.jf.intel.com with ESMTP; 24 Jan 2022 01:32:40 -0800 Received: from orsmsx612.amr.corp.intel.com (10.22.229.25) by ORSMSX603.amr.corp.intel.com (10.22.229.16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.20; Mon, 24 Jan 2022 01:32:38 -0800 Received: from ORSEDG602.ED.cps.intel.com (10.7.248.7) by orsmsx612.amr.corp.intel.com (10.22.229.25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.20 via Frontend Transport; Mon, 24 Jan 2022 01:32:38 -0800 Received: from NAM11-CO1-obe.outbound.protection.outlook.com (104.47.56.173) by edgegateway.intel.com (134.134.137.103) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2308.20; Mon, 24 Jan 2022 01:32:37 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RkolMa9C//2BkdHJNDdbj8CIdXhI2fC9UsRqgZe8mGvu/rtULNxtCLOkITAp3XOwmj1JAcz43EUNHqg2y8gY01eh/DbBg7nNjYAe4jRamQBITva6nAfqarHMQwnkdDcRCZIcBZ0LJK3thfU9vwQ+GiFqwyH2BO9+MHtC+WDiO0FDnE4RbXZrAMZF5sv49RkmZNdeZ+ZX2SIggnHQI7w0bX4BKQ5GCw33ODPgp6tmVTyTsYGTBD0MrcLT5i5T3clYGWmBBdLjEgC8QtHDHZJZrur2qeMjkAZdn+Rk4fWJOaRw/VkIYl61ftQCH1UrlVfh2xdgjNh1JEk4kC+JWfnrFg== 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=qDIXssnRonUT1xQ1oleZsUPdx3nc2z75SzryHQPCxHE=; b=UGE/r6WyKcNGXupzlO0IZNSmI0wSgML2d05VZp/sv3avyWoWtjo5+33Op2TkAhbmz8m5KjhespeUmU3FS+N92JMDNixce5GNT6Oqnp/vlVN7I/fl9Qnql/OZJm3x0cpK9Fbdlregl4vKnvV27G1LKmC8qFxEs8EwlC9zz7pwZV1gevqCjPBzMAnykNdSgeTg7OvSMyH+frbupFP5pge1dFGGprHQZhZ0q6vrB/IcEbjUDfpeXkff/c97DscbAOTyP+Dm/0RQVgYY9vUKNKzvXAnyQSp8gX5v0Rg3g6Ip4RjdI3BV/ytKbfQta6INAebtfZ5UW3xcev6KjGnq0Ckl3A== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; Received: from PH0PR11MB5000.namprd11.prod.outlook.com (2603:10b6:510:41::19) by BN6PR1101MB2324.namprd11.prod.outlook.com (2603:10b6:404:9d::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4909.8; Mon, 24 Jan 2022 09:32:35 +0000 Received: from PH0PR11MB5000.namprd11.prod.outlook.com ([fe80::5046:8550:928d:850e]) by PH0PR11MB5000.namprd11.prod.outlook.com ([fe80::5046:8550:928d:850e%7]) with mapi id 15.20.4909.017; Mon, 24 Jan 2022 09:32:35 +0000 Message-ID: Date: Mon, 24 Jan 2022 09:32:30 +0000 Content-Language: en-US To: Kumara Parameshwaran CC: , Kumara Parameshwaran , "Stephen Hemminger" References: <20220120111215.76058-1-kumaraparamesh92@gmail.com> From: Ferruh Yigit Subject: Re: [PATCH] net/tap: Bug fix to populate fds in secondary process X-User: ferruhy In-Reply-To: <20220120111215.76058-1-kumaraparamesh92@gmail.com> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: LO4P265CA0013.GBRP265.PROD.OUTLOOK.COM (2603:10a6:600:2ad::9) To PH0PR11MB5000.namprd11.prod.outlook.com (2603:10b6:510:41::19) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: b313f007-d945-4121-a0f1-08d9df1c742c X-MS-TrafficTypeDiagnostic: BN6PR1101MB2324:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:4714; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: UMk90A4uwqm2tIM/Rjc7S1A473B5xtR3N6dbr0hIzoSGJ1lDozqEAE26MjoUTrdrFpe4Zc3yz5W2O+H85siYhSmWbZ8QrH8ON9P/FgJ7ZUFBooZPf+XSxClYiyzscBUWbPL3c1GwXRN7skdzfTp+Oos/K14FRarMZgOy4nJuEXr40IEhgXxyPtd2A9LZOxUo8HbinIGN+ByRgpCg6aVKnqepqsO+M1XGopY+V/cN5k/Z+Ca2U6lSU5R+6yN9hrvi3IqK/UmNRmQWH0AYtDWvL9fR0WaGoy1P14vUte3Yed+JB+W0RZmJ84Hhs4Qkjy+1547Zb0f6tPJiu28AhjQl+GpiS1F/S8FuLZzDFL+Evb0Nuy4ECPCpdLY1aExHGcumwXZM3A0zbU3SsOuYxgK+9/uwObKFw5QDJCG9NnRVzG/Ml4gxvHJxX+IugPG6c/ofMvk0+Z0UV4luRtwHTF/G+9/02A9EjSsQJzNgByuOuvokweHY4lxv6TAioHd1ae9U26p+Rq+IpWQAleMPmcrbSUf5rvtJoytDgnyjayUGCCZXMUgfu4U3vjmpZ+Urp6Zf1JDHzWLE4NtYFoewnsAcIe9+jOXZ7a3RVhph1EJS47ZdNRVq3+l3haFqPUAmZKtvmFB+3TvFKaSum8g7Lm0e3lWF3ab5n3EZvocsSkjHXW/N5MyeeASecY0iK+hmqMe5wXluRbC72taznR+v0OOMCA== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:PH0PR11MB5000.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(366004)(508600001)(83380400001)(6512007)(6506007)(5660300002)(2906002)(31686004)(2616005)(31696002)(6486002)(6666004)(66476007)(4326008)(6916009)(66556008)(66946007)(36756003)(8936002)(8676002)(86362001)(82960400001)(26005)(54906003)(186003)(53546011)(44832011)(316002)(38100700002)(45980500001); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?dE45dUEyRVVBV2x3QUUvSHg2c0xtMFBaUDZ4cFFWUmtYRnZ2K3hWMnpiT2M3?= =?utf-8?B?c1dPT0ZzUjFBckkxbmdJdGlSTjVPSGE3d3UzUlV0M1NVeExDbTl2OWora3Y0?= =?utf-8?B?SEhUUlFmeGtYY3cya05rMVRHcGEvWU5NUG54b1B3SCtjbUJKT3FFSDBoQ0hU?= =?utf-8?B?eFpQRUxHZ0psWGtlTlpMdS9PTjR6eXJEcDdmdmVuOFdvVDFETlJ6TFpQL2dI?= =?utf-8?B?dkNNT2ZvbVY4bm5FRGdjWWYrcCtKdHpuQkt6N0trN3Ird0g4RHZLMlBUMmdL?= =?utf-8?B?VHBwOTUxbWpWajRlL0JIbGI4U1NHT25nRnVmNE1xZnNsSzFXYjllK2UzUHNi?= =?utf-8?B?RGtaNmtGSWdDak82R05BakVLNUJBYmFManJwNFdvbUZjOFJ3WWpPZGJ5eFpM?= =?utf-8?B?QUM3UW5zQlg5ZFJJNmdlOS94VlBvRHVwMmppYkNYK29TenViV2JsNXV6K2Ja?= =?utf-8?B?UjJLVWQ4SnAxanNWTVlmdWFEQXd4N0ZUSEF5dERRWElXOTNJQmJmUzZ0OVN0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ZzZFcHVPTlgwak1Y?= =?utf-8?B?QU1XRnlucS9HNGVnRHJBdVA5ckt3UGFxVmttRHhHRGQ0eFRnY3BFbUFMWi92?= =?utf-8?B?QVoyT1dnT1ZaOWt6R2NTWTFsdzVPbXFBTklzNDBBRXNlbEtwUFNvMXIwV1JI?= =?utf-8?B?STFkYXBWMmNRZlcwQUlCdE1UMDFCcDFUL1gvVXU3RDJOVDZpZGNlRUNKeDNQ?= =?utf-8?B?UjVxTkdGckpsc2RrQWwzNUVnVVdMYUxiK1dqbTM3Z0VZRnkxakZQdkJpWmlS?= =?utf-8?B?Yk1XYXd0WmRPKy9wL0NUOTNpcmg2ZnF1UUR1UE9OME9yaU5lVVJqa2ZuMmpD?= =?utf-8?B?SjNNZUFGS2wwN0N6WW1Ea3NYQnRsUXh5RmJQaTh2eVFBQjNuQkwwUzFITFIx?= =?utf-8?B?dXhBZVZMUEE5SzJ4OHhRcHh5WkJhT1ljcU0yb2Zld3UxSDkwSzUwZ3N0T2Js?= =?utf-8?B?V2M2NEpCSi92MDF6VGMzaVhOSUV3SmNQbGJQMElmY1AwWmNUeGc1WnpHTTFJ?= =?utf-8?B?NkdKaVlscllwV3JpeXgralhrUDlxYkZsRXN0OVF5VXFEMVQrVmx0THJGNm0z?= =?utf-8?B?czh0SG5PWUVPNzFiZGxGdnNXL1JSeUM3UmY3bDBRMlVPRStwZEsyckVTa2JK?= =?utf-8?B?TGxyNDdsQVBiQk9YNWNkcnUrU2I5VFJuaFlLYy85MGx2UEY1cHV1Y2piU2Y1?= =?utf-8?B?UmNzeXloOS9Sd0V3R2pYY01qV2pPU0g4NHhucW5kZnhlaStwM3NBT1hmWmtJ?= =?utf-8?Q?fl76JIRrxreeBtJt2lvF3nA=3D?= X-MS-Exchange-CrossTenant-Network-Message-Id: b313f007-d945-4121-a0f1-08d9df1c742c X-MS-Exchange-CrossTenant-AuthSource: PH0PR11MB5000.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Jan 2022 09:32:35.3451 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: OF5ReUVG6xX1pZ0ea8gO3BvQYD9Y6Xw/ILdM55II11u2dtMe2cnJKsh+rZDPS9m+ZSm0bsGVBmxiQ91DSCUTGw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN6PR1101MB2324 X-OriginatorOrg: intel.com 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 On 1/20/2022 11:12 AM, Kumara Parameshwaran wrote: > From: Kumara Parameshwaran > > When a tap device is hotplugged to primary process which in turn > adds the device to all secondary process, the secondary process > does a tap_mp_attach_queues, but the fds are not populated in > the primary during the probe they are populated during the queue_setup, > added a fix to sync the queues during rte_eth_dev_start > Can you please make this a two patches set? First one is the new API patch, second one is the tap patch that uses the new API. > Signed-off-by: Kumara Parameshwaran > diff --git a/lib/ethdev/rte_ethdev.h b/lib/ethdev/rte_ethdev.h > index 096b676fc1..d9594c0460 100644 > --- a/lib/ethdev/rte_ethdev.h > +++ b/lib/ethdev/rte_ethdev.h > @@ -4987,6 +4987,22 @@ rte_eth_read_clock(uint16_t port_id, uint64_t *clock); > int > rte_eth_dev_get_port_by_name(const char *name, uint16_t *port_id); > > +/** > +* Get rte_eth_dev from device name. The device name should be specified > +* as below: > +* - PCIe address (Domain:Bus:Device.Function), for example- 0000:2:00.0 > +* - SoC device name, for example- fsl-gmac0 > +* - vdev dpdk name, for example- net_[pcap0|null0|tap0] > +* > +* @param name > +* pci address or name of the device > +* @return > +* - rte_eth_dev if sucessful > +* - NULL on failure > +*/ > +struct rte_eth_dev* > +rte_get_eth_dev_by_name(const char *name); > + Can you please move this to 'ethdev_driver.h'? > /** > * Get the device name from port ID. The device name is specified as below: > * - PCIe address (Domain:Bus:Device.Function), for example- 0000:02:00.0 > diff --git a/lib/ethdev/version.map b/lib/ethdev/version.map > index c2fb0669a4..168898a27c 100644 > --- a/lib/ethdev/version.map > +++ b/lib/ethdev/version.map > @@ -128,6 +128,7 @@ DPDK_22 { > rte_flow_isolate; > rte_flow_query; > rte_flow_validate; > + rte_get_eth_dev_by_name; > And move this to 'INTERNAL' block? > local: *; > };