diff options
Diffstat (limited to 'drivers/infiniband/ulp')
-rw-r--r-- | drivers/infiniband/ulp/srp/ib_srp.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/drivers/infiniband/ulp/srp/ib_srp.c b/drivers/infiniband/ulp/srp/ib_srp.c index ae1ab6acf460..46292561c44c 100644 --- a/drivers/infiniband/ulp/srp/ib_srp.c +++ b/drivers/infiniband/ulp/srp/ib_srp.c | |||
@@ -1850,7 +1850,6 @@ static void srp_remove_one(struct ib_device *device) | |||
1850 | struct srp_host *host, *tmp_host; | 1850 | struct srp_host *host, *tmp_host; |
1851 | LIST_HEAD(target_list); | 1851 | LIST_HEAD(target_list); |
1852 | struct srp_target_port *target, *tmp_target; | 1852 | struct srp_target_port *target, *tmp_target; |
1853 | unsigned long flags; | ||
1854 | 1853 | ||
1855 | srp_dev = ib_get_client_data(device, &srp_client); | 1854 | srp_dev = ib_get_client_data(device, &srp_client); |
1856 | 1855 | ||
@@ -1868,10 +1867,9 @@ static void srp_remove_one(struct ib_device *device) | |||
1868 | */ | 1867 | */ |
1869 | spin_lock(&host->target_lock); | 1868 | spin_lock(&host->target_lock); |
1870 | list_for_each_entry(target, &host->target_list, list) { | 1869 | list_for_each_entry(target, &host->target_list, list) { |
1871 | spin_lock_irqsave(target->scsi_host->host_lock, flags); | 1870 | spin_lock_irq(target->scsi_host->host_lock); |
1872 | if (target->state != SRP_TARGET_REMOVED) | 1871 | target->state = SRP_TARGET_REMOVED; |
1873 | target->state = SRP_TARGET_REMOVED; | 1872 | spin_unlock_irq(target->scsi_host->host_lock); |
1874 | spin_unlock_irqrestore(target->scsi_host->host_lock, flags); | ||
1875 | } | 1873 | } |
1876 | spin_unlock(&host->target_lock); | 1874 | spin_unlock(&host->target_lock); |
1877 | 1875 | ||