瀏覽代碼

Fix Express lane queue creation.

The older sli4 adapters only supported the 64 byte WQE entry size.
The new adapter (fw) support both 64 and 128 byte WQE entry sizies.
The Express lane WQ was not being created with the 128 byte WQE sizes
when it was supported.

Not having the right WQE size created for the express lane work queue
caused the the firmware to overwrite the lun indentifier in the FCP header.

This patch correctly creates the express lane work queue with the
supported size.

Signed-off-by: Dick Kennedy <dick.kennedy@broadcom.com>
Signed-off-by: James Smart <james.smart@broadcom.com>
Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
James Smart 8 年之前
父節點
當前提交
7e04e21afa
共有 1 個文件被更改,包括 5 次插入1 次删除
  1. 5 1
      drivers/scsi/lpfc/lpfc_init.c

+ 5 - 1
drivers/scsi/lpfc/lpfc_init.c

@@ -12040,6 +12040,7 @@ int
 lpfc_fof_queue_create(struct lpfc_hba *phba)
 lpfc_fof_queue_create(struct lpfc_hba *phba)
 {
 {
 	struct lpfc_queue *qdesc;
 	struct lpfc_queue *qdesc;
+	uint32_t wqesize;
 
 
 	/* Create FOF EQ */
 	/* Create FOF EQ */
 	qdesc = lpfc_sli4_queue_alloc(phba, phba->sli4_hba.eq_esize,
 	qdesc = lpfc_sli4_queue_alloc(phba, phba->sli4_hba.eq_esize,
@@ -12060,8 +12061,11 @@ lpfc_fof_queue_create(struct lpfc_hba *phba)
 		phba->sli4_hba.oas_cq = qdesc;
 		phba->sli4_hba.oas_cq = qdesc;
 
 
 		/* Create OAS WQ */
 		/* Create OAS WQ */
-		qdesc = lpfc_sli4_queue_alloc(phba, phba->sli4_hba.wq_esize,
+		wqesize = (phba->fcp_embed_io) ?
+				LPFC_WQE128_SIZE : phba->sli4_hba.wq_esize;
+		qdesc = lpfc_sli4_queue_alloc(phba, wqesize,
 					      phba->sli4_hba.wq_ecount);
 					      phba->sli4_hba.wq_ecount);
+
 		if (!qdesc)
 		if (!qdesc)
 			goto out_error;
 			goto out_error;