Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 271129
b: refs/heads/master
c: e5f93a3
h: refs/heads/master
i:
  271127: 198ff0a
v: v3
  • Loading branch information
adam radford authored and James Bottomley committed Oct 16, 2011
1 parent 3136fb5 commit c1632e2
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c8e858fe72230dd2ad07abcbec7c9f201672a8b4
refs/heads/master: e5f93a36f72c9817b989f573f7140e3dfbce0f49
1 change: 1 addition & 0 deletions trunk/drivers/scsi/megaraid/megaraid_sas.h
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@
#define MFI_CMD_ABORT 0x06
#define MFI_CMD_SMP 0x07
#define MFI_CMD_STP 0x08
#define MFI_CMD_INVALID 0xff

#define MR_DCMD_CTRL_GET_INFO 0x01010000
#define MR_DCMD_LD_GET_LIST 0x03010000
Expand Down
19 changes: 18 additions & 1 deletion trunk/drivers/scsi/megaraid/megaraid_sas_base.c
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,10 @@ megasas_return_cmd(struct megasas_instance *instance, struct megasas_cmd *cmd)

cmd->scmd = NULL;
cmd->frame_count = 0;
if ((instance->pdev->device != PCI_DEVICE_ID_LSI_FUSION) &&
(instance->pdev->device != PCI_DEVICE_ID_LSI_INVADER) &&
(reset_devices))
cmd->frame->hdr.cmd = MFI_CMD_INVALID;
list_add_tail(&cmd->list, &instance->cmd_pool);

spin_unlock_irqrestore(&instance->cmd_pool_lock, flags);
Expand Down Expand Up @@ -2165,7 +2169,16 @@ megasas_complete_cmd(struct megasas_instance *instance, struct megasas_cmd *cmd,
cmd->scmd->SCp.ptr = NULL;

switch (hdr->cmd) {

case MFI_CMD_INVALID:
/* Some older 1068 controller FW may keep a pended
MR_DCMD_CTRL_EVENT_GET_INFO left over from the main kernel
when booting the kdump kernel. Ignore this command to
prevent a kernel panic on shutdown of the kdump kernel. */
printk(KERN_WARNING "megaraid_sas: MFI_CMD_INVALID command "
"completed.\n");
printk(KERN_WARNING "megaraid_sas: If you have a controller "
"other than PERC5, please upgrade your firmware.\n");
break;
case MFI_CMD_PD_SCSI_IO:
case MFI_CMD_LD_SCSI_IO:

Expand Down Expand Up @@ -2934,6 +2947,10 @@ static int megasas_create_frame_pool(struct megasas_instance *instance)
memset(cmd->frame, 0, total_sz);
cmd->frame->io.context = cmd->index;
cmd->frame->io.pad_0 = 0;
if ((instance->pdev->device != PCI_DEVICE_ID_LSI_FUSION) &&
(instance->pdev->device != PCI_DEVICE_ID_LSI_INVADER) &&
(reset_devices))
cmd->frame->hdr.cmd = MFI_CMD_INVALID;
}

return 0;
Expand Down

0 comments on commit c1632e2

Please sign in to comment.