From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM02-BL2-obe.outbound.protection.outlook.com (mail-bl2nam02on0069.outbound.protection.outlook.com [104.47.38.69]) by dpdk.org (Postfix) with ESMTP id 1B5D31B1C1 for ; Fri, 6 Oct 2017 15:00:27 +0200 (CEST) Received: from CY4PR03CA0018.namprd03.prod.outlook.com (10.168.162.28) by CY4PR03MB2694.namprd03.prod.outlook.com (10.173.43.137) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.77.7; Fri, 6 Oct 2017 13:00:25 +0000 Received: from BL2FFO11FD040.protection.gbl (2a01:111:f400:7c09::186) by CY4PR03CA0018.outlook.office365.com (2603:10b6:903:33::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.77.7 via Frontend Transport; Fri, 6 Oct 2017 13:00:25 +0000 Authentication-Results: spf=fail (sender IP is 192.88.158.2) smtp.mailfrom=nxp.com; monjalon.net; dkim=none (message not signed) header.d=none;monjalon.net; dmarc=fail action=none header.from=nxp.com; Received-SPF: Fail (protection.outlook.com: domain of nxp.com does not designate 192.88.158.2 as permitted sender) receiver=protection.outlook.com; client-ip=192.88.158.2; helo=az84smr01.freescale.net; Received: from az84smr01.freescale.net (192.88.158.2) by BL2FFO11FD040.mail.protection.outlook.com (10.173.161.136) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.77.10 via Frontend Transport; Fri, 6 Oct 2017 13:00:23 +0000 Received: from [10.232.14.39] ([10.232.14.39]) by az84smr01.freescale.net (8.14.3/8.14.0) with ESMTP id v96D0H8x001146; Fri, 6 Oct 2017 06:00:18 -0700 To: Thomas Monjalon CC: , Jan Blunck , Hemant Agrawal References: <20170812102220.27773-1-shreyansh.jain@nxp.com> <422ce0c6-7868-b601-2fe9-e361497d7b14@nxp.com> <2075457.Vvey9mxHue@xps> From: Shreyansh Jain Message-ID: Date: Fri, 6 Oct 2017 18:42:33 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 MIME-Version: 1.0 In-Reply-To: <2075457.Vvey9mxHue@xps> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-EOPAttributedMessage: 0 X-Matching-Connectors: 131517684248457860; (91ab9b29-cfa4-454e-5278-08d120cd25b8); () X-Forefront-Antispam-Report: CIP:192.88.158.2; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(6009001)(7966004)(336005)(39860400002)(39380400002)(376002)(346002)(2980300002)(1110001)(1109001)(339900001)(189002)(76104003)(377454003)(199003)(24454002)(68736007)(229853002)(64126003)(230700001)(53936002)(58126008)(76176999)(50466002)(105606002)(106466001)(305945005)(8676002)(8936002)(54356999)(316002)(81166006)(81156014)(31686004)(104016004)(83506001)(53546010)(356003)(77096006)(498600001)(85426001)(2906002)(54906003)(93886005)(5660300001)(2950100002)(23676002)(6916009)(65826007)(189998001)(6666003)(6246003)(33646002)(65806001)(65956001)(31696002)(4326008)(97736004)(50986999)(8656003)(47776003)(86362001)(69596002)(36756003); DIR:OUT; SFP:1101; SCL:1; SRVR:CY4PR03MB2694; H:az84smr01.freescale.net; FPR:; SPF:Fail; PTR:InfoDomainNonexistent; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BL2FFO11FD040; 1:qfr1jtzBgXLj8jLDNF6G3FJMz8cP6o7a5uit0UWbmt+xjts2EV3hzas9smVtJuFcM3H4TgfMZlbs76jExv8AA2a0uhsT/csbvkVproOC3LIvm0kXxnIa7Yhwxu9B8kIk X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 9613ca38-c03a-49a9-b284-08d50cba35c6 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(2017052603199)(201703131430075)(201703131517081); SRVR:CY4PR03MB2694; X-Microsoft-Exchange-Diagnostics: 1; CY4PR03MB2694; 3:i8ftSp5adGGSqJ9As3KSESTElZoP0IYol7/anx4/hxHlhkzAnqrgEnZN3lQWLNafR3PdJmtNUUlpC7uM+fEikOunDSL5LfWFu6hzOJzeeOLGbwv7AB/DOGfU6KO89RSFtXUbJ6AojJkEk3YhHy56J4xVsTcWYNOl3eR+x4SyetxLmNzGGIATbs2I5HkxILKiZEI/C3ghYR4Gl/GmG51pZSWT7xmdfCPEYwU5N4OxGV5++ZjsdmDNBNUF/ZukMpj271Lv9kwU5e5SdFs8JEySBL6rG3kbGUUcZXaI5ee7qLuvohXxIZi4TGPfPANTc0nJGT4SeeKTeN6PBI2cSX6QjA==; 25:CZnT31KwT6PhKk+Yv0ILhn2adCbOeEf2F3z3SJT5nenHoOzuVaUt3ae67mPoqJBGToBOySMxxWO3G11rDkRG1wuB1M4BIRoKpkdQPaU1FlAt8q84Sb91JJUec/+O2xoxicMsvunGsySG1bvFvitP/5GtbDoKWBEKCB+svNVsgqMqsMEAf1EehknIOR3WcJsN92H6jNdaEV8KCCMh8o9ikQAn/1mlwNVDhzxizbTDSH3IlreerA+sx84gmx6J9Lkx43+Gmlr87zH0otZCCNKpAK1T1HQZ9I9MSXf5WbrwrO//8TLsFUmWeh3WT2aMAO0A1di55YE0zLR94obKJmjF5w==; 31:WHa3EDkEteYvhDRkt1/6QCdMdx3I/paI7N/GysnvUr3Fhz3mwsx4iPgmheoFA5MD+cEQZUz7oLdVLnSSb8/c4VQHY4qSXVOmF4f0KMvZBi3+TeN05MLWEoKLFjk9phkq1UUz/j8Ebcjrt3mtC8Oa3w5rOawCe3o5MyX+N0l+pRXaR6oAiUQOUq9yR8BKe1MR5dm5cSvZQ+vcFo6VnZn7ZZ/B2yBa3XltJD8taBJ0qzE= X-MS-TrafficTypeDiagnostic: CY4PR03MB2694: X-Exchange-Antispam-Report-Test: UriScan:(185117386973197); X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6095135)(2401047)(5005006)(8121501046)(10201501046)(100000703101)(100105400095)(3002001)(93006095)(93001095)(6055026)(6096035)(20161123556025)(201703131430075)(201703131433075)(201703131441075)(201703131448075)(201703161259150)(20161123561025)(20161123563025)(20161123559100)(20161123565025)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:CY4PR03MB2694; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(400006)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:CY4PR03MB2694; X-Microsoft-Exchange-Diagnostics: 1; CY4PR03MB2694; 4:MGYgK0xWzjYkty3W75V+G8V2OlsODmXAw6/fGEW5nNZnWqNaGdnNL76f/kllH8/QuFtk9TvihhsX9qhi02ufCwOoVpYJj9Rt3/Tcl6aNM2pBBY1NC4gmpisEgCeLgP/lBLHhzvkd65wl4XFcLfQfgfThhryBstloXKtoD8DGpbHoL0zHNFLyTnqzObhnrwhIBvZ/49x/87lTTw5/EqrEqHCCuLzm2o1NybF3U1tUQH9aj/MRdcpwQDBcTvsD1HUuQbiMjpDr82x/1FRWIl0Qo2z+aL0zrCO25crlGpMQgRg= X-Forefront-PRVS: 0452022BE1 X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtDWTRQUjAzTUIyNjk0OzIzOjJxZmZxUmhaMVpodkhRTDNuNWt5UzZlU2hh?= =?utf-8?B?T1RPZWdCTy9LMHpUdUVCdnhTTy9hS3J2ZWpiODRZNEUrNFBTU2gxd25mdFFN?= =?utf-8?B?ZjRSZHU2Y1dVVEsyZVEza2NvS3VTVWF4bC8rbDZZdWpCNHVJY3ZQbUJ4L1ls?= =?utf-8?B?SC80N0NabHl2eDBvemJJZU41cUgxZ2ZPd3RTQ3JFL2hOQTdXbzZsQ0VGbEsz?= =?utf-8?B?NWZGU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ics: 1; CY4PR03MB2694; 6:iXWDvf+sneBo5V3xjkR7ce6TWwoHzCd01hg4oCG7zSGX6KVAik8RthI4qz0CLY/vN7HhAdcOYqXz+YMkXSQ5kyj9cvVLMcWczEL44xc/okZfomRTC8cG2lYvLd5mOcfHS4z+QkGXP1ALk27N2OEr0gyApzqZ01Aijn1AyIf9OMjtGYxeC8ADX+QQIpjXEHfRTLMkHY5/+qblN9Z2BowXqcBSW0p/G7WFLLMMkBgMfk/GJH9lt6d7uJvAA1a1c68T8S8T2sfiG9TI79J5o2w3Ygjq4VqW5h2iR3MNn5SdHXGEWHul8nt/X6qQQFXkHdKj06/ARrdotvcbR8SqbQUumw==; 5:Vrw/YoTg3miIsXfsTteJhN+0KkQCpwyhSbRqNS/r909HCVx7syLhv4zWXbi6g8LLJ6X1jk00LXH0+DqbTiUSNLX1dlxKby6ei/cOvLGe/A0AQ21+PuC7c8fJ/g7zYJKKtZN0ddVSIAIaO7tSL4DRQQ==; 24:9weOTRypA1d4bHXfb9pisWwbZcd9MAWg1mKkg6RO5uulMIVgcFT+s43vleyHrYilWeeQW+P0Gv4imLZKdISsuqZ1J/OrR6dPCcTSUlmEkVM=; 7:9cxlh8ugAsYAbMjW/ydhCvJiCjPXNmEDxD6KbM2clkfKSz5SCbEwacNZbsBJ3nEgIrbIodkQlcco5pBq++9gaE3irrhKtWSE7LkZzHCyy29TktWNikZnbmjWBcpucGBHX7znrTiQaFigq3fwJzNWxB3OEWYaeOLE3sHLOvd7BlKwdPXygcBEgFlcHCpQ4RGQJ9X0Xdc+/hr9brNuz3RtLS3WMt8A59VA4xQBS3ZPQx4= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Oct 2017 13:00:23.2233 (UTC) X-MS-Exchange-CrossTenant-Id: 5afe0b00-7697-4969-b663-5eab37d5f47e X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=5afe0b00-7697-4969-b663-5eab37d5f47e; Ip=[192.88.158.2]; Helo=[az84smr01.freescale.net] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR03MB2694 Subject: Re: [dpdk-dev] [PATCH] eal: bus scan and probe never fail 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: Fri, 06 Oct 2017 13:00:27 -0000 On Friday 06 October 2017 04:51 AM, Thomas Monjalon wrote: > 19/09/2017 20:51, Jan Blunck: >> On Mon, Sep 18, 2017 at 1:36 PM, Hemant Agrawal wrote: >>> Tested-by: Hemant Agrawal >>> >>> >>> On 8/12/2017 3:52 PM, Shreyansh Jain wrote: >>>> >>>> Bus scan is responsible for finding devices over *all* buses. >>>> Some of these buses might not be able to scan but that should >>>> not prevent other buses to be scanned. >>>> >> >> If scanning the bus fails this is signaling an error. In that case we >> might even want to unregister the bus. > > A scan error seems important enough to be reported to the caller. > OK to continue scanning other buses, but an error code should be returned. Isn't that counter intuitive if the scanning continues after error and an error is expected to be returned from it? What if there are more than one error? Which one is reported. As for cleanup, bus un-registration is not correct. Scan has failed, which might mean some assumption that bus took for scanning for devices doesn't exist for time being or present platform. Either way, I think whatever rollback needs to be done for scan failure, would be done by the bus->scan() implementation. Let me know what you think - I will make changes to the patch and push again. > >>>> Same is the case for probing. It is possible that some devices which >>>> were scanned didn't have a specific driver. That should not prevent >>>> other buses from being probed. >> >> Absolutely correct. > > Yes > When we will have a probe notification, we will be able > to notify the upper layer that a device probing has failed.