• Jing Huang's avatar
    [SCSI] bfa: vport fixes · c54d557c
    Jing Huang authored
    This patch fixes 3 bugs in vport create/delete.
    1) Replace scsi_add_host() with scsi_add_host_with_dma()
    2) Fix rmmod hang when there are vports configured. This is due to a race
    condition between the workqueue destroy in pci remove context and the vport
    delete works being handled. The fix is to use a counter to track the
    vport delete work, so that workqueue destroy will not be called until all
    configured vports are deleted from workqueue.
    3) Fix rmmmod crash when there are PBC vport configured. PBC is not allowed
    to be deleted dynamically. However, if someone try to delete it, it leaves the
    vport is wrong state. The fix is to restore the vport back to original state
    when the attempt to delete pbc vport delete is failed.
    Signed-off-by: default avatarJing Huang <huangj@brocade.com>
    Signed-off-by: default avatarJames Bottomley <James.Bottomley@suse.de>
    c54d557c
bfad_drv.h 7.91 KB