Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 161069
b: refs/heads/master
c: a67417a
h: refs/heads/master
i:
  161067: 565d417
v: v3
  • Loading branch information
Swen Schillig authored and James Bottomley committed Sep 5, 2009
1 parent 571c0dd commit f4f51db
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 5 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: cdf69bb91b0ef14f0e0a987a4430764e6c290644
refs/heads/master: a67417ab7eeff45bba55666c0e1083260f3624ee
7 changes: 5 additions & 2 deletions trunk/drivers/s390/scsi/zfcp_aux.c
Original file line number Diff line number Diff line change
Expand Up @@ -672,12 +672,15 @@ struct zfcp_port *zfcp_port_enqueue(struct zfcp_adapter *adapter, u64 wwpn,
*/
void zfcp_port_dequeue(struct zfcp_port *port)
{
wait_event(port->remove_wq, atomic_read(&port->refcount) == 0);
write_lock_irq(&zfcp_data.config_lock);
list_del(&port->list);
write_unlock_irq(&zfcp_data.config_lock);
if (port->rport)
if (port->rport) {
port->rport->dd_data = NULL;
port->rport = NULL;
}
wait_event(port->remove_wq, atomic_read(&port->refcount) == 0);
cancel_work_sync(&port->rport_work); /* usually not necessary */
zfcp_adapter_put(port->adapter);
sysfs_remove_group(&port->sysfs_device.kobj, &zfcp_sysfs_port_attrs);
device_unregister(&port->sysfs_device);
Expand Down
6 changes: 4 additions & 2 deletions trunk/drivers/s390/scsi/zfcp_scsi.c
Original file line number Diff line number Diff line change
Expand Up @@ -582,8 +582,10 @@ void zfcp_scsi_schedule_rport_block(struct zfcp_port *port)
zfcp_port_get(port);
port->rport_task = RPORT_DEL;

if (!queue_work(zfcp_data.work_queue, &port->rport_work))
zfcp_port_put(port);
if (port->rport && queue_work(zfcp_data.work_queue, &port->rport_work))
return;

zfcp_port_put(port);
}

void zfcp_scsi_schedule_rports_block(struct zfcp_adapter *adapter)
Expand Down

0 comments on commit f4f51db

Please sign in to comment.