[dpdk-dev] [PATCH v10 13/14] eal/pci: Add rte_eal_dev_attach/detach() functions

Maxime Leroy maxime.leroy at 6wind.com
Fri Feb 20 16:20:59 CET 2015


Hi Tetsuya,

Thanks for your comment.

On Fri, Feb 20, 2015 at 11:32 AM, Tetsuya Mukawa <mukawa at igel.co.jp> wrote:
> On 2015/02/20 19:14, Maxime Leroy wrote:
>> Hi Tetsuya,
[...]
>>
>
> Hi Maxime,
>
> I appreciate for your comment.
>
> When rte_eal_init() is called, if we have "--vdev" options, these will
> be stored in vdevargs as you describe above.
> I agree this is the current behavior of DPDK.
>
> When we call hotplug functions, I guess doing same thing will be more
> consistent design.

The rte_eal_devargs_add is here to store a white list parameters for
later creating the devices.
It means that the devargs_list is only needed at the init to store the
devargs parsed .
I think we should not use the devargs_list after eal initialization.

Why you want to add devargs in the devargs_list, if there are no needs
to store this information ?

At the end, it adds extra codes for nothing.

>
> For example, we can do like below.
> 1. $ ./testpmd --vdev 'eth_pcap' -- -i
> 2. testpmd>port detach

It's exactly the same for physical device:
1. $./testpmd -w 0000:08:00:1 -- -i
2. testpmd> port detach

But you don't call rte_eal_devargs_add with RTE_DEVTYPE_WHILISTED_PCI
in  rte_eal_dev_attach_pdev ?
Thus it makes the hotplug implementation not coherent for me.

What do you think ?

Regards,

Maxime


More information about the dev mailing list