Staging: hv: Get rid of the indirection to invoke rndis_filte_device_add()
authorK. Y. Srinivasan <kys@microsoft.com>
Tue, 10 May 2011 14:54:59 +0000 (07:54 -0700)
committerGreg Kroah-Hartman <gregkh@suse.de>
Wed, 11 May 2011 20:48:46 +0000 (13:48 -0700)
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Abhishek Kane <v-abkane@microsoft.com>
Signed-off-by: Hank Janssen <hjanssen@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/hv/netvsc_drv.c

index f4c600071b1a6dbd4e0bf5ce197676a5e23e9f12..d962308926f042bf8aa3e21df070135e8212b177 100644 (file)
@@ -349,9 +349,6 @@ static int netvsc_probe(struct hv_device *dev)
        struct netvsc_device_info device_info;
        int ret;
 
-       if (!net_drv_obj->base.dev_add)
-               return -1;
-
        net = alloc_etherdev(sizeof(struct net_device_context));
        if (!net)
                return -1;
@@ -366,7 +363,7 @@ static int netvsc_probe(struct hv_device *dev)
        INIT_WORK(&net_device_ctx->work, netvsc_send_garp);
 
        /* Notify the netvsc driver of the new device */
-       ret = net_drv_obj->base.dev_add(dev, &device_info);
+       ret = rndis_filte_device_add(dev, &device_info);
        if (ret != 0) {
                free_netdev(net);
                dev_set_drvdata(&dev->device, NULL);