Patch "qed: Read queue state before releasing buffer" has been added to the 4.9-stable tree
Subsystems (3)
This is a note to let you know that I've just added the patch titled
qed: Read queue state before releasing buffer
to the 4.9-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
qed-read-queue-state-before-releasing-buffer.patch
and it can be found in the queue-4.9 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.
Quoted 1 line
From foo@baz Thu Oct 19 15:04:02 CEST 2017
From: Ram Amrani <[email protected]>
Date: Mon, 20 Feb 2017 22:43:31 +0200
Subject: qed: Read queue state before releasing buffer
From: Ram Amrani <[email protected]>
[ Upstream commit c5212b943d4b52a7d9e0d9f747e7ad59c50d31f1 ]
Currently the state is read only after the buffers are relesed.
--- drivers/net/ethernet/qlogic/qed/qed_roce.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-)
drivers/net/ethernet/qlogic/qed/qed_roce.c +6 -6
@@ -1766,13 +1766,13 @@ static int qed_roce_query_qp(struct qed_if (rc) goto err_resp; -dma_free_coherent (&p_hwfn->cdev->pdev->dev,sizeof (*p_resp_ramrod_res), - p_resp_ramrod_res, resp_ramrod_res_phys); - out_params->rq_psn =le32_to_cpu (p_resp_ramrod_res->psn); rq_err_state =GET_FIELD (le32_to_cpu (p_resp_ramrod_res->err_flag),ROCE_QUERY_QP_RESP_OUTPUT_PARAMS_ERROR_FLG ); +dma_free_coherent (&p_hwfn->cdev->pdev->dev,sizeof (*p_resp_ramrod_res), + p_resp_ramrod_res, resp_ramrod_res_phys); +if (!(qp->req_offloaded)) {/* Don't send query qp for the requester */ out_params->sq_psn = qp->sq_psn;
@@ -1813,9 +1813,6 @@ static int qed_roce_query_qp(struct qed_if (rc) goto err_req; -dma_free_coherent (&p_hwfn->cdev->pdev->dev,sizeof (*p_req_ramrod_res), - p_req_ramrod_res, req_ramrod_res_phys); - out_params->sq_psn =le32_to_cpu (p_req_ramrod_res->psn); sq_err_state =GET_FIELD (le32_to_cpu (p_req_ramrod_res->flags),ROCE_QUERY_QP_REQ_OUTPUT_PARAMS_ERR_FLG );
@@ -1823,6 +1820,9 @@ static int qed_roce_query_qp(struct qed_GET_FIELD (le32_to_cpu (p_req_ramrod_res->flags),ROCE_QUERY_QP_REQ_OUTPUT_PARAMS_SQ_DRAINING_FLG ); +dma_free_coherent (&p_hwfn->cdev->pdev->dev,sizeof (*p_req_ramrod_res), + p_req_ramrod_res, req_ramrod_res_phys); + out_params->draining = false;if (rq_err_state)
Patches currently in stable-queue which might be from [email protected] are
queue-4.9/qed-reserve-doorbell-bar-space-for-present-cpus.patch queue-4.9/qed-read-queue-state-before-releasing-buffer.patch