mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-04 21:31:51 +00:00
Drivers: hv: vmbus: Fix the issue with freeing up hv_ctl_table_hdr
The check to free the Hyper-V control table header was reversed. This
fixes it.
Fixes: 81b18bce48
("Drivers: HV: Send one page worth of kmsg dump over Hyper-V during panic")
Signed-off-by: Sunil Muthuswamy <sunilmut@microsoft.com>
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
ddcaf3ca4c
commit
8afc06dd75
1 changed files with 4 additions and 10 deletions
|
@ -1176,11 +1176,8 @@ err_alloc:
|
||||||
|
|
||||||
bus_unregister(&hv_bus);
|
bus_unregister(&hv_bus);
|
||||||
free_page((unsigned long)hv_panic_page);
|
free_page((unsigned long)hv_panic_page);
|
||||||
if (!hv_ctl_table_hdr) {
|
|
||||||
unregister_sysctl_table(hv_ctl_table_hdr);
|
unregister_sysctl_table(hv_ctl_table_hdr);
|
||||||
hv_ctl_table_hdr = NULL;
|
hv_ctl_table_hdr = NULL;
|
||||||
}
|
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1891,11 +1888,8 @@ static void __exit vmbus_exit(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
free_page((unsigned long)hv_panic_page);
|
free_page((unsigned long)hv_panic_page);
|
||||||
if (!hv_ctl_table_hdr) {
|
|
||||||
unregister_sysctl_table(hv_ctl_table_hdr);
|
unregister_sysctl_table(hv_ctl_table_hdr);
|
||||||
hv_ctl_table_hdr = NULL;
|
hv_ctl_table_hdr = NULL;
|
||||||
}
|
|
||||||
|
|
||||||
bus_unregister(&hv_bus);
|
bus_unregister(&hv_bus);
|
||||||
|
|
||||||
cpuhp_remove_state(hyperv_cpuhp_online);
|
cpuhp_remove_state(hyperv_cpuhp_online);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue