patch-2.4.20 linux-2.4.20/arch/x86_64/lib/iodebug.c

Next file: linux-2.4.20/arch/x86_64/lib/memcpy.S
Previous file: linux-2.4.20/arch/x86_64/lib/io.c
Back to the patch index
Back to the overall index

diff -urN linux-2.4.19/arch/x86_64/lib/iodebug.c linux-2.4.20/arch/x86_64/lib/iodebug.c
@@ -0,0 +1,19 @@
+#include <asm/io.h>
+
+void * __io_virt_debug(unsigned long x, const char *file, int line)
+{
+	if (x < PAGE_OFFSET) {
+		printk("io mapaddr 0x%05lx not valid at %s:%d!\n", x, file, line);
+		return __va(x);
+	}
+	return (void *)x;
+}
+
+unsigned long __io_phys_debug(unsigned long x, const char *file, int line)
+{
+	if (x < PAGE_OFFSET) {
+		printk("io mapaddr 0x%05lx not valid at %s:%d!\n", x, file, line);
+		return x;
+	}
+	return __pa(x);
+}

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)