Commit f42e81e1 authored by Stephen Cameron's avatar Stephen Cameron Committed by James Bottomley

hpsa: print CDBs instead of kernel virtual addresses for uncommon errors

Printing the address of the command pointer is of little value, change
to print the CDB.
Reviewed-by: default avatarScott Teel <scott.teel@pmcs.com>
Signed-off-by: default avatarDon Brace <don.brace@pmcs.com>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
parent 7fa3030c
...@@ -1882,9 +1882,8 @@ static void complete_scsi_command(struct CommandList *cp) ...@@ -1882,9 +1882,8 @@ static void complete_scsi_command(struct CommandList *cp)
case CMD_DATA_UNDERRUN: /* let mid layer handle it. */ case CMD_DATA_UNDERRUN: /* let mid layer handle it. */
break; break;
case CMD_DATA_OVERRUN: case CMD_DATA_OVERRUN:
dev_warn(&h->pdev->dev, "cp %p has" dev_warn(&h->pdev->dev,
" completed with data overrun " "CDB %16phN data overrun\n", cp->Request.CDB);
"reported\n", cp);
break; break;
case CMD_INVALID: { case CMD_INVALID: {
/* print_bytes(cp, sizeof(*cp), 1, 0); /* print_bytes(cp, sizeof(*cp), 1, 0);
...@@ -1900,34 +1899,38 @@ static void complete_scsi_command(struct CommandList *cp) ...@@ -1900,34 +1899,38 @@ static void complete_scsi_command(struct CommandList *cp)
break; break;
case CMD_PROTOCOL_ERR: case CMD_PROTOCOL_ERR:
cmd->result = DID_ERROR << 16; cmd->result = DID_ERROR << 16;
dev_warn(&h->pdev->dev, "cp %p has " dev_warn(&h->pdev->dev, "CDB %16phN : protocol error\n",
"protocol error\n", cp); cp->Request.CDB);
break; break;
case CMD_HARDWARE_ERR: case CMD_HARDWARE_ERR:
cmd->result = DID_ERROR << 16; cmd->result = DID_ERROR << 16;
dev_warn(&h->pdev->dev, "cp %p had hardware error\n", cp); dev_warn(&h->pdev->dev, "CDB %16phN : hardware error\n",
cp->Request.CDB);
break; break;
case CMD_CONNECTION_LOST: case CMD_CONNECTION_LOST:
cmd->result = DID_ERROR << 16; cmd->result = DID_ERROR << 16;
dev_warn(&h->pdev->dev, "cp %p had connection lost\n", cp); dev_warn(&h->pdev->dev, "CDB %16phN : connection lost\n",
cp->Request.CDB);
break; break;
case CMD_ABORTED: case CMD_ABORTED:
cmd->result = DID_ABORT << 16; cmd->result = DID_ABORT << 16;
dev_warn(&h->pdev->dev, "cp %p was aborted with status 0x%x\n", dev_warn(&h->pdev->dev, "CDB %16phN was aborted with status 0x%x\n",
cp, ei->ScsiStatus); cp->Request.CDB, ei->ScsiStatus);
break; break;
case CMD_ABORT_FAILED: case CMD_ABORT_FAILED:
cmd->result = DID_ERROR << 16; cmd->result = DID_ERROR << 16;
dev_warn(&h->pdev->dev, "cp %p reports abort failed\n", cp); dev_warn(&h->pdev->dev, "CDB %16phN : abort failed\n",
cp->Request.CDB);
break; break;
case CMD_UNSOLICITED_ABORT: case CMD_UNSOLICITED_ABORT:
cmd->result = DID_SOFT_ERROR << 16; /* retry the command */ cmd->result = DID_SOFT_ERROR << 16; /* retry the command */
dev_warn(&h->pdev->dev, "cp %p aborted due to an unsolicited " dev_warn(&h->pdev->dev, "CDB %16phN : unsolicited abort\n",
"abort\n", cp); cp->Request.CDB);
break; break;
case CMD_TIMEOUT: case CMD_TIMEOUT:
cmd->result = DID_TIME_OUT << 16; cmd->result = DID_TIME_OUT << 16;
dev_warn(&h->pdev->dev, "cp %p timedout\n", cp); dev_warn(&h->pdev->dev, "CDB %16phN timed out\n",
cp->Request.CDB);
break; break;
case CMD_UNABORTABLE: case CMD_UNABORTABLE:
cmd->result = DID_ERROR << 16; cmd->result = DID_ERROR << 16;
......
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