Skip to content

Commit

Permalink
[PCMCIA] i82365: release all resources if no devices are found
Browse files Browse the repository at this point in the history
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.

Signed-off-by: Igor Popik <igor.popik@gmail.com>
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
  • Loading branch information
Igor Popik authored and Dominik Brodowski committed Nov 10, 2005
1 parent e346315 commit a2932b3
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/pcmcia/i82365.c
Original file line number Diff line number Diff line change
Expand Up @@ -1366,6 +1366,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;
}
Expand Down

0 comments on commit a2932b3

Please sign in to comment.