Commit 66f49f88 authored by Mustafa Ismail's avatar Mustafa Ismail Committed by Doug Ledford

i40iw: Move exception_lan_queue to VSI structure

Consolidate exception_lan_queue under VSI structure
where it belongs. Remove it from device and QP structures.
Signed-off-by: default avatarMustafa Ismail <mustafa.ismail@intel.com>
Signed-off-by: default avatarShiraz Saleem <shiraz.saleem@intel.com>
Signed-off-by: default avatarDoug Ledford <dledford@redhat.com>
parent de9f0634
...@@ -2406,7 +2406,6 @@ static enum i40iw_status_code i40iw_sc_qp_init(struct i40iw_sc_qp *qp, ...@@ -2406,7 +2406,6 @@ static enum i40iw_status_code i40iw_sc_qp_init(struct i40iw_sc_qp *qp,
qp->rcv_tph_en = info->rcv_tph_en; qp->rcv_tph_en = info->rcv_tph_en;
qp->xmit_tph_en = info->xmit_tph_en; qp->xmit_tph_en = info->xmit_tph_en;
qp->qs_handle = qp->vsi->qos[qp->user_pri].qs_handle; qp->qs_handle = qp->vsi->qos[qp->user_pri].qs_handle;
qp->exception_lan_queue = qp->pd->dev->exception_lan_queue;
return 0; return 0;
} }
...@@ -2741,7 +2740,7 @@ static enum i40iw_status_code i40iw_sc_qp_setctx( ...@@ -2741,7 +2740,7 @@ static enum i40iw_status_code i40iw_sc_qp_setctx(
LS_64(qp->sq_tph_val, I40IWQPC_SQTPHVAL) | LS_64(qp->sq_tph_val, I40IWQPC_SQTPHVAL) |
LS_64(qp->rq_tph_val, I40IWQPC_RQTPHVAL) | LS_64(qp->rq_tph_val, I40IWQPC_RQTPHVAL) |
LS_64(qp->qs_handle, I40IWQPC_QSHANDLE) | LS_64(qp->qs_handle, I40IWQPC_QSHANDLE) |
LS_64(qp->exception_lan_queue, I40IWQPC_EXCEPTION_LAN_QUEUE)); LS_64(vsi->exception_lan_queue, I40IWQPC_EXCEPTION_LAN_QUEUE));
if (info->iwarp_info_valid) { if (info->iwarp_info_valid) {
qw0 |= LS_64(iw->ddp_ver, I40IWQPC_DDP_VER) | qw0 |= LS_64(iw->ddp_ver, I40IWQPC_DDP_VER) |
...@@ -4584,6 +4583,8 @@ void i40iw_sc_vsi_init(struct i40iw_sc_vsi *vsi, struct i40iw_vsi_init_info *inf ...@@ -4584,6 +4583,8 @@ void i40iw_sc_vsi_init(struct i40iw_sc_vsi *vsi, struct i40iw_vsi_init_info *inf
vsi->dev = info->dev; vsi->dev = info->dev;
vsi->back_vsi = info->back_vsi; vsi->back_vsi = info->back_vsi;
vsi->mss = info->params->mss; vsi->mss = info->params->mss;
vsi->exception_lan_queue = info->exception_lan_queue;
i40iw_fill_qos_list(info->params->qs_handle_list); i40iw_fill_qos_list(info->params->qs_handle_list);
for (i = 0; i < I40IW_MAX_USER_PRIORITY; i++) { for (i = 0; i < I40IW_MAX_USER_PRIORITY; i++) {
...@@ -5068,7 +5069,6 @@ enum i40iw_status_code i40iw_device_init(struct i40iw_sc_dev *dev, ...@@ -5068,7 +5069,6 @@ enum i40iw_status_code i40iw_device_init(struct i40iw_sc_dev *dev,
dev->debug_mask = info->debug_mask; dev->debug_mask = info->debug_mask;
dev->hmc_fn_id = info->hmc_fn_id; dev->hmc_fn_id = info->hmc_fn_id;
dev->exception_lan_queue = info->exception_lan_queue;
dev->is_pf = info->is_pf; dev->is_pf = info->is_pf;
dev->fpm_query_buf_pa = info->fpm_query_buf_pa; dev->fpm_query_buf_pa = info->fpm_query_buf_pa;
......
...@@ -958,7 +958,7 @@ static enum i40iw_status_code i40iw_initialize_ieq(struct i40iw_device *iwdev) ...@@ -958,7 +958,7 @@ static enum i40iw_status_code i40iw_initialize_ieq(struct i40iw_device *iwdev)
memset(&info, 0, sizeof(info)); memset(&info, 0, sizeof(info));
info.type = I40IW_PUDA_RSRC_TYPE_IEQ; info.type = I40IW_PUDA_RSRC_TYPE_IEQ;
info.cq_id = 2; info.cq_id = 2;
info.qp_id = iwdev->sc_dev.exception_lan_queue; info.qp_id = iwdev->vsi.exception_lan_queue;
info.count = 1; info.count = 1;
info.pd_id = 2; info.pd_id = 2;
info.sq_size = 8192; info.sq_size = 8192;
...@@ -1338,7 +1338,6 @@ static enum i40iw_status_code i40iw_initialize_dev(struct i40iw_device *iwdev, ...@@ -1338,7 +1338,6 @@ static enum i40iw_status_code i40iw_initialize_dev(struct i40iw_device *iwdev,
iwdev->dcb = true; iwdev->dcb = true;
} }
i40iw_pr_info("DCB is set/clear = %d\n", iwdev->dcb); i40iw_pr_info("DCB is set/clear = %d\n", iwdev->dcb);
info.exception_lan_queue = 1;
info.vchnl_send = i40iw_virtchnl_send; info.vchnl_send = i40iw_virtchnl_send;
status = i40iw_device_init(&iwdev->sc_dev, &info); status = i40iw_device_init(&iwdev->sc_dev, &info);
...@@ -1348,6 +1347,7 @@ static enum i40iw_status_code i40iw_initialize_dev(struct i40iw_device *iwdev, ...@@ -1348,6 +1347,7 @@ static enum i40iw_status_code i40iw_initialize_dev(struct i40iw_device *iwdev,
vsi_info.dev = &iwdev->sc_dev; vsi_info.dev = &iwdev->sc_dev;
vsi_info.back_vsi = (void *)iwdev; vsi_info.back_vsi = (void *)iwdev;
vsi_info.params = &l2params; vsi_info.params = &l2params;
vsi_info.exception_lan_queue = 1;
i40iw_sc_vsi_init(&iwdev->vsi, &vsi_info); i40iw_sc_vsi_init(&iwdev->vsi, &vsi_info);
if (dev->is_pf) { if (dev->is_pf) {
......
...@@ -381,7 +381,6 @@ struct i40iw_sc_qp { ...@@ -381,7 +381,6 @@ struct i40iw_sc_qp {
u8 *q2_buf; u8 *q2_buf;
u64 qp_compl_ctx; u64 qp_compl_ctx;
u16 qs_handle; u16 qs_handle;
u16 exception_lan_queue;
u16 push_idx; u16 push_idx;
u8 sq_tph_val; u8 sq_tph_val;
u8 rq_tph_val; u8 rq_tph_val;
...@@ -460,6 +459,7 @@ struct i40iw_sc_vsi { ...@@ -460,6 +459,7 @@ struct i40iw_sc_vsi {
u32 ieq_count; u32 ieq_count;
struct i40iw_virt_mem ieq_mem; struct i40iw_virt_mem ieq_mem;
struct i40iw_puda_rsrc *ieq; struct i40iw_puda_rsrc *ieq;
u16 exception_lan_queue;
u16 mss; u16 mss;
u8 fcn_id; u8 fcn_id;
bool stats_fcn_id_alloc; bool stats_fcn_id_alloc;
...@@ -502,7 +502,6 @@ struct i40iw_sc_dev { ...@@ -502,7 +502,6 @@ struct i40iw_sc_dev {
struct i40iw_hmc_fpm_misc hmc_fpm_misc; struct i40iw_hmc_fpm_misc hmc_fpm_misc;
u32 debug_mask; u32 debug_mask;
u16 exception_lan_queue;
u8 hmc_fn_id; u8 hmc_fn_id;
bool is_pf; bool is_pf;
bool vchnl_up; bool vchnl_up;
...@@ -574,6 +573,7 @@ struct i40iw_vsi_init_info { ...@@ -574,6 +573,7 @@ struct i40iw_vsi_init_info {
struct i40iw_sc_dev *dev; struct i40iw_sc_dev *dev;
void *back_vsi; void *back_vsi;
struct i40iw_l2params *params; struct i40iw_l2params *params;
u16 exception_lan_queue;
}; };
struct i40iw_vsi_stats_info { struct i40iw_vsi_stats_info {
...@@ -591,7 +591,6 @@ struct i40iw_device_init_info { ...@@ -591,7 +591,6 @@ struct i40iw_device_init_info {
struct i40iw_hw *hw; struct i40iw_hw *hw;
void __iomem *bar0; void __iomem *bar0;
enum i40iw_status_code (*vchnl_send)(struct i40iw_sc_dev *, u32, u8 *, u16); enum i40iw_status_code (*vchnl_send)(struct i40iw_sc_dev *, u32, u8 *, u16);
u16 exception_lan_queue;
u8 hmc_fn_id; u8 hmc_fn_id;
bool is_pf; bool is_pf;
u32 debug_mask; u32 debug_mask;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment