git.droids-corp.org
/
dpdk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
net/bnx2x: serialize access to VF mailbox
[dpdk.git]
/
drivers
/
net
/
bnx2x
/
bnx2x_ethdev.c
diff --git
a/drivers/net/bnx2x/bnx2x_ethdev.c
b/drivers/net/bnx2x/bnx2x_ethdev.c
index
b975e99
..
7375a4e
100644
(file)
--- a/
drivers/net/bnx2x/bnx2x_ethdev.c
+++ b/
drivers/net/bnx2x/bnx2x_ethdev.c
@@
-575,6
+575,8
@@
bnx2x_common_dev_init(struct rte_eth_dev *eth_dev, int is_vf)
eth_dev->data->port_id, pci_dev->id.vendor_id, pci_dev->id.device_id);
if (IS_VF(sc)) {
eth_dev->data->port_id, pci_dev->id.vendor_id, pci_dev->id.device_id);
if (IS_VF(sc)) {
+ rte_spinlock_init(&sc->vf2pf_lock);
+
if (bnx2x_dma_alloc(sc, sizeof(struct bnx2x_vf_mbx_msg),
&sc->vf2pf_mbox_mapping, "vf2pf_mbox",
RTE_CACHE_LINE_SIZE) != 0)
if (bnx2x_dma_alloc(sc, sizeof(struct bnx2x_vf_mbx_msg),
&sc->vf2pf_mbox_mapping, "vf2pf_mbox",
RTE_CACHE_LINE_SIZE) != 0)