Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 142073
b: refs/heads/master
c: b997876
h: refs/heads/master
i:
  142071: b48f8fa
v: v3
  • Loading branch information
Andrew Vasquez authored and James Bottomley committed Apr 3, 2009
1 parent 0f345a5 commit 0ec1fae
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 20 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: e612d46591e2d4fbc35541377d18ab483c211768
refs/heads/master: b9978769877c6c90c8d6777df13b9ae427af40b7
49 changes: 30 additions & 19 deletions trunk/drivers/scsi/qla2xxx/qla_os.c
Original file line number Diff line number Diff line change
Expand Up @@ -1890,6 +1890,16 @@ qla2x00_probe_one(struct pci_dev *pdev, const struct pci_device_id *id)
ha->max_queues = 0;

probe_failed:
if (base_vha->timer_active)
qla2x00_stop_timer(base_vha);
base_vha->flags.online = 0;
if (ha->dpc_thread) {
struct task_struct *t = ha->dpc_thread;

ha->dpc_thread = NULL;
kthread_stop(t);
}

qla2x00_free_device(base_vha);

scsi_host_put(base_vha->host);
Expand Down Expand Up @@ -1923,10 +1933,30 @@ qla2x00_remove_one(struct pci_dev *pdev)

set_bit(UNLOADING, &base_vha->dpc_flags);

qla2x00_abort_all_cmds(base_vha, DID_NO_CONNECT << 16);

qla2x00_dfs_remove(base_vha);

qla84xx_put_chip(base_vha);

/* Disable timer */
if (base_vha->timer_active)
qla2x00_stop_timer(base_vha);

base_vha->flags.online = 0;

/* Kill the kernel thread for this host */
if (ha->dpc_thread) {
struct task_struct *t = ha->dpc_thread;

/*
* qla2xxx_wake_dpc checks for ->dpc_thread
* so we need to zero it out.
*/
ha->dpc_thread = NULL;
kthread_stop(t);
}

qla2x00_free_sysfs_attr(base_vha);

fc_remove_host(base_vha->host);
Expand Down Expand Up @@ -1955,25 +1985,6 @@ static void
qla2x00_free_device(scsi_qla_host_t *vha)
{
struct qla_hw_data *ha = vha->hw;
qla2x00_abort_all_cmds(vha, DID_NO_CONNECT << 16);

/* Disable timer */
if (vha->timer_active)
qla2x00_stop_timer(vha);

vha->flags.online = 0;

/* Kill the kernel thread for this host */
if (ha->dpc_thread) {
struct task_struct *t = ha->dpc_thread;

/*
* qla2xxx_wake_dpc checks for ->dpc_thread
* so we need to zero it out.
*/
ha->dpc_thread = NULL;
kthread_stop(t);
}

if (ha->flags.fce_enabled)
qla2x00_disable_fce_trace(vha, NULL, NULL);
Expand Down

0 comments on commit 0ec1fae

Please sign in to comment.