summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_init.c
diff options
context:
space:
mode:
authorHimanshu Madhani <himanshu.madhani@qlogic.com>2013-11-04 13:31:32 -0500
committerDavid S. Miller <davem@davemloft.net>2013-11-04 15:33:19 -0500
commit18afc102fdcb95d6c7d57f2967a06f2f8fe3ba4c (patch)
treee7e493fb94fc80fb3ebde4adc5586d9b57625a42 /drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_init.c
parent34e8c406fda5b5a9d2e126a92bab84cd28e3b5fa (diff)
downloadblackbird-obmc-linux-18afc102fdcb95d6c7d57f2967a06f2f8fe3ba4c.tar.gz
blackbird-obmc-linux-18afc102fdcb95d6c7d57f2967a06f2f8fe3ba4c.zip
qlcnic: Enable multiple Tx queue support for 83xx/84xx Series adapters.
o 83xx and 84xx firmware is capable of multiple Tx queues. This patch will enable multiple Tx queues for 83xx/84xx series adapters. Max number of Tx queues supported will be 8. Signed-off-by: Himanshu Madhani <himanshu.madhani@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_init.c')
-rw-r--r--drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_init.c18
1 files changed, 11 insertions, 7 deletions
diff --git a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_init.c b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_init.c
index 5682a40eb8a7..89208e5b25d6 100644
--- a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_init.c
+++ b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_83xx_init.c
@@ -2068,13 +2068,13 @@ int qlcnic_83xx_configure_opmode(struct qlcnic_adapter *adapter)
return -EIO;
adapter->max_sds_rings = QLCNIC_MAX_VNIC_SDS_RINGS;
- adapter->max_tx_rings = QLCNIC_SINGLE_RING;
+ adapter->max_tx_rings = QLCNIC_MAX_VNIC_TX_RINGS;
} else if (ret == QLC_83XX_DEFAULT_OPMODE) {
ahw->nic_mode = QLCNIC_DEFAULT_MODE;
adapter->nic_ops->init_driver = qlcnic_83xx_init_default_driver;
ahw->idc.state_entry = qlcnic_83xx_idc_ready_state_entry;
adapter->max_sds_rings = ahw->max_rx_ques;
- adapter->max_tx_rings = QLCNIC_SINGLE_RING;
+ adapter->max_tx_rings = ahw->max_tx_ques;
} else {
return -EIO;
}
@@ -2179,16 +2179,20 @@ static int qlcnic_83xx_get_fw_info(struct qlcnic_adapter *adapter)
static void qlcnic_83xx_init_rings(struct qlcnic_adapter *adapter)
{
+ u8 rx_cnt = QLCNIC_DEF_SDS_RINGS;
+ u8 tx_cnt = QLCNIC_DEF_TX_RINGS;
+
adapter->max_tx_rings = QLCNIC_MAX_TX_RINGS;
adapter->max_sds_rings = QLCNIC_MAX_SDS_RINGS;
- qlcnic_set_tx_ring_count(adapter, QLCNIC_SINGLE_RING);
+ if (!adapter->ahw->msix_supported) {
+ rx_cnt = QLCNIC_SINGLE_RING;
+ tx_cnt = QLCNIC_SINGLE_RING;
+ }
/* compute and set drv sds rings */
- if (adapter->ahw->msix_supported)
- qlcnic_set_sds_ring_count(adapter, QLCNIC_DEF_SDS_RINGS);
- else
- qlcnic_set_sds_ring_count(adapter, QLCNIC_SINGLE_RING);
+ qlcnic_set_tx_ring_count(adapter, tx_cnt);
+ qlcnic_set_sds_ring_count(adapter, rx_cnt);
}
int qlcnic_83xx_init(struct qlcnic_adapter *adapter, int pci_using_dac)
OpenPOWER on IntegriCloud