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 59A02A0471 for ; Mon, 17 Jun 2019 12:54:47 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 2D61C1BEEE; Mon, 17 Jun 2019 12:54:47 +0200 (CEST) Received: from mailout2.w1.samsung.com (mailout2.w1.samsung.com [210.118.77.12]) by dpdk.org (Postfix) with ESMTP id E35961BEE4 for ; Mon, 17 Jun 2019 12:54:42 +0200 (CEST) Received: from eucas1p2.samsung.com (unknown [182.198.249.207]) by mailout2.w1.samsung.com (KnoxPortal) with ESMTP id 20190617105441euoutp02f22ee6eb9acffa353e69c160c95425b6~o9wdUzfqO3198731987euoutp02S for ; Mon, 17 Jun 2019 10:54:41 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout2.w1.samsung.com 20190617105441euoutp02f22ee6eb9acffa353e69c160c95425b6~o9wdUzfqO3198731987euoutp02S DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1560768881; bh=tYz1QwJWWq8Tnprm2iRSSL30h6aDp9rTttQ08lX6I2c=; h=Subject:To:Cc:From:Date:In-Reply-To:References:From; b=DtXK1GAtyZRxkE+c6RxoaAeiKJkwLxjvf6novF4gt1kdtnWWboS4OVf1J7bB9Rzek 0qbUsisNeTpcgDlP9TJrN6MH70bYIxEMEdIcksgBpq8abZEbhpmRylwIjvEg+e7GS3 vJekwUTZ7JgyhC26zJ6S+JMaxq1BG5UXQBmteUkA= Received: from eusmges1new.samsung.com (unknown [203.254.199.242]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20190617105441eucas1p1ac72327277faad11b677023a07872bfd~o9wc1G8Ol1428514285eucas1p1m; Mon, 17 Jun 2019 10:54:41 +0000 (GMT) Received: from eucas1p1.samsung.com ( [182.198.249.206]) by eusmges1new.samsung.com (EUCPMTA) with SMTP id 3E.15.04298.071770D5; Mon, 17 Jun 2019 11:54:40 +0100 (BST) Received: from eusmtrp1.samsung.com (unknown [182.198.249.138]) by eucas1p2.samsung.com (KnoxPortal) with ESMTPA id 20190617105440eucas1p25d4362abb5eae38b8b1cdd5196255c46~o9wb_o-4k1633216332eucas1p2i; Mon, 17 Jun 2019 10:54:40 +0000 (GMT) Received: from eusmgms2.samsung.com (unknown [182.198.249.180]) by eusmtrp1.samsung.com (KnoxPortal) with ESMTP id 20190617105440eusmtrp12e874175890ca88cd79b8a09c31632d4~o9wbvBIY40415104151eusmtrp12; Mon, 17 Jun 2019 10:54:40 +0000 (GMT) X-AuditID: cbfec7f2-f2dff700000010ca-c0-5d077170a5c1 Received: from eusmtip1.samsung.com ( [203.254.199.221]) by eusmgms2.samsung.com (EUCPMTA) with SMTP id 27.CB.04140.F61770D5; Mon, 17 Jun 2019 11:54:39 +0100 (BST) Received: from [106.109.129.180] (unknown [106.109.129.180]) by eusmtip1.samsung.com (KnoxPortal) with ESMTPA id 20190617105439eusmtip1994e41f2b7758b3fd593e9888d21ac0a~o9wbKRFQo2597325973eusmtip1c; Mon, 17 Jun 2019 10:54:39 +0000 (GMT) To: dev@dpdk.org Cc: Thomas Monjalon , Anatoly Burakov , Jan Blunck , Qi Zhang , Kevin Traynor , David Marchand , stable@dpdk.org From: Ilya Maximets Message-ID: <12851ead-09c8-54e9-d2c6-c0b5cbcab200@samsung.com> Date: Mon, 17 Jun 2019 13:54:38 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.7.0 MIME-Version: 1.0 In-Reply-To: <20190606100228.19959-1-i.maximets@samsung.com> Content-Language: en-GB Content-Transfer-Encoding: 7bit X-Brightmail-Tracker: H4sIAAAAAAAAA01SbUhTYRjt3b27985aXKfho1bSKCi/BaNbiBYFDfrjL4nC6qbXKblpm599 KeY3YaKguSQtFZ1SiS0tS62L36KhpGSmrojEmWbbQiyx3O4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IxNLPUNj81grI1Ml fTublNSczLLUIn27BL2Ms9NesxS85q54s+QsYwPjFs4uRk4OCQETiQ2LJ7N1MXJxCAksZZT4 1ziPGSIhJfHj1wVWCFtY4s+1Lqii94wSF5c8AksIC7hLLFxykRHEFhEQkPjcuRisiFmglUni 9eyrLBAdBxglGl6+BhvLJqAjcWr1EbAOXgE7iaZDB8BsFgFViX3fP4PZogIRErN3NbBA1AhK nJz5BMzmFLCRWNq+kg3EZhZQl/gz7xIzhC0u0fRlJSuELS+x/e0c5gmMQrOQtM9C0jILScss JC0LGFlWMYqklhbnpucWG+kVJ+YWl+al6yXn525iBMbltmM/t+xg7HoXfIhRgINRiYfXo5Et Vog1say4MvcQowQHs5II7zw7llgh3pTEyqrUovz4otKc1OJDjKZAz01klhJNzgemjLySeENT Q3MLS0NzY3NjMwslcd4OgYMxQgLpiSWp2ampBalFMH1MHJxSDYxM/9su74yw4Vt61rpv4vn9 Nfzb9G613r4QP0Gkc9ob60TX62Uc1742ru76ey2f6daUr7Pu96Z9qbL27T46vWxar+m9Dxe3 NhT96eeJcLnIvPMK8+xPXtPjzdfJFR+aoTzNZ6J3eI/fKUMDXrk/nouWKl9417WC5WnyP4l6 c4mWvnq2ii8RapZKLMUZiYZazEXFiQDBFZ604QIAAA== X-CMS-MailID: 20190617105440eucas1p25d4362abb5eae38b8b1cdd5196255c46 X-Msg-Generator: CA Content-Type: text/plain; charset="utf-8" X-RootMTR: 20190606100234eucas1p2a73029a37495cde21bce3b9a3b023ac4 X-EPHeader: CA CMS-TYPE: 201P X-CMS-RootMailID: 20190606100234eucas1p2a73029a37495cde21bce3b9a3b023ac4 References: <20190530132526.3496-1-i.maximets@samsung.com> <20190606100228.19959-1-i.maximets@samsung.com> Subject: Re: [dpdk-stable] [PATCH v2] eal: fix positive error codes from probe/remove X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" On 06.06.2019 13:02, Ilya Maximets wrote: > According to API, 'rte_dev_probe()' and 'rte_dev_remove()' must > return 0 or negative error code. Bus code returns positive values > if device wasn't recognized by any driver, so the result of > 'bus->plug/unplug()' must be converted. 'local_dev_probe()' and > 'local_dev_remove()' also has their internal API, so the conversion > should be done there. > > Positive on remove means that device not found by driver. > Positive on probe means that there are no suitable buses/drivers, > i.e. device is not supported. > > Users of these API fixed to provide a good example by respecting > DPDK API. This also will allow to catch such issues in the future. > > CC: stable@dpdk.org > Fixes: a3ee360f4440 ("eal: add hotplug add/remove device") > Fixes: 244d5130719c ("eal: enable hotplug on multi-process") > > Signed-off-by: Ilya Maximets > --- > > Version 2: > > * Fixed API callers. > * Check for probe moved from 'rte_dev_probe' to 'local_dev_probe'. > > app/test-pmd/testpmd.c | 4 ++-- > drivers/net/failsafe/failsafe.c | 2 +- > drivers/net/failsafe/failsafe_eal.c | 4 ++-- > drivers/net/failsafe/failsafe_ether.c | 2 +- > drivers/net/vdev_netvsc/vdev_netvsc.c | 2 +- > lib/librte_eal/common/eal_common_dev.c | 5 ++++- > 6 files changed, 11 insertions(+), 8 deletions(-) Any more thoughts on this patch? Or can it be merged? Best regards, Ilya Maximets.