Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 4972
b: refs/heads/master
c: fa4c496
h: refs/heads/master
v: v3
  • Loading branch information
James Bottomley committed Jun 26, 2005
1 parent e62c946 commit d869a47
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 18 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: 849717383abc795b8f5efe7b9e0792b2e1f8916a
refs/heads/master: fa4c49669f0408557bc52cd7054c920a8790dec6
21 changes: 4 additions & 17 deletions trunk/drivers/scsi/megaraid.c
Original file line number Diff line number Diff line change
Expand Up @@ -1938,7 +1938,7 @@ megaraid_abort(Scsi_Cmnd *cmd)


static int
__megaraid_reset(Scsi_Cmnd *cmd)
megaraid_reset(struct scsi_cmnd *cmd)
{
adapter_t *adapter;
megacmd_t mc;
Expand All @@ -1950,42 +1950,29 @@ __megaraid_reset(Scsi_Cmnd *cmd)
mc.cmd = MEGA_CLUSTER_CMD;
mc.opcode = MEGA_RESET_RESERVATIONS;

spin_unlock_irq(&adapter->lock);
if( mega_internal_command(adapter, LOCK_INT, &mc, NULL) != 0 ) {
printk(KERN_WARNING
"megaraid: reservation reset failed.\n");
}
else {
printk(KERN_INFO "megaraid: reservation reset.\n");
}
spin_lock_irq(&adapter->lock);
#endif

spin_lock_irq(&adapter->lock);

rval = megaraid_abort_and_reset(adapter, cmd, SCB_RESET);

/*
* This is required here to complete any completed requests
* to be communicated over to the mid layer.
*/
mega_rundoneq(adapter);

return rval;
}

static int
megaraid_reset(Scsi_Cmnd *cmd)
{
adapter_t *adapter = (adapter_t *)cmd->device->host->hostdata;
int rc;

spin_lock_irq(&adapter->lock);
rc = __megaraid_reset(cmd);
spin_unlock_irq(&adapter->lock);

return rc;
return rval;
}


/**
* megaraid_abort_and_reset()
* @adapter - megaraid soft state
Expand Down

0 comments on commit d869a47

Please sign in to comment.