aboutsummaryrefslogtreecommitdiff
path: root/arch/s390/include/asm/types.h
diff options
context:
space:
mode:
authorMartin Schwidefsky <schwidefsky@de.ibm.com>2008-08-01 20:42:05 +0200
committerMartin Schwidefsky <schwidefsky@de.ibm.com>2008-08-01 20:42:05 +0200
commitc6557e7f2b6ae76a44653d38f835174074c42e05 (patch)
treeda619a76b309cb1cd259d082af768a83cfcd6d52 /arch/s390/include/asm/types.h
parentab4227cb2d936886069ef1056c02500d05beb15d (diff)
[S390] move include/asm-s390 to arch/s390/include/asm
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'arch/s390/include/asm/types.h')
-rw-r--r--arch/s390/include/asm/types.h63
1 files changed, 63 insertions, 0 deletions
diff --git a/arch/s390/include/asm/types.h b/arch/s390/include/asm/types.h
new file mode 100644
index 00000000000..41c54765613
--- /dev/null
+++ b/arch/s390/include/asm/types.h
@@ -0,0 +1,63 @@
+/*
+ * include/asm-s390/types.h
+ *
+ * S390 version
+ *
+ * Derived from "include/asm-i386/types.h"
+ */
+
+#ifndef _S390_TYPES_H
+#define _S390_TYPES_H
+
+#ifndef __s390x__
+# include <asm-generic/int-ll64.h>
+#else
+# include <asm-generic/int-l64.h>
+#endif
+
+#ifndef __ASSEMBLY__
+
+typedef unsigned short umode_t;
+
+/* A address type so that arithmetic can be done on it & it can be upgraded to
+ 64 bit when necessary
+*/
+typedef unsigned long addr_t;
+typedef __signed__ long saddr_t;
+
+#endif /* __ASSEMBLY__ */
+
+/*
+ * These aren't exported outside the kernel to avoid name space clashes
+ */
+#ifdef __KERNEL__
+
+#ifndef __s390x__
+#define BITS_PER_LONG 32
+#else
+#define BITS_PER_LONG 64
+#endif
+
+#ifndef __ASSEMBLY__
+
+typedef u64 dma64_addr_t;
+#ifdef __s390x__
+/* DMA addresses come in 32-bit and 64-bit flavours. */
+typedef u64 dma_addr_t;
+#else
+typedef u32 dma_addr_t;
+#endif
+
+#ifndef __s390x__
+typedef union {
+ unsigned long long pair;
+ struct {
+ unsigned long even;
+ unsigned long odd;
+ } subreg;
+} register_pair;
+
+#endif /* ! __s390x__ */
+#endif /* __ASSEMBLY__ */
+#endif /* __KERNEL__ */
+#endif /* _S390_TYPES_H */