diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-07-28 11:41:13 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-07-28 11:41:13 -0400 |
commit | b10a8b7238d7b034f28d32a85bb05c48475f132a (patch) | |
tree | 8e70e816757c2a517de6fb721dd9ac2276619c26 /include/asm-sh/segment.h | |
parent | 37eaf8c7463e53cf1acf025fb566fb6c4573297f (diff) | |
parent | 8b2224dc6a5b46cfa1d54ab1fe82107351c66443 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6: (72 commits)
sh: SuperH Mobile CEU and camera platform data for AP325RXA
sh: Update smc911x platform data for AP325RXA
sh: SuperH Mobile LCDC platform data for AP325RXA
sh: Add SuperH Mobile CEU platform data for Migo-R
sh: Add SuperH Mobile LCDC platform data for Migo-R
sh: Move asid_cache() out of ifdef to fix SH-3/4 nommu build.
sh: Workaround for __put_user_asm() bug with gcc 4.x on big-endian.
sh: Wire up new syscalls.
sh: fix uImage Entry Point
sh_keysc: remove request_mem_region() and release_mem_region()
sh: Don't miss pending signals returning to user mode after signal processing
sh: Use clk_always_enable() on sh7366
sh: Use clk_always_enable() on sh7343 / SE77343
sh: Use clk_always_enable() on sh7722 / Migo-R / SE7722
sh: Use clk_always_enable() on sh7723 / ap325rxa
sh: Introduce clk_always_enable() function
sh: Show all clocks and their state in /proc/clocks
sh: Merge sh7343 and sh7722 clock code
sh: Add SuperH Mobile MSTPCR bits to clock framework
sh: Use arch_flags to simplify sh7722 siu clock code
...
Diffstat (limited to 'include/asm-sh/segment.h')
-rw-r--r-- | include/asm-sh/segment.h | 30 |
1 files changed, 29 insertions, 1 deletions
diff --git a/include/asm-sh/segment.h b/include/asm-sh/segment.h index e417eab4c7d7..5e2725f4ac49 100644 --- a/include/asm-sh/segment.h +++ b/include/asm-sh/segment.h | |||
@@ -1,6 +1,34 @@ | |||
1 | #ifndef __ASM_SH_SEGMENT_H | 1 | #ifndef __ASM_SH_SEGMENT_H |
2 | #define __ASM_SH_SEGMENT_H | 2 | #define __ASM_SH_SEGMENT_H |
3 | 3 | ||
4 | /* Only here because we have some old header files that expect it.. */ | 4 | #ifndef __ASSEMBLY__ |
5 | 5 | ||
6 | typedef struct { | ||
7 | unsigned long seg; | ||
8 | } mm_segment_t; | ||
9 | |||
10 | #define MAKE_MM_SEG(s) ((mm_segment_t) { (s) }) | ||
11 | |||
12 | /* | ||
13 | * The fs value determines whether argument validity checking should be | ||
14 | * performed or not. If get_fs() == USER_DS, checking is performed, with | ||
15 | * get_fs() == KERNEL_DS, checking is bypassed. | ||
16 | * | ||
17 | * For historical reasons, these macros are grossly misnamed. | ||
18 | */ | ||
19 | #define KERNEL_DS MAKE_MM_SEG(0xFFFFFFFFUL) | ||
20 | #ifdef CONFIG_MMU | ||
21 | #define USER_DS MAKE_MM_SEG(PAGE_OFFSET) | ||
22 | #else | ||
23 | #define USER_DS KERNEL_DS | ||
24 | #endif | ||
25 | |||
26 | #define segment_eq(a,b) ((a).seg == (b).seg) | ||
27 | |||
28 | #define get_ds() (KERNEL_DS) | ||
29 | |||
30 | #define get_fs() (current_thread_info()->addr_limit) | ||
31 | #define set_fs(x) (current_thread_info()->addr_limit = (x)) | ||
32 | |||
33 | #endif /* __ASSEMBLY__ */ | ||
6 | #endif /* __ASM_SH_SEGMENT_H */ | 34 | #endif /* __ASM_SH_SEGMENT_H */ |