Commit 16cc2ba7 authored by Muhammad Usama Anjum's avatar Muhammad Usama Anjum Committed by Martin K. Petersen

scsi: lpfc: Correct size for cmdwqe/rspwqe for memset()

The cmdwqe and rspwqe are of type lpfc_wqe128. They should be memset() with
the same type.

Fixes: 61910d6a ("scsi: lpfc: SLI path split: Refactor CT paths")
Signed-off-by: default avatarMuhammad Usama Anjum <usama.anjum@collabora.com>
Link: https://lore.kernel.org/r/20240304091119.847060-1-usama.anjum@collabora.comReviewed-by: default avatarJustin Tee <justin.tee@broadcom.com>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent 28d41991
...@@ -3169,10 +3169,10 @@ lpfc_bsg_diag_loopback_run(struct bsg_job *job) ...@@ -3169,10 +3169,10 @@ lpfc_bsg_diag_loopback_run(struct bsg_job *job)
} }
cmdwqe = &cmdiocbq->wqe; cmdwqe = &cmdiocbq->wqe;
memset(cmdwqe, 0, sizeof(union lpfc_wqe)); memset(cmdwqe, 0, sizeof(*cmdwqe));
if (phba->sli_rev < LPFC_SLI_REV4) { if (phba->sli_rev < LPFC_SLI_REV4) {
rspwqe = &rspiocbq->wqe; rspwqe = &rspiocbq->wqe;
memset(rspwqe, 0, sizeof(union lpfc_wqe)); memset(rspwqe, 0, sizeof(*rspwqe));
} }
INIT_LIST_HEAD(&head); INIT_LIST_HEAD(&head);
......
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