Commit 28e52c66 authored by Igor Popik's avatar Igor Popik Committed by Greg Kroah-Hartman

[PATCH] i82365: release all resources if no devices are found

The i82365 driver does not release all the resources when the device is not
found. This can cause an oops when reading /proc/ioports after module
unload (e.g. bug #5657).
Signed-off-by: default avatarIgor Popik <igor.popik@gmail.com>
Signed-off-by: default avatarDominik Brodowski <linux@dominikbrodowski.net>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent ab2d3d36
......@@ -1382,6 +1382,7 @@ static int __init init_i82365(void)
if (sockets == 0) {
printk("not found.\n");
platform_device_unregister(&i82365_device);
release_region(i365_base, 2);
driver_unregister(&i82365_driver);
return -ENODEV;
}
......
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