diff options
author | Vitaly Kuznetsov <vkuznets@redhat.com> | 2015-02-27 22:25:57 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-03-02 06:30:07 +0300 |
commit | e086748c655ab99bac91b87d1bb59d9cc45867b9 (patch) | |
tree | 004fda805ee1c6124bcd275357ccafed6c786ad5 /drivers/hv/hyperv_vmbus.h | |
parent | 32a158325acf12842764b1681f53903673f2f22e (diff) | |
download | linux-e086748c655ab99bac91b87d1bb59d9cc45867b9.tar.xz |
Drivers: hv: vmbus: Teardown clockevent devices on module unload
Newly introduced clockevent devices made it impossible to unload hv_vmbus
module as clockevents_config_and_register() takes additional reverence to
the module. To make it possible again we do the following:
- avoid setting dev->owner for clockevent devices;
- implement hv_synic_clockevents_cleanup() doing clockevents_unbind_device();
- call it from vmbus_exit().
In theory hv_synic_clockevents_cleanup() can be merged with hv_synic_cleanup(),
however, we call hv_synic_cleanup() from smp_call_function_single() and this
doesn't work for clockevents_unbind_device() as it does such call on its own. I
opted for a separate function.
Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/hv/hyperv_vmbus.h')
-rw-r--r-- | drivers/hv/hyperv_vmbus.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/hv/hyperv_vmbus.h b/drivers/hv/hyperv_vmbus.h index 6cf2de9f487a..b055e53bbc6e 100644 --- a/drivers/hv/hyperv_vmbus.h +++ b/drivers/hv/hyperv_vmbus.h @@ -572,6 +572,8 @@ extern void hv_synic_init(void *irqarg); extern void hv_synic_cleanup(void *arg); +extern void hv_synic_clockevents_cleanup(void); + /* * Host version information. */ |