From 2dfd074e6c995655ef003a2196f2988161043cfa Mon Sep 17 00:00:00 2001 From: Rasesh Mody Date: Wed, 29 Mar 2017 13:36:13 -0700 Subject: [PATCH] net/qede/base: change queue/sb-id from 8 bit to 16 bit Change the queue/sb-id values from 8 bit fields to 16 bit fields. Signed-off-by: Rasesh Mody --- drivers/net/qede/base/ecore_dev.c | 8 ++++---- drivers/net/qede/base/ecore_dev_api.h | 4 ++-- drivers/net/qede/base/ecore_l2.c | 2 +- drivers/net/qede/base/ecore_l2_api.h | 2 +- drivers/net/qede/base/ecore_sriov.c | 4 ++-- 5 files changed, 10 insertions(+), 10 deletions(-) diff --git a/drivers/net/qede/base/ecore_dev.c b/drivers/net/qede/base/ecore_dev.c index 87c1c23f9a..7a501bb2ee 100644 --- a/drivers/net/qede/base/ecore_dev.c +++ b/drivers/net/qede/base/ecore_dev.c @@ -3876,7 +3876,7 @@ static enum _ecore_status_t ecore_set_coalesce(struct ecore_hwfn *p_hwfn, enum _ecore_status_t ecore_set_rxq_coalesce(struct ecore_hwfn *p_hwfn, struct ecore_ptt *p_ptt, - u16 coalesce, u8 qid, u16 sb_id) + u16 coalesce, u16 qid, u16 sb_id) { struct ustorm_eth_queue_zone eth_qzone; u8 timeset, timer_res; @@ -3897,7 +3897,7 @@ enum _ecore_status_t ecore_set_rxq_coalesce(struct ecore_hwfn *p_hwfn, } timeset = (u8)(coalesce >> timer_res); - rc = ecore_fw_l2_queue(p_hwfn, (u16)qid, &fw_qid); + rc = ecore_fw_l2_queue(p_hwfn, qid, &fw_qid); if (rc != ECORE_SUCCESS) return rc; @@ -3919,7 +3919,7 @@ enum _ecore_status_t ecore_set_rxq_coalesce(struct ecore_hwfn *p_hwfn, enum _ecore_status_t ecore_set_txq_coalesce(struct ecore_hwfn *p_hwfn, struct ecore_ptt *p_ptt, - u16 coalesce, u8 qid, u16 sb_id) + u16 coalesce, u16 qid, u16 sb_id) { struct xstorm_eth_queue_zone eth_qzone; u8 timeset, timer_res; @@ -3941,7 +3941,7 @@ enum _ecore_status_t ecore_set_txq_coalesce(struct ecore_hwfn *p_hwfn, timeset = (u8)(coalesce >> timer_res); - rc = ecore_fw_l2_queue(p_hwfn, (u16)qid, &fw_qid); + rc = ecore_fw_l2_queue(p_hwfn, qid, &fw_qid); if (rc != ECORE_SUCCESS) return rc; diff --git a/drivers/net/qede/base/ecore_dev_api.h b/drivers/net/qede/base/ecore_dev_api.h index 0dee68a9b2..e7332ace30 100644 --- a/drivers/net/qede/base/ecore_dev_api.h +++ b/drivers/net/qede/base/ecore_dev_api.h @@ -535,7 +535,7 @@ enum _ecore_status_t ecore_final_cleanup(struct ecore_hwfn *p_hwfn, */ enum _ecore_status_t ecore_set_rxq_coalesce(struct ecore_hwfn *p_hwfn, struct ecore_ptt *p_ptt, - u16 coalesce, u8 qid, u16 sb_id); + u16 coalesce, u16 qid, u16 sb_id); /** * @brief ecore_set_txq_coalesce - Configure coalesce parameters for a Tx queue @@ -553,6 +553,6 @@ enum _ecore_status_t ecore_set_rxq_coalesce(struct ecore_hwfn *p_hwfn, */ enum _ecore_status_t ecore_set_txq_coalesce(struct ecore_hwfn *p_hwfn, struct ecore_ptt *p_ptt, - u16 coalesce, u8 qid, u16 sb_id); + u16 coalesce, u16 qid, u16 sb_id); #endif diff --git a/drivers/net/qede/base/ecore_l2.c b/drivers/net/qede/base/ecore_l2.c index 22bb43d65f..1379a1b836 100644 --- a/drivers/net/qede/base/ecore_l2.c +++ b/drivers/net/qede/base/ecore_l2.c @@ -212,7 +212,7 @@ ecore_sp_vport_update_rss(struct ecore_hwfn *p_hwfn, for (i = 0; i < ECORE_RSS_IND_TABLE_SIZE; i++) { rc = ecore_fw_l2_queue(p_hwfn, - (u8)p_rss->rss_ind_table[i], + p_rss->rss_ind_table[i], &abs_l2_queue); if (rc != ECORE_SUCCESS) return rc; diff --git a/drivers/net/qede/base/ecore_l2_api.h b/drivers/net/qede/base/ecore_l2_api.h index 247316b8fd..8f7b6140ca 100644 --- a/drivers/net/qede/base/ecore_l2_api.h +++ b/drivers/net/qede/base/ecore_l2_api.h @@ -37,7 +37,7 @@ struct ecore_queue_start_common_params { /* q_zone_id is relative, may be different from queue id * currently used by Tx-only, upper-bounded by number of FW-queues */ - u8 qzone_id; + u16 qzone_id; /* stats_id is relative or absolute depends on function */ u8 stats_id; diff --git a/drivers/net/qede/base/ecore_sriov.c b/drivers/net/qede/base/ecore_sriov.c index b051678284..6e86966f35 100644 --- a/drivers/net/qede/base/ecore_sriov.c +++ b/drivers/net/qede/base/ecore_sriov.c @@ -2118,8 +2118,8 @@ static void ecore_iov_vf_mbx_start_txq(struct ecore_hwfn *p_hwfn, !ecore_iov_validate_sb(p_hwfn, vf, req->hw_sb)) goto out; - params.queue_id = (u8)vf->vf_queues[req->tx_qid].fw_tx_qid; - params.qzone_id = (u8)vf->vf_queues[req->tx_qid].fw_tx_qid; + params.queue_id = vf->vf_queues[req->tx_qid].fw_tx_qid; + params.qzone_id = vf->vf_queues[req->tx_qid].fw_tx_qid; params.vport_id = vf->vport_id; params.stats_id = vf->abs_vf_id + 0x10; params.sb = req->hw_sb; -- 2.20.1