Commit 6cdc57c0 authored by K. Y. Srinivasan's avatar K. Y. Srinivasan Committed by Greg Kroah-Hartman

Staging: hv: storvsc_drv: Get rid of the indirection in invoking storvsc_dev_remove()

Get rid of the indirection in invoking storvsc_dev_remove()
Signed-off-by: default avatarK. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: default avatarHaiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: default avatarAbhishek Kane <v-abkane@microsoft.com>
Signed-off-by: default avatarHank Janssen <hjanssen@microsoft.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 9b3e773b
......@@ -359,8 +359,6 @@ static unsigned int copy_to_bounce_buffer(struct scatterlist *orig_sgl,
*/
static int storvsc_remove(struct hv_device *dev)
{
struct storvsc_driver *storvsc_drv_obj =
drv_to_stordrv(dev->device.driver);
struct Scsi_Host *host = dev_get_drvdata(&dev->device);
struct hv_host_device *host_dev =
(struct hv_host_device *)host->hostdata;
......@@ -369,7 +367,7 @@ static int storvsc_remove(struct hv_device *dev)
* Call to the vsc driver to let it know that the device is being
* removed
*/
storvsc_drv_obj->base.dev_rm(dev);
storvsc_dev_remove(dev);
if (host_dev->request_pool) {
kmem_cache_destroy(host_dev->request_pool);
......@@ -842,7 +840,7 @@ static int storvsc_probe(struct hv_device *device)
ret = scsi_add_host(host, &device->device);
if (ret != 0) {
storvsc_drv_obj->base.dev_rm(device);
storvsc_dev_remove(device);
kmem_cache_destroy(host_dev->request_pool);
scsi_host_put(host);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment