scsi: megaraid_sas: Incorrect processing of IOCTL frames for SMP/STP commands
authorShivasharan S <shivasharan.srikanteshwara@broadcom.com>
Thu, 19 Oct 2017 09:49:02 +0000 (02:49 -0700)
committerMartin K. Petersen <martin.petersen@oracle.com>
Wed, 25 Oct 2017 08:55:30 +0000 (04:55 -0400)
commit82add4e1b354f93ca4b986989a94c957cb8b06c5
tree75e33967f803d6b66aa651ae6d713a2decba8da5
parentb9637d14dc00d91cef0068cde1f9a8959b051028
scsi: megaraid_sas: Incorrect processing of IOCTL frames for SMP/STP commands

cmd->frame->dcmd.opcode will be valid only for MFI_CMD_DCMD
IOCTL frames. Currently driver check for cmd->frame->dcmd.opcode without
checking cmd type. Ensure we check dcmd opcode only for MFI_CMD_DCMD
commands. Separate handling of MFI_CMD_SMP/STP commands from
MFI_CMD_DCMD in completion path.

Signed-off-by: Kashyap Desai <kashyap.desai@broadcom.com>
Signed-off-by: Shivasharan S <shivasharan.srikanteshwara@broadcom.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/megaraid/megaraid_sas.h
drivers/scsi/megaraid/megaraid_sas_base.c