[dpdk-dev] bond: initialize backpointer from pci device to driver

Message ID 1431052872-4739-1-git-send-email-stephen@networkplumber.org (mailing list archive)
State Accepted, archived
Headers

Commit Message

Stephen Hemminger May 8, 2015, 2:41 a.m. UTC
  Add missing initialization of to pci_dev driver
The link from pci_dev back to the ethernet driver was not being set.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 lib/librte_pmd_bond/rte_eth_bond_api.c | 1 +
 1 file changed, 1 insertion(+)
  

Comments

Thomas Monjalon June 29, 2015, 10:14 a.m. UTC | #1
2015-05-07 19:41, Stephen Hemminger:
> Add missing initialization of to pci_dev driver
> The link from pci_dev back to the ethernet driver was not being set.
> 
> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>

Applied, thanks
  

Patch

diff --git a/lib/librte_pmd_bond/rte_eth_bond_api.c b/lib/librte_pmd_bond/rte_eth_bond_api.c
index e91a623..904b59f 100644
--- a/lib/librte_pmd_bond/rte_eth_bond_api.c
+++ b/lib/librte_pmd_bond/rte_eth_bond_api.c
@@ -260,6 +260,7 @@  rte_eth_bond_create(const char *name, uint8_t mode, uint8_t socket_id)
 
 	pci_dev->numa_node = socket_id;
 	pci_drv->name = driver_name;
+	pci_dev->driver = pci_drv;
 
 	eth_dev->driver = eth_drv;
 	eth_dev->data->dev_private = internals;