diff options
| -rw-r--r-- | include/asm-sparc/types.h | 32 | ||||
| -rw-r--r-- | include/asm-sparc64/types.h | 35 |
2 files changed, 32 insertions, 35 deletions
diff --git a/include/asm-sparc/types.h b/include/asm-sparc/types.h index 07734f942405..8c28fde5eaa2 100644 --- a/include/asm-sparc/types.h +++ b/include/asm-sparc/types.h | |||
| @@ -1,6 +1,5 @@ | |||
| 1 | #ifndef _SPARC_TYPES_H | 1 | #ifndef _SPARC_TYPES_H |
| 2 | #define _SPARC_TYPES_H | 2 | #define _SPARC_TYPES_H |
| 3 | |||
| 4 | /* | 3 | /* |
| 5 | * This file is never included by application software unless | 4 | * This file is never included by application software unless |
| 6 | * explicitly requested (e.g., via linux/types.h) in which case the | 5 | * explicitly requested (e.g., via linux/types.h) in which case the |
| @@ -8,6 +7,35 @@ | |||
| 8 | * not a major issue. However, for interoperability, libraries still | 7 | * not a major issue. However, for interoperability, libraries still |
| 9 | * need to be careful to avoid a name clashes. | 8 | * need to be careful to avoid a name clashes. |
| 10 | */ | 9 | */ |
| 10 | |||
| 11 | #if defined(__sparc__) && defined(__arch64__) | ||
| 12 | |||
| 13 | /*** SPARC 64 bit ***/ | ||
| 14 | #include <asm-generic/int-l64.h> | ||
| 15 | |||
| 16 | #ifndef __ASSEMBLY__ | ||
| 17 | |||
| 18 | typedef unsigned short umode_t; | ||
| 19 | |||
| 20 | #endif /* __ASSEMBLY__ */ | ||
| 21 | |||
| 22 | #ifdef __KERNEL__ | ||
| 23 | |||
| 24 | #define BITS_PER_LONG 64 | ||
| 25 | |||
| 26 | #ifndef __ASSEMBLY__ | ||
| 27 | |||
| 28 | /* Dma addresses come in generic and 64-bit flavours. */ | ||
| 29 | |||
| 30 | typedef u32 dma_addr_t; | ||
| 31 | typedef u64 dma64_addr_t; | ||
| 32 | |||
| 33 | #endif /* __ASSEMBLY__ */ | ||
| 34 | |||
| 35 | #endif /* __KERNEL__ */ | ||
| 36 | #else | ||
| 37 | |||
| 38 | /*** SPARC 32 bit ***/ | ||
| 11 | #include <asm-generic/int-ll64.h> | 39 | #include <asm-generic/int-ll64.h> |
| 12 | 40 | ||
| 13 | #ifndef __ASSEMBLY__ | 41 | #ifndef __ASSEMBLY__ |
| @@ -29,4 +57,6 @@ typedef u32 dma64_addr_t; | |||
| 29 | 57 | ||
| 30 | #endif /* __KERNEL__ */ | 58 | #endif /* __KERNEL__ */ |
| 31 | 59 | ||
| 60 | #endif /* defined(__sparc__) && defined(__arch64__) */ | ||
| 61 | |||
| 32 | #endif /* defined(_SPARC_TYPES_H) */ | 62 | #endif /* defined(_SPARC_TYPES_H) */ |
diff --git a/include/asm-sparc64/types.h b/include/asm-sparc64/types.h index b27ccc85202f..cfbfad5043eb 100644 --- a/include/asm-sparc64/types.h +++ b/include/asm-sparc64/types.h | |||
| @@ -1,34 +1 @@ | |||
| 1 | #ifndef _SPARC64_TYPES_H | #include <asm-sparc/types.h> | |
| 2 | #define _SPARC64_TYPES_H | ||
| 3 | |||
| 4 | /* | ||
| 5 | * This file is never included by application software unless | ||
| 6 | * explicitly requested (e.g., via linux/types.h) in which case the | ||
| 7 | * application is Linux specific so (user-) name space pollution is | ||
| 8 | * not a major issue. However, for interoperability, libraries still | ||
| 9 | * need to be careful to avoid a name clashes. | ||
| 10 | */ | ||
| 11 | #include <asm-generic/int-l64.h> | ||
| 12 | |||
| 13 | #ifndef __ASSEMBLY__ | ||
| 14 | |||
| 15 | typedef unsigned short umode_t; | ||
| 16 | |||
| 17 | #endif /* __ASSEMBLY__ */ | ||
| 18 | |||
| 19 | #ifdef __KERNEL__ | ||
| 20 | |||
| 21 | #define BITS_PER_LONG 64 | ||
| 22 | |||
| 23 | #ifndef __ASSEMBLY__ | ||
| 24 | |||
| 25 | /* Dma addresses come in generic and 64-bit flavours. */ | ||
| 26 | |||
| 27 | typedef u32 dma_addr_t; | ||
| 28 | typedef u64 dma64_addr_t; | ||
| 29 | |||
| 30 | #endif /* __ASSEMBLY__ */ | ||
| 31 | |||
| 32 | #endif /* __KERNEL__ */ | ||
| 33 | |||
| 34 | #endif /* defined(_SPARC64_TYPES_H) */ | ||
