Re: [dpdk-dev] [PATCH v6 4/6] ethdev: adjust APIs removal error report

2018-01-21 Thread Ferruh Yigit
On 1/19/2018 4:19 PM, Ferruh Yigit wrote: > On 1/18/2018 6:10 PM, Matan Azrad wrote: >> Hi Ferruh >> >> From: Ferruh Yigit, Thursday, January 18, 2018 7:31 PM >>> On 1/18/2018 11:27 AM, Matan Azrad wrote: rte_eth_dev_is_removed API was added to detect a device removal synchronously.

Re: [dpdk-dev] [PATCH v6 4/6] ethdev: adjust APIs removal error report

2018-01-20 Thread Matan Azrad
Hi Thomas From: Thomas Monjalon, Saturday, January 20, 2018 10:29 PM > 20/01/2018 20:04, Matan Azrad: > > Konstantin wrote in another thread: > > >+ RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, 0); > > >+ > > >+ dev = &rte_eth_devices[port_id]; > > >+ > > >+ RTE_FUNC_PTR_OR_ERR_RET(*dev->dev_ops->is

Re: [dpdk-dev] [PATCH v6 4/6] ethdev: adjust APIs removal error report

2018-01-20 Thread Thomas Monjalon
20/01/2018 20:04, Matan Azrad: > Konstantin wrote in another thread: > >+RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, 0); > >+ > >+dev = &rte_eth_devices[port_id]; > >+ > >+RTE_FUNC_PTR_OR_ERR_RET(*dev->dev_ops->is_removed, 0); > > > I'd says these 2 checks have to be swapped. > > Konstan

Re: [dpdk-dev] [PATCH v6 4/6] ethdev: adjust APIs removal error report

2018-01-20 Thread Matan Azrad
Hi all From: Thomas Monjalon, Friday, January 19, 2018 8:17 PM > 19/01/2018 19:13, Ferruh Yigit: > > On 1/19/2018 5:54 PM, Thomas Monjalon wrote: > > > 19/01/2018 17:19, Ferruh Yigit: > > >> On 1/18/2018 6:10 PM, Matan Azrad wrote: > > >>> From: Ferruh Yigit, Thursday, January 18, 2018 7:31 PM > >

Re: [dpdk-dev] [PATCH v6 4/6] ethdev: adjust APIs removal error report

2018-01-19 Thread Thomas Monjalon
19/01/2018 19:13, Ferruh Yigit: > On 1/19/2018 5:54 PM, Thomas Monjalon wrote: > > 19/01/2018 17:19, Ferruh Yigit: > >> On 1/18/2018 6:10 PM, Matan Azrad wrote: > >>> From: Ferruh Yigit, Thursday, January 18, 2018 7:31 PM > This patch updates *all* ethdev public APIs to add if device is remove

Re: [dpdk-dev] [PATCH v6 4/6] ethdev: adjust APIs removal error report

2018-01-19 Thread Ferruh Yigit
On 1/19/2018 5:54 PM, Thomas Monjalon wrote: > 19/01/2018 17:19, Ferruh Yigit: >> On 1/18/2018 6:10 PM, Matan Azrad wrote: >>> From: Ferruh Yigit, Thursday, January 18, 2018 7:31 PM This patch updates *all* ethdev public APIs to add if device is removed check? >>> >>> Yes. >>> And ea

Re: [dpdk-dev] [PATCH v6 4/6] ethdev: adjust APIs removal error report

2018-01-19 Thread Thomas Monjalon
19/01/2018 17:19, Ferruh Yigit: > On 1/18/2018 6:10 PM, Matan Azrad wrote: > > From: Ferruh Yigit, Thursday, January 18, 2018 7:31 PM > >> This patch updates *all* ethdev public APIs to add if device is removed > >> check? > > > > Yes. > > > >> And each check goes to ethdev is_removed() dev_ops t

Re: [dpdk-dev] [PATCH v6 4/6] ethdev: adjust APIs removal error report

2018-01-19 Thread Ananyev, Konstantin
> -Original Message- > From: Yigit, Ferruh > Sent: Friday, January 19, 2018 4:19 PM > To: Matan Azrad ; Adrien Mazarguil > ; Gaetan Rivet > Cc: Thomas Monjalon ; dev@dpdk.org; Andrew Rybchenko > ; Ananyev, Konstantin > ; Alejandro Lucero > ; Jerin Jacob > ; Hemant Agrawal ; > Shahaf

Re: [dpdk-dev] [PATCH v6 4/6] ethdev: adjust APIs removal error report

2018-01-19 Thread Ferruh Yigit
On 1/18/2018 6:10 PM, Matan Azrad wrote: > Hi Ferruh > > From: Ferruh Yigit, Thursday, January 18, 2018 7:31 PM >> On 1/18/2018 11:27 AM, Matan Azrad wrote: >>> rte_eth_dev_is_removed API was added to detect a device removal >>> synchronously. >>> >>> When a device removal occurs during control co

Re: [dpdk-dev] [PATCH v6 4/6] ethdev: adjust APIs removal error report

2018-01-18 Thread Matan Azrad
Hi Ferruh From: Ferruh Yigit, Thursday, January 18, 2018 7:31 PM > On 1/18/2018 11:27 AM, Matan Azrad wrote: > > rte_eth_dev_is_removed API was added to detect a device removal > > synchronously. > > > > When a device removal occurs during control command execution, many > > different errors can b

Re: [dpdk-dev] [PATCH v6 4/6] ethdev: adjust APIs removal error report

2018-01-18 Thread Ferruh Yigit
On 1/18/2018 11:27 AM, Matan Azrad wrote: > rte_eth_dev_is_removed API was added to detect a device removal > synchronously. > > When a device removal occurs during control command execution, many > different errors can be reported to the user. > > Adjust all ethdev APIs error reports to return -

[dpdk-dev] [PATCH v6 4/6] ethdev: adjust APIs removal error report

2018-01-18 Thread Matan Azrad
rte_eth_dev_is_removed API was added to detect a device removal synchronously. When a device removal occurs during control command execution, many different errors can be reported to the user. Adjust all ethdev APIs error reports to return -EIO in case of device removal using rte_eth_dev_is_remov