diff options
Diffstat (limited to 'drivers/scsi/bfa/bfad_attr.c')
-rw-r--r-- | drivers/scsi/bfa/bfad_attr.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/scsi/bfa/bfad_attr.c b/drivers/scsi/bfa/bfad_attr.c index 06310b8e562d..7b1ecd2b3ffe 100644 --- a/drivers/scsi/bfa/bfad_attr.c +++ b/drivers/scsi/bfa/bfad_attr.c | |||
@@ -494,8 +494,11 @@ bfad_im_vport_delete(struct fc_vport *fc_vport) | |||
494 | unsigned long flags; | 494 | unsigned long flags; |
495 | struct completion fcomp; | 495 | struct completion fcomp; |
496 | 496 | ||
497 | if (im_port->flags & BFAD_PORT_DELETE) | 497 | if (im_port->flags & BFAD_PORT_DELETE) { |
498 | goto free_scsi_host; | 498 | bfad_scsi_host_free(bfad, im_port); |
499 | list_del(&vport->list_entry); | ||
500 | return 0; | ||
501 | } | ||
499 | 502 | ||
500 | port = im_port->port; | 503 | port = im_port->port; |
501 | 504 | ||
@@ -526,7 +529,6 @@ bfad_im_vport_delete(struct fc_vport *fc_vport) | |||
526 | 529 | ||
527 | wait_for_completion(vport->comp_del); | 530 | wait_for_completion(vport->comp_del); |
528 | 531 | ||
529 | free_scsi_host: | ||
530 | bfad_scsi_host_free(bfad, im_port); | 532 | bfad_scsi_host_free(bfad, im_port); |
531 | list_del(&vport->list_entry); | 533 | list_del(&vport->list_entry); |
532 | kfree(vport); | 534 | kfree(vport); |