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

Staging: hv: netvsc_drv: Make netvsc_drv an instance of struct hv_driver

In preparation to getting rid of struct  netvsc_driver, make
the variable netvsc_drv an instance of struct hv_driver.
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 4e3cba6b
......@@ -428,26 +428,25 @@ static int netvsc_remove(struct hv_device *dev)
}
/* The one and only one */
static struct netvsc_driver netvsc_drv = {
.base.probe = netvsc_probe,
.base.remove = netvsc_remove,
static struct hv_driver netvsc_drv = {
.probe = netvsc_probe,
.remove = netvsc_remove,
};
static void netvsc_drv_exit(void)
{
vmbus_child_driver_unregister(&netvsc_drv.base.driver);
vmbus_child_driver_unregister(&netvsc_drv.driver);
}
static int netvsc_drv_init(int (*drv_init)(struct hv_driver *drv))
{
struct netvsc_driver *net_drv_obj = &netvsc_drv;
struct hv_driver *drv = &netvsc_drv.base;
struct hv_driver *drv = &netvsc_drv;
int ret;
/* Callback to client driver to complete the initialization */
drv_init(&net_drv_obj->base);
drv_init(drv);
drv->driver.name = net_drv_obj->base.name;
drv->driver.name = drv->name;
/* The driver belongs to vmbus */
ret = vmbus_child_driver_register(&drv->driver);
......
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