summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGanesh Goudar <ganeshgr@chelsio.com>2018-03-07 13:08:45 +0530
committerDavid S. Miller <davem@davemloft.net>2018-03-07 15:32:11 -0500
commit016764de8b0d17e946832d7b6530434daa82df0e (patch)
treeb7e4633dac29d08bc2ad12db710fe042afd13dcb
parentb51f26b14683838825170387457176c1ffaea9f5 (diff)
cxgb4: copy adap index to PF0-3 adapter instances
instantiation of VF's on different adapters fails, copy adapter index and chip type to PF0-3 adapter instances to fix the issue. Signed-off-by: Ganesh Goudar <ganeshgr@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c
index 7b452e85de2a..33bc84185b82 100644
--- a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c
+++ b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c
@@ -5181,6 +5181,8 @@ static int init_one(struct pci_dev *pdev, const struct pci_device_id *ent)
adapter->name = pci_name(pdev);
adapter->mbox = func;
adapter->pf = func;
+ adapter->params.chip = chip;
+ adapter->adap_idx = adap_idx;
adapter->msg_enable = DFLT_MSG_ENABLE;
adapter->mbox_log = kzalloc(sizeof(*adapter->mbox_log) +
(sizeof(struct mbox_cmd) *