mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-04 09:34:12 +08:00
acer-wmi: remove debugfs entries upon unloading
The exit function neglects to remove debugfs entries, leading to a BUG on reload. [akpm@linux-foundation.org: cleanups] Signed-off-by: Russ Dill <Russ.Dill@gmail.com> Acked-by: Carlos Corbacho <carlos@strangeworlds.co.uk> Cc: Andi Kleen <ak@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Andi Kleen <ak@linux.intel.com>
This commit is contained in:
parent
b635acec48
commit
7d964c352b
@ -1167,7 +1167,7 @@ static int create_debugfs(void)
|
|||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
error_debugfs:
|
error_debugfs:
|
||||||
remove_debugfs();
|
remove_debugfs();
|
||||||
return -ENOMEM;
|
return -ENOMEM;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1248,6 +1248,7 @@ error_platform_register:
|
|||||||
static void __exit acer_wmi_exit(void)
|
static void __exit acer_wmi_exit(void)
|
||||||
{
|
{
|
||||||
remove_sysfs(acer_platform_device);
|
remove_sysfs(acer_platform_device);
|
||||||
|
remove_debugfs();
|
||||||
platform_device_del(acer_platform_device);
|
platform_device_del(acer_platform_device);
|
||||||
platform_driver_unregister(&acer_platform_driver);
|
platform_driver_unregister(&acer_platform_driver);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user