Change isp16 from check_region to request_region.
diff -Nru a/drivers/cdrom/isp16.c b/drivers/cdrom/isp16.c
--- a/drivers/cdrom/isp16.c Mon Sep 22 15:33:46 2003
+++ b/drivers/cdrom/isp16.c Mon Sep 22 15:33:46 2003
@@ -121,14 +121,14 @@
return (0);
}
- if (check_region(ISP16_IO_BASE, ISP16_IO_SIZE)) {
+ if (!request_region(ISP16_IO_BASE, ISP16_IO_SIZE, "isp16")) {
printk("ISP16: i/o ports already in use.\n");
- return (-EIO);
+ goto ret_eio;
}
if ((isp16_type = isp16_detect()) < 0) {
printk("ISP16: no cdrom interface found.\n");
- return (-EIO);
+ goto err;
}
printk(KERN_INFO
@@ -148,20 +148,24 @@
else {
printk("ISP16: %s not supported by cdrom interface.\n",
isp16_cdrom_type);
- return (-EIO);
+ goto err;
}
if (isp16_cdi_config(isp16_cdrom_base, expected_drive,
isp16_cdrom_irq, isp16_cdrom_dma) < 0) {
printk
("ISP16: cdrom interface has not been properly configured.\n");
- return (-EIO);
+ goto err;
}
printk(KERN_INFO
"ISP16: cdrom interface set up with io base 0x%03X, irq %d, dma %d,"
" type %s.\n", isp16_cdrom_base, isp16_cdrom_irq,
isp16_cdrom_dma, isp16_cdrom_type);
return (0);
+ err:
+ release_region(ISP16_IO_BASE, ISP16_IO_SIZE);
+ ret_eio:
+ return (-EIO);
}
static short __init isp16_detect(void)