diff options
Diffstat (limited to 'drivers/s390/scsi/zfcp_cfdc.c')
-rw-r--r-- | drivers/s390/scsi/zfcp_cfdc.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/s390/scsi/zfcp_cfdc.c b/drivers/s390/scsi/zfcp_cfdc.c index ef681dfed0cc..856f82dbcb1b 100644 --- a/drivers/s390/scsi/zfcp_cfdc.c +++ b/drivers/s390/scsi/zfcp_cfdc.c | |||
@@ -98,7 +98,7 @@ static struct zfcp_adapter *zfcp_cfdc_get_adapter(u32 devno) | |||
98 | if (!adapter) | 98 | if (!adapter) |
99 | goto out_put; | 99 | goto out_put; |
100 | 100 | ||
101 | zfcp_adapter_get(adapter); | 101 | kref_get(&adapter->ref); |
102 | out_put: | 102 | out_put: |
103 | put_device(&ccwdev->dev); | 103 | put_device(&ccwdev->dev); |
104 | out: | 104 | out: |
@@ -212,7 +212,6 @@ static long zfcp_cfdc_dev_ioctl(struct file *file, unsigned int command, | |||
212 | retval = -ENXIO; | 212 | retval = -ENXIO; |
213 | goto free_buffer; | 213 | goto free_buffer; |
214 | } | 214 | } |
215 | zfcp_adapter_get(adapter); | ||
216 | 215 | ||
217 | retval = zfcp_cfdc_sg_setup(data->command, fsf_cfdc->sg, | 216 | retval = zfcp_cfdc_sg_setup(data->command, fsf_cfdc->sg, |
218 | data_user->control_file); | 217 | data_user->control_file); |
@@ -245,7 +244,7 @@ static long zfcp_cfdc_dev_ioctl(struct file *file, unsigned int command, | |||
245 | free_sg: | 244 | free_sg: |
246 | zfcp_sg_free_table(fsf_cfdc->sg, ZFCP_CFDC_PAGES); | 245 | zfcp_sg_free_table(fsf_cfdc->sg, ZFCP_CFDC_PAGES); |
247 | adapter_put: | 246 | adapter_put: |
248 | zfcp_adapter_put(adapter); | 247 | kref_put(&adapter->ref, zfcp_adapter_release); |
249 | free_buffer: | 248 | free_buffer: |
250 | kfree(data); | 249 | kfree(data); |
251 | no_mem_sense: | 250 | no_mem_sense: |