summaryrefslogtreecommitdiff
path: root/drivers/staging/hv/blkvsc_drv.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/staging/hv/blkvsc_drv.c')
-rw-r--r--drivers/staging/hv/blkvsc_drv.c58
1 files changed, 29 insertions, 29 deletions
diff --git a/drivers/staging/hv/blkvsc_drv.c b/drivers/staging/hv/blkvsc_drv.c
index 4fb809485d9e..58bbcd60b3d7 100644
--- a/drivers/staging/hv/blkvsc_drv.c
+++ b/drivers/staging/hv/blkvsc_drv.c
@@ -183,7 +183,7 @@ static int blkvsc_drv_init(int (*drv_init)(struct hv_driver *drv))
drv_init(&storvsc_drv_obj->base);
drv_ctx->driver.name = storvsc_drv_obj->base.name;
- memcpy(&drv_ctx->class_id, &storvsc_drv_obj->base.deviceType,
+ memcpy(&drv_ctx->class_id, &storvsc_drv_obj->base.dev_type,
sizeof(struct hv_guid));
drv_ctx->probe = blkvsc_probe;
@@ -230,8 +230,8 @@ static void blkvsc_drv_exit(void)
device_unregister(current_dev);
}
- if (storvsc_drv_obj->base.OnCleanup)
- storvsc_drv_obj->base.OnCleanup(&storvsc_drv_obj->base);
+ if (storvsc_drv_obj->base.cleanup)
+ storvsc_drv_obj->base.cleanup(&storvsc_drv_obj->base);
vmbus_child_driver_unregister(drv_ctx);
@@ -262,7 +262,7 @@ static int blkvsc_probe(struct device *device)
DPRINT_DBG(BLKVSC_DRV, "blkvsc_probe - enter");
- if (!storvsc_drv_obj->base.OnDeviceAdd) {
+ if (!storvsc_drv_obj->base.dev_add) {
DPRINT_ERR(BLKVSC_DRV, "OnDeviceAdd() not set");
ret = -1;
goto Cleanup;
@@ -293,7 +293,7 @@ static int blkvsc_probe(struct device *device)
/* Call to the vsc driver to add the device */
- ret = storvsc_drv_obj->base.OnDeviceAdd(device_obj, &device_info);
+ ret = storvsc_drv_obj->base.dev_add(device_obj, &device_info);
if (ret != 0) {
DPRINT_ERR(BLKVSC_DRV, "unable to add blkvsc device");
goto Cleanup;
@@ -392,7 +392,7 @@ static int blkvsc_probe(struct device *device)
return ret;
Remove:
- storvsc_drv_obj->base.OnDeviceRemove(device_obj);
+ storvsc_drv_obj->base.dev_rm(device_obj);
Cleanup:
if (blkdev) {
@@ -460,9 +460,9 @@ static int blkvsc_do_flush(struct block_device_context *blkdev)
blkvsc_req->req = NULL;
blkvsc_req->write = 0;
- blkvsc_req->request.data_buffer.PfnArray[0] = 0;
- blkvsc_req->request.data_buffer.Offset = 0;
- blkvsc_req->request.data_buffer.Length = 0;
+ blkvsc_req->request.data_buffer.pfn_array[0] = 0;
+ blkvsc_req->request.data_buffer.offset = 0;
+ blkvsc_req->request.data_buffer.len = 0;
blkvsc_req->cmnd[0] = SYNCHRONIZE_CACHE;
blkvsc_req->cmd_len = 10;
@@ -507,9 +507,9 @@ static int blkvsc_do_inquiry(struct block_device_context *blkdev)
blkvsc_req->req = NULL;
blkvsc_req->write = 0;
- blkvsc_req->request.data_buffer.PfnArray[0] = page_to_pfn(page_buf);
- blkvsc_req->request.data_buffer.Offset = 0;
- blkvsc_req->request.data_buffer.Length = 64;
+ blkvsc_req->request.data_buffer.pfn_array[0] = page_to_pfn(page_buf);
+ blkvsc_req->request.data_buffer.offset = 0;
+ blkvsc_req->request.data_buffer.len = 64;
blkvsc_req->cmnd[0] = INQUIRY;
blkvsc_req->cmnd[1] = 0x1; /* Get product data */
@@ -594,9 +594,9 @@ static int blkvsc_do_read_capacity(struct block_device_context *blkdev)
blkvsc_req->req = NULL;
blkvsc_req->write = 0;
- blkvsc_req->request.data_buffer.PfnArray[0] = page_to_pfn(page_buf);
- blkvsc_req->request.data_buffer.Offset = 0;
- blkvsc_req->request.data_buffer.Length = 8;
+ blkvsc_req->request.data_buffer.pfn_array[0] = page_to_pfn(page_buf);
+ blkvsc_req->request.data_buffer.offset = 0;
+ blkvsc_req->request.data_buffer.len = 8;
blkvsc_req->cmnd[0] = READ_CAPACITY;
blkvsc_req->cmd_len = 16;
@@ -671,9 +671,9 @@ static int blkvsc_do_read_capacity16(struct block_device_context *blkdev)
blkvsc_req->req = NULL;
blkvsc_req->write = 0;
- blkvsc_req->request.data_buffer.PfnArray[0] = page_to_pfn(page_buf);
- blkvsc_req->request.data_buffer.Offset = 0;
- blkvsc_req->request.data_buffer.Length = 12;
+ blkvsc_req->request.data_buffer.pfn_array[0] = page_to_pfn(page_buf);
+ blkvsc_req->request.data_buffer.offset = 0;
+ blkvsc_req->request.data_buffer.len = 12;
blkvsc_req->cmnd[0] = 0x9E; /* READ_CAPACITY16; */
blkvsc_req->cmd_len = 16;
@@ -742,14 +742,14 @@ static int blkvsc_remove(struct device *device)
DPRINT_DBG(BLKVSC_DRV, "blkvsc_remove()\n");
- if (!storvsc_drv_obj->base.OnDeviceRemove)
+ if (!storvsc_drv_obj->base.dev_rm)
return -1;
/*
* Call to the vsc driver to let it know that the device is being
* removed
*/
- ret = storvsc_drv_obj->base.OnDeviceRemove(device_obj);
+ ret = storvsc_drv_obj->base.dev_rm(device_obj);
if (ret != 0) {
/* TODO: */
DPRINT_ERR(BLKVSC_DRV,
@@ -866,14 +866,14 @@ static int blkvsc_submit_request(struct blkvsc_request *blkvsc_req,
(blkvsc_req->write) ? "WRITE" : "READ",
(unsigned long) blkvsc_req->sector_start,
blkvsc_req->sector_count,
- blkvsc_req->request.data_buffer.Offset,
- blkvsc_req->request.data_buffer.Length);
+ blkvsc_req->request.data_buffer.offset,
+ blkvsc_req->request.data_buffer.len);
#if 0
- for (i = 0; i < (blkvsc_req->request.data_buffer.Length >> 12); i++) {
+ for (i = 0; i < (blkvsc_req->request.data_buffer.len >> 12); i++) {
DPRINT_DBG(BLKVSC_DRV, "blkvsc_submit_request() - "
"req %p pfn[%d] %llx\n",
blkvsc_req, i,
- blkvsc_req->request.data_buffer.PfnArray[i]);
+ blkvsc_req->request.data_buffer.pfn_array[i]);
}
#endif
@@ -993,9 +993,9 @@ static int blkvsc_do_request(struct block_device_context *blkdev,
blkvsc_req->dev = blkdev;
blkvsc_req->req = req;
- blkvsc_req->request.data_buffer.Offset
+ blkvsc_req->request.data_buffer.offset
= bvec->bv_offset;
- blkvsc_req->request.data_buffer.Length
+ blkvsc_req->request.data_buffer.len
= 0;
/* Add to the group */
@@ -1011,9 +1011,9 @@ static int blkvsc_do_request(struct block_device_context *blkdev,
/* Add the curr bvec/segment to the curr blkvsc_req */
blkvsc_req->request.data_buffer.
- PfnArray[databuf_idx]
+ pfn_array[databuf_idx]
= page_to_pfn(bvec->bv_page);
- blkvsc_req->request.data_buffer.Length
+ blkvsc_req->request.data_buffer.len
+= bvec->bv_len;
prev_bvec = bvec;
@@ -1116,7 +1116,7 @@ static void blkvsc_request_completion(struct hv_storvsc_request *request)
(blkvsc_req->write) ? "WRITE" : "READ",
(unsigned long)blkvsc_req->sector_start,
blkvsc_req->sector_count,
- blkvsc_req->request.data_buffer.Length,
+ blkvsc_req->request.data_buffer.len,
blkvsc_req->group->outstanding,
blkdev->num_outstanding_reqs);