scsi: ibmvfc: Deduplicate common ibmvfc_cmd init code
authorTyrel Datwyler <tyreld@linux.ibm.com>
Wed, 18 Nov 2020 01:10:59 +0000 (19:10 -0600)
committerMartin K. Petersen <martin.petersen@oracle.com>
Fri, 20 Nov 2020 03:09:10 +0000 (22:09 -0500)
commitfad74a1be2dbeae02d71e072418eeb307ce46103
tree5ae2a9b321218d8152f0911ba652fe260a49e827
parent2aa0102c6688306548d81a958a6293936904ca75
scsi: ibmvfc: Deduplicate common ibmvfc_cmd init code

The virtual FC frame command exchanged with the VIOS is used for device
reset and command abort TMF as well as normally queued commands. When
initializing the ibmvfc_cmd there are several elements of the command that
are set the same way regardless of the command type.

Deduplicate code by moving these commonally set fields into a
initialization helper routine, namely ibmvfc_init_vfc_cmd().

Link: https://lore.kernel.org/r/20201118011104.296999-2-tyreld@linux.ibm.com
Acked-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: Tyrel Datwyler <tyreld@linux.ibm.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/ibmvscsi/ibmvfc.c