patch-2.1.106 linux/include/asm-arm/arch-ebsa285/io.h
Next file: linux/include/asm-arm/arch-ebsa285/processor.h
Previous file: linux/include/asm-arm/arch-ebsa110/mmap.h
Back to the patch index
Back to the overall index
- Lines: 27
- Date:
Sat Jun 13 13:11:12 1998
- Orig file:
v2.1.105/linux/include/asm-arm/arch-ebsa285/io.h
- Orig date:
Tue Apr 14 14:29:25 1998
diff -u --recursive --new-file v2.1.105/linux/include/asm-arm/arch-ebsa285/io.h linux/include/asm-arm/arch-ebsa285/io.h
@@ -140,4 +140,26 @@
#define inl_t(p) \
(*(volatile unsigned long *)(p))
+/*
+ * This is not sufficient... (and it's a hack anyway)
+ */
+static inline void writeb(unsigned char b, unsigned int addr)
+{
+ *(volatile unsigned char *)(0xe0000000 + (addr)) = b;
+}
+
+static inline unsigned char readb(unsigned int addr)
+{
+ return *(volatile unsigned char *)(0xe0000000 + (addr));
+}
+
+static inline void writew(unsigned short b, unsigned int addr)
+{
+ *(volatile unsigned short *)(0xe0000000 + (addr)) = b;
+}
+
+static inline unsigned short readw(unsigned int addr)
+{
+ return *(volatile unsigned short *)(0xe0000000 + (addr));
+}
#endif
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov