Commit 117d2ce1 authored by Brian King's avatar Brian King Committed by James Bottomley

[SCSI] ipr: Auto sense handling fix

Fix up a logic error in the checking for valid sense data.
Signed-off-by: default avatarBrian King <brking@us.ibm.com>
Signed-off-by: default avatarJames Bottomley <James.Bottomley@SteelEye.com>
parent 5b7304fb
...@@ -4127,8 +4127,7 @@ static int ipr_get_autosense(struct ipr_cmnd *ipr_cmd) ...@@ -4127,8 +4127,7 @@ static int ipr_get_autosense(struct ipr_cmnd *ipr_cmd)
{ {
struct ipr_ioasa *ioasa = &ipr_cmd->ioasa; struct ipr_ioasa *ioasa = &ipr_cmd->ioasa;
if ((be32_to_cpu(ioasa->ioasc_specific) & if ((be32_to_cpu(ioasa->ioasc_specific) & IPR_AUTOSENSE_VALID) == 0)
(IPR_ADDITIONAL_STATUS_FMT | IPR_AUTOSENSE_VALID)) == 0)
return 0; return 0;
memcpy(ipr_cmd->scsi_cmd->sense_buffer, ioasa->auto_sense.data, memcpy(ipr_cmd->scsi_cmd->sense_buffer, ioasa->auto_sense.data,
......
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