[dpdk-dev] [PATCH] ethdev: The users could get device types now

Neil Horman nhorman at tuxdriver.com
Sun Sep 28 14:36:40 CEST 2014


On Sun, Sep 28, 2014 at 11:27:16AM +0800, Ding Heng wrote:
> As different PMDs support different features, application may want
> to know the NIC type of a port, then decide how to use that port.
> Add a new field in struct rte_eth_dev, users are able to get
> device type now.
> 
> Signed-off-by: Ding Heng <hengx.ding at intel.com>
Nack.  This patch embodies PMD specific information in a common library, which
really isn't necessecary.  It implies that developers who maintain PMDs outside
of the core dpdk still need to do some maintenence in the core for all the dpdk
features to work.  Its also a layering violation.   The core shouldn't have to
know any specifics about a driver to initalize it, even its name.

If an application wants to know what type of driver a NIC is,
the application can just interrogate the pci drivers name field directly.

Neil



More information about the dev mailing list