[PATCH] drivers/cdrom/isp16.c check_region() fix

From: Omkhar Arasaratnam
Date: Mon Dec 29 2003 - 14:50:11 EST


check_region is depreciated in 2.6, this replaces it with request_region

As this is my first patch to the kernel, please let me know if I did anything wrong


--- /usr/src/linux/drivers/cdrom/isp16.c 2001-09-07 12:28:38.000000000 -0400
+++ drivers/cdrom/isp16.c 2003-12-29 14:07:24.000000000 -0500
@@ -121,11 +121,12 @@
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);
}
-
+ release_region(ISP16_IO_BASE, ISP16_IO_SIZE);
+
if ((isp16_type = isp16_detect()) < 0) {
printk("ISP16: no cdrom interface found.\n");
return (-EIO);

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/