|
@@ -304,10 +304,8 @@ static void bnx2fc_upload_session(struct fcoe_port *port,
|
|
" not sent to FW\n");
|
|
" not sent to FW\n");
|
|
|
|
|
|
/* Free session resources */
|
|
/* Free session resources */
|
|
- spin_lock_bh(&tgt->cq_lock);
|
|
|
|
bnx2fc_free_session_resc(hba, tgt);
|
|
bnx2fc_free_session_resc(hba, tgt);
|
|
bnx2fc_free_conn_id(hba, tgt->fcoe_conn_id);
|
|
bnx2fc_free_conn_id(hba, tgt->fcoe_conn_id);
|
|
- spin_unlock_bh(&tgt->cq_lock);
|
|
|
|
}
|
|
}
|
|
|
|
|
|
static int bnx2fc_init_tgt(struct bnx2fc_rport *tgt,
|
|
static int bnx2fc_init_tgt(struct bnx2fc_rport *tgt,
|
|
@@ -830,11 +828,13 @@ static void bnx2fc_free_session_resc(struct bnx2fc_hba *hba,
|
|
tgt->rq = NULL;
|
|
tgt->rq = NULL;
|
|
}
|
|
}
|
|
/* Free CQ */
|
|
/* Free CQ */
|
|
|
|
+ spin_lock_bh(&tgt->cq_lock);
|
|
if (tgt->cq) {
|
|
if (tgt->cq) {
|
|
dma_free_coherent(&hba->pcidev->dev, tgt->cq_mem_size,
|
|
dma_free_coherent(&hba->pcidev->dev, tgt->cq_mem_size,
|
|
tgt->cq, tgt->cq_dma);
|
|
tgt->cq, tgt->cq_dma);
|
|
tgt->cq = NULL;
|
|
tgt->cq = NULL;
|
|
}
|
|
}
|
|
|
|
+ spin_unlock_bh(&tgt->cq_lock);
|
|
/* Free SQ */
|
|
/* Free SQ */
|
|
if (tgt->sq) {
|
|
if (tgt->sq) {
|
|
dma_free_coherent(&hba->pcidev->dev, tgt->sq_mem_size,
|
|
dma_free_coherent(&hba->pcidev->dev, tgt->sq_mem_size,
|