]> git.karo-electronics.de Git - linux-beck.git/commitdiff
Staging: hv: Use generic device_driver probe function
authorK. Y. Srinivasan <kys@microsoft.com>
Mon, 7 Mar 2011 21:20:57 +0000 (13:20 -0800)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 7 Mar 2011 22:09:17 +0000 (14:09 -0800)
In preparation for moving all the state from struct driver_context
to struct hv_driver, eliminate the probe() function from
struct driver_context and use generic device_driver probe
function.

Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Abhishek Kane <v-abkane@microsoft.com>
Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Hank Janssen <hjanssen@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/hv/blkvsc_drv.c
drivers/staging/hv/hv_mouse.c
drivers/staging/hv/netvsc_drv.c
drivers/staging/hv/storvsc_drv.c
drivers/staging/hv/vmbus_drv.c

index 36a0adbaa98715df82e389e0c08d8a37b8b9d90c..0dff55791d26fc8666129c32ebc92f3db5a34327 100644 (file)
@@ -186,7 +186,7 @@ static int blkvsc_drv_init(int (*drv_init)(struct hv_driver *drv))
        memcpy(&drv_ctx->class_id, &storvsc_drv_obj->base.dev_type,
               sizeof(struct hv_guid));
 
-       drv_ctx->probe = blkvsc_probe;
+       drv_ctx->driver.probe = blkvsc_probe;
        drv_ctx->remove = blkvsc_remove;
        drv_ctx->shutdown = blkvsc_shutdown;
 
index 1aaaef4695e347a2c023d64d567666222173d237..4a25f3b8770daa67eaf87128aed0476c231e75fc 100644 (file)
@@ -1021,7 +1021,7 @@ static int __init mousevsc_init(void)
        memcpy(&drv_ctx->class_id, &input_drv_obj->Base.dev_type,
               sizeof(struct hv_guid));
 
-       drv_ctx->probe = mousevsc_probe;
+       drv_ctx->driver.probe = mousevsc_probe;
        drv_ctx->remove = mousevsc_remove;
 
        /* The driver belongs to vmbus */
index 03f97404a2def24ec17b98f77d9b721d6b1761c6..083f0d34859892937363a1f7cd500ccbc5a75357 100644 (file)
@@ -511,7 +511,7 @@ static int netvsc_drv_init(int (*drv_init)(struct hv_driver *drv))
        memcpy(&drv_ctx->class_id, &net_drv_obj->base.dev_type,
               sizeof(struct hv_guid));
 
-       drv_ctx->probe = netvsc_probe;
+       drv_ctx->driver.probe = netvsc_probe;
        drv_ctx->remove = netvsc_remove;
 
        /* The driver belongs to vmbus */
index a8427ffd162bd465bc603bcbc7759001e1de45a7..3fe4bdb4ec927d568ed59b17081dcf2e1b3aa32f 100644 (file)
@@ -164,7 +164,7 @@ static int storvsc_drv_init(int (*drv_init)(struct hv_driver *drv))
        memcpy(&drv_ctx->class_id, &storvsc_drv_obj->base.dev_type,
               sizeof(struct hv_guid));
 
-       drv_ctx->probe = storvsc_probe;
+       drv_ctx->driver.probe = storvsc_probe;
        drv_ctx->remove = storvsc_remove;
 
        /* The driver belongs to vmbus */
index 459c707afe572cf4443db12b801fa4df32eb9275..fee2a8f9b4e48f8d9bd4fc2c3e4993284aa70876 100644 (file)
@@ -919,8 +919,9 @@ static int vmbus_probe(struct device *child_device)
                        device_to_vm_device(child_device);
 
        /* Let the specific open-source driver handles the probe if it can */
-       if (driver_ctx->probe) {
-               ret = device_ctx->probe_error = driver_ctx->probe(child_device);
+       if (driver_ctx->driver.probe) {
+               ret = device_ctx->probe_error =
+               driver_ctx->driver.probe(child_device);
                if (ret != 0) {
                        DPRINT_ERR(VMBUS_DRV, "probe() failed for device %s "
                                   "(%p) on driver %s (%d)...",