patch-2.3.25 linux/include/asm-arm/io.h

Next file: linux/include/asm-arm/page.h
Previous file: linux/include/asm-arm/arch-sa1100/memory.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.24/linux/include/asm-arm/io.h linux/include/asm-arm/io.h
@@ -185,17 +185,16 @@
 
 #endif
 
-#ifndef ARCH_READWRITE
+extern void __readwrite_bug(const char *fn);
 
-/* for panic */
-#include <linux/kernel.h>
+#ifndef ARCH_READWRITE
 
-#define readb(p)	(panic("readb called, but not implemented"),0)
-#define readw(p)	(panic("readw called, but not implemented"),0)
-#define readl(p)	(panic("readl called, but not implemented"),0)
-#define writeb(v,p)	panic("writeb called, but not implemented")
-#define writew(v,p)	panic("writew called, but not implemented")
-#define writel(v,p)	panic("writel called, but not implemented")
+#define readb(p)	(__readwrite_bug("readb"),0)
+#define readw(p)	(__readwrite_bug("readw"),0)
+#define readl(p)	(__readwrite_bug("readl"),0)
+#define writeb(v,p)	__readwrite_bug("writeb")
+#define writew(v,p)	__readwrite_bug("writew")
+#define writel(v,p)	__readwrite_bug("writel")
 
 #endif
 

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