diff options
author | K. Y. Srinivasan <kys@microsoft.com> | 2011-12-12 21:29:17 +0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2011-12-13 02:26:50 +0400 |
commit | 93e5bd06a95343c701361fa009cdc5a653d6ec8e (patch) | |
tree | fe28f7a5ad3c009fbf8e197c94c74b444015630f /drivers/hv/vmbus_drv.c | |
parent | 8b8ee6753154dd6cfe397e0d29fe7f90a8adb50b (diff) | |
download | linux-93e5bd06a95343c701361fa009cdc5a653d6ec8e.tar.xz |
Drivers: hv: Make the vmbus driver unloadable
It turns out that the vmbus driver can be made unloadable. Make it
unloadable.
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/hv/vmbus_drv.c')
-rw-r--r-- | drivers/hv/vmbus_drv.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/drivers/hv/vmbus_drv.c b/drivers/hv/vmbus_drv.c index 40956d1c6608..c3875f72b5bf 100644 --- a/drivers/hv/vmbus_drv.c +++ b/drivers/hv/vmbus_drv.c @@ -795,8 +795,19 @@ cleanup: return ret; } +static void __exit vmbus_exit(void) +{ + + free_irq(irq, hv_acpi_dev); + vmbus_free_channels(); + bus_unregister(&hv_bus); + hv_cleanup(); + acpi_bus_unregister_driver(&vmbus_acpi_driver); +} + MODULE_LICENSE("GPL"); MODULE_VERSION(HV_DRV_VERSION); subsys_initcall(hv_acpi_init); +module_exit(vmbus_exit); |