Staging: hv: fix typedefs in StorVscApi.h
authorGreg Kroah-Hartman <gregkh@suse.de>
Fri, 28 Aug 2009 23:20:07 +0000 (16:20 -0700)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 15 Sep 2009 19:02:00 +0000 (12:02 -0700)
It's all clean now.

Cc: Hank Janssen <hjanssen@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/hv/BlkVsc.c
drivers/staging/hv/StorVsc.c
drivers/staging/hv/blkvsc_drv.c
drivers/staging/hv/include/StorVscApi.h
drivers/staging/hv/storvsc_drv.c

index d613e59..d433d8c 100644 (file)
@@ -48,7 +48,7 @@ BlkVscInitialize(
        struct hv_driver *Driver
        )
 {
-       STORVSC_DRIVER_OBJECT* storDriver = (STORVSC_DRIVER_OBJECT*)Driver;
+       struct storvsc_driver_object *storDriver = (struct storvsc_driver_object *)Driver;
        int ret=0;
 
        DPRINT_ENTER(BLKVSC);
@@ -86,7 +86,7 @@ BlkVscOnDeviceAdd(
        )
 {
        int ret=0;
-       STORVSC_DEVICE_INFO *deviceInfo = (STORVSC_DEVICE_INFO*)AdditionalInfo;
+       struct storvsc_device_info *deviceInfo = (struct storvsc_device_info *)AdditionalInfo;
 
        DPRINT_ENTER(BLKVSC);
 
index bcc545f..edb3ab6 100644 (file)
@@ -261,7 +261,7 @@ StorVscInitialize(
        struct hv_driver *Driver
        )
 {
-       STORVSC_DRIVER_OBJECT* storDriver = (STORVSC_DRIVER_OBJECT*)Driver;
+       struct storvsc_driver_object *storDriver = (struct storvsc_driver_object *)Driver;
        int ret=0;
 
        DPRINT_ENTER(STORVSC);
@@ -319,7 +319,7 @@ StorVscOnDeviceAdd(
        int ret=0;
        STORVSC_DEVICE *storDevice;
        /* struct vmstorage_channel_properties *props; */
-       STORVSC_DEVICE_INFO *deviceInfo = (STORVSC_DEVICE_INFO*)AdditionalInfo;
+       struct storvsc_device_info *deviceInfo = (struct storvsc_device_info *)AdditionalInfo;
 
        DPRINT_ENTER(STORVSC);
 
@@ -530,7 +530,7 @@ StorVscConnectToVsp(
        int ret=0;
        struct vmstorage_channel_properties props;
 
-       STORVSC_DRIVER_OBJECT *storDriver = (STORVSC_DRIVER_OBJECT*) Device->Driver;;
+       struct storvsc_driver_object *storDriver = (struct storvsc_driver_object *)Device->Driver;;
 
        memset(&props, sizeof(struct vmstorage_channel_properties), 0);
 
@@ -615,11 +615,11 @@ void *Context
 )
 {
 struct hv_device *device=(struct hv_device *)Context;
-STORVSC_DRIVER_OBJECT *storDriver;
+struct storvsc_driver_object *storDriver;
 
 DPRINT_ENTER(STORVSC);
 
-storDriver = (STORVSC_DRIVER_OBJECT*) device->Driver;
+storDriver = (struct storvsc_driver_object*) device->Driver;
 storDriver->OnHostRescan(device);
 
 DPRINT_EXIT(STORVSC);
index f91fa43..8dcc140 100644 (file)
@@ -117,7 +117,7 @@ struct block_device_context {
 struct blkvsc_driver_context {
        /* !! These must be the first 2 fields !! */
        struct driver_context   drv_ctx;
-       STORVSC_DRIVER_OBJECT   drv_obj;
+       struct storvsc_driver_object drv_obj;
 };
 
 /* Static decl */
@@ -173,7 +173,7 @@ Desc:       BlkVsc driver initialization.
 static int blkvsc_drv_init(PFN_DRIVERINITIALIZE pfn_drv_init)
 {
        int ret=0;
-       STORVSC_DRIVER_OBJECT *storvsc_drv_obj=&g_blkvsc_drv.drv_obj;
+       struct storvsc_driver_object *storvsc_drv_obj = &g_blkvsc_drv.drv_obj;
        struct driver_context *drv_ctx=&g_blkvsc_drv.drv_ctx;
 
        DPRINT_ENTER(BLKVSC_DRV);
@@ -217,7 +217,7 @@ Desc:
 --*/
 static void blkvsc_drv_exit(void)
 {
-       STORVSC_DRIVER_OBJECT *storvsc_drv_obj=&g_blkvsc_drv.drv_obj;
+       struct storvsc_driver_object *storvsc_drv_obj = &g_blkvsc_drv.drv_obj;
        struct driver_context *drv_ctx=&g_blkvsc_drv.drv_ctx;
        struct device *current_dev=NULL;
        int ret;
@@ -268,13 +268,13 @@ static int blkvsc_probe(struct device *device)
 
        struct driver_context *driver_ctx = driver_to_driver_context(device->driver);
        struct blkvsc_driver_context *blkvsc_drv_ctx = (struct blkvsc_driver_context*)driver_ctx;
-       STORVSC_DRIVER_OBJECT* storvsc_drv_obj = &blkvsc_drv_ctx->drv_obj;
+       struct storvsc_driver_object *storvsc_drv_obj = &blkvsc_drv_ctx->drv_obj;
 
        struct device_context *device_ctx = device_to_device_context(device);
        struct hv_device *device_obj = &device_ctx->device_obj;
 
        struct block_device_context *blkdev=NULL;
-       STORVSC_DEVICE_INFO device_info;
+       struct storvsc_device_info device_info;
        int major=0;
        int devnum=0;
 
@@ -777,7 +777,7 @@ static int blkvsc_remove(struct device *device)
 
        struct driver_context *driver_ctx = driver_to_driver_context(device->driver);
        struct blkvsc_driver_context *blkvsc_drv_ctx = (struct blkvsc_driver_context*)driver_ctx;
-       STORVSC_DRIVER_OBJECT* storvsc_drv_obj = &blkvsc_drv_ctx->drv_obj;
+       struct storvsc_driver_object *storvsc_drv_obj = &blkvsc_drv_ctx->drv_obj;
 
        struct device_context *device_ctx = device_to_device_context(device);
        struct hv_device *device_obj = &device_ctx->device_obj;
@@ -907,7 +907,7 @@ static int blkvsc_submit_request(struct blkvsc_request *blkvsc_req, void (*reque
        struct device_context *device_ctx=blkdev->device_ctx;
        struct driver_context *driver_ctx = driver_to_driver_context(device_ctx->device.driver);
        struct blkvsc_driver_context *blkvsc_drv_ctx = (struct blkvsc_driver_context*)driver_ctx;
-       STORVSC_DRIVER_OBJECT* storvsc_drv_obj = &blkvsc_drv_ctx->drv_obj;
+       struct storvsc_driver_object *storvsc_drv_obj = &blkvsc_drv_ctx->drv_obj;
        int ret =0;
 
        struct hv_storvsc_request *storvsc_req;
index 2deefbd..56193ff 100644 (file)
@@ -54,14 +54,14 @@ typedef int (*PFN_ON_HOST_RESET)(struct hv_device *Device);
 typedef void (*PFN_ON_HOST_RESCAN)(struct hv_device *Device);
 
 /* Matches Windows-end */
-typedef enum _STORVSC_REQUEST_TYPE{
+enum storvsc_request_type{
        WRITE_TYPE,
        READ_TYPE,
        UNKNOWN_TYPE,
-} STORVSC_REQUEST_TYPE;
+};
 
 struct hv_storvsc_request {
-       STORVSC_REQUEST_TYPE Type;
+       enum storvsc_request_type Type;
        u32 Host;
        u32 Bus;
        u32 TargetId;
@@ -85,7 +85,7 @@ struct hv_storvsc_request {
 };
 
 /* Represents the block vsc driver */
-typedef struct _STORVSC_DRIVER_OBJECT {
+struct storvsc_driver_object {
        /* Must be the first field */
        /* Which is a bug FIXME! */
        struct hv_driver Base;
@@ -105,13 +105,13 @@ typedef struct _STORVSC_DRIVER_OBJECT {
        /* Specific to this driver */
        PFN_ON_IO_REQUEST OnIORequest;
        PFN_ON_HOST_RESET OnHostReset;
-} STORVSC_DRIVER_OBJECT;
+};
 
-typedef struct _STORVSC_DEVICE_INFO {
+struct storvsc_device_info {
        unsigned int PortNumber;
        unsigned char PathId;
        unsigned char TargetId;
-} STORVSC_DEVICE_INFO;
+};
 
 /* Interface */
 int StorVscInitialize(struct hv_driver *driver);
index a3d591d..155ba1d 100644 (file)
@@ -72,7 +72,7 @@ struct storvsc_cmd_request {
 struct storvsc_driver_context {
        /* !! These must be the first 2 fields !! */
        struct driver_context   drv_ctx;
-       STORVSC_DRIVER_OBJECT   drv_obj;
+       struct storvsc_driver_object drv_obj;
 };
 
 /* Static decl */
@@ -133,7 +133,7 @@ Desc:       StorVsc driver initialization.
 static int storvsc_drv_init(PFN_DRIVERINITIALIZE pfn_drv_init)
 {
        int ret=0;
-       STORVSC_DRIVER_OBJECT *storvsc_drv_obj=&g_storvsc_drv.drv_obj;
+       struct storvsc_driver_object *storvsc_drv_obj = &g_storvsc_drv.drv_obj;
        struct driver_context *drv_ctx=&g_storvsc_drv.drv_ctx;
 
        DPRINT_ENTER(STORVSC_DRV);
@@ -186,7 +186,7 @@ Desc:
 --*/
 static void storvsc_drv_exit(void)
 {
-       STORVSC_DRIVER_OBJECT *storvsc_drv_obj=&g_storvsc_drv.drv_obj;
+       struct storvsc_driver_object *storvsc_drv_obj = &g_storvsc_drv.drv_obj;
        struct driver_context *drv_ctx=&g_storvsc_drv.drv_ctx;
        struct device *current_dev=NULL;
        int ret;
@@ -236,14 +236,14 @@ static int storvsc_probe(struct device *device)
 
        struct driver_context *driver_ctx = driver_to_driver_context(device->driver);
        struct storvsc_driver_context *storvsc_drv_ctx = (struct storvsc_driver_context*)driver_ctx;
-       STORVSC_DRIVER_OBJECT* storvsc_drv_obj = &storvsc_drv_ctx->drv_obj;
+       struct storvsc_driver_object *storvsc_drv_obj = &storvsc_drv_ctx->drv_obj;
 
        struct device_context *device_ctx = device_to_device_context(device);
        struct hv_device *device_obj = &device_ctx->device_obj;
 
        struct Scsi_Host *host;
        struct host_device_context *host_device_ctx;
-       STORVSC_DEVICE_INFO device_info;
+       struct storvsc_device_info device_info;
 
        DPRINT_ENTER(STORVSC_DRV);
 
@@ -339,7 +339,7 @@ static int storvsc_remove(struct device *device)
 
        struct driver_context *driver_ctx = driver_to_driver_context(device->driver);
        struct storvsc_driver_context *storvsc_drv_ctx = (struct storvsc_driver_context*)driver_ctx;
-       STORVSC_DRIVER_OBJECT* storvsc_drv_obj = &storvsc_drv_ctx->drv_obj;
+       struct storvsc_driver_object *storvsc_drv_obj = &storvsc_drv_ctx->drv_obj;
 
        struct device_context *device_ctx = device_to_device_context(device);
        struct hv_device *device_obj = &device_ctx->device_obj;
@@ -665,7 +665,7 @@ static int storvsc_queuecommand(struct scsi_cmnd *scmnd, void (*done)(struct scs
        struct device_context *device_ctx=host_device_ctx->device_ctx;
        struct driver_context *driver_ctx = driver_to_driver_context(device_ctx->device.driver);
        struct storvsc_driver_context *storvsc_drv_ctx = (struct storvsc_driver_context*)driver_ctx;
-       STORVSC_DRIVER_OBJECT* storvsc_drv_obj = &storvsc_drv_ctx->drv_obj;
+       struct storvsc_driver_object *storvsc_drv_obj = &storvsc_drv_ctx->drv_obj;
 
        struct hv_storvsc_request *request;
        struct storvsc_cmd_request *cmd_request;
@@ -887,7 +887,7 @@ static int storvsc_host_reset_handler(struct scsi_cmnd *scmnd)
        struct driver_context *driver_ctx = driver_to_driver_context(device_ctx->device.driver);
        struct storvsc_driver_context *storvsc_drv_ctx = (struct storvsc_driver_context*)driver_ctx;
 
-       STORVSC_DRIVER_OBJECT *storvsc_drv_obj = &storvsc_drv_ctx->drv_obj;
+       struct storvsc_driver_object *storvsc_drv_obj = &storvsc_drv_ctx->drv_obj;
 
        DPRINT_ENTER(STORVSC_DRV);