[dpdk-dev] [PATCH] eal: postpone vdev initialization

2016-11-20 Thread David Marchand
On Sun, Nov 20, 2016 at 9:00 AM, Jerin Jacob wrote: > Some platform like octeontx may use pci and > vdev based combined device to represent a logical > dpdk functional device.In such case, postponing the > vdev initialization after pci device > initialization will provide the better view of > the

[dpdk-dev] [RFC PATCH 0/6] Restructure EAL device model for bus support

2016-11-20 Thread David Marchand
On Thu, Nov 17, 2016 at 6:29 AM, Shreyansh Jain wrote: > DPDK has been inherently a PCI inclined framework. Because of this, the > design of device tree (or list) within DPDK is also PCI inclined. A non-PCI > device doesn't have a way of being expressed without using hooks started from > EAL to

[dpdk-dev] [PATCH 7/7] ethdev: Move filling of rte_eth_dev_info->pci_dev to dev_infos_get()

2016-11-20 Thread David Marchand
On Sun, Nov 20, 2016 at 11:05 AM, Jan Blunck wrote: > Only the device itself can decide its PCI or not. > > Signed-off-by: Jan Blunck > --- > drivers/net/bnx2x/bnx2x_ethdev.c| 1 + > drivers/net/bnxt/bnxt_ethdev.c | 2 ++ > drivers/net/cxgbe/cxgbe_ethdev.c| 2 ++ >

[dpdk-dev] [PATCH 2/7] eal: Helper to convert to struct rte_pci_device

2016-11-20 Thread David Marchand
Hello Jan, On Sun, Nov 20, 2016 at 11:05 AM, Jan Blunck wrote: > Signed-off-by: Jan Blunck > --- > lib/librte_eal/common/include/rte_pci.h | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/lib/librte_eal/common/include/rte_pci.h > b/lib/librte_eal/common/include/rte_pci.h > index

[dpdk-dev] [PATCH] eal: postpone vdev initialization

2016-11-20 Thread Jerin Jacob
Some platform like octeontx may use pci and vdev based combined device to represent a logical dpdk functional device.In such case, postponing the vdev initialization after pci device initialization will provide the better view of the pci device resources in the system in vdev's probe function, and

[dpdk-dev] [PATCH 7/7] ethdev: Move filling of rte_eth_dev_info->pci_dev to dev_infos_get()

2016-11-20 Thread Jan Blunck
Only the device itself can decide its PCI or not. Signed-off-by: Jan Blunck --- drivers/net/bnx2x/bnx2x_ethdev.c| 1 + drivers/net/bnxt/bnxt_ethdev.c | 2 ++ drivers/net/cxgbe/cxgbe_ethdev.c| 2 ++ drivers/net/e1000/em_ethdev.c | 1 +

[dpdk-dev] [PATCH 5/7] virtio: Add vtpci_intr_handle() helper to get rte_intr_handle

2016-11-20 Thread Jan Blunck
This adds a helper to get the rte_intr_handle from the virtio_hw. This is safe to do since the usage of the helper is guarded by RTE_ETH_DEV_INTR_LSC which is only set if we found a PCI device during initialization. Signed-off-by: Jan Blunck --- drivers/net/virtio/virtio_ethdev.c | 12

[dpdk-dev] [PATCH 4/7] virtio: Don't fill dev_info->driver_name

2016-11-20 Thread Jan Blunck
This is overwritten in rte_eth_dev_info_get(). Signed-off-by: Jan Blunck --- drivers/net/virtio/virtio_ethdev.c | 4 1 file changed, 4 deletions(-) diff --git a/drivers/net/virtio/virtio_ethdev.c b/drivers/net/virtio/virtio_ethdev.c index 079fd6c..741688e 100644 ---

[dpdk-dev] [PATCH 3/7] drivers: Use ETH_DEV_PCI_DEV() helper

2016-11-20 Thread Jan Blunck
The drivers should not directly access the rte_eth_dev->pci_dev but use a macro instead. This is a preparation for replacing the pci_dev with a struct rte_device member in the future. Signed-off-by: Jan Blunck --- drivers/net/bnxt/bnxt_ethdev.c | 19 ++-

[dpdk-dev] [PATCH 2/7] eal: Helper to convert to struct rte_pci_device

2016-11-20 Thread Jan Blunck
Signed-off-by: Jan Blunck --- lib/librte_eal/common/include/rte_pci.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/librte_eal/common/include/rte_pci.h b/lib/librte_eal/common/include/rte_pci.h index 9ce8847..0376160 100644 --- a/lib/librte_eal/common/include/rte_pci.h +++