diff options
author | Paul Mundt <lethal@linux-sh.org> | 2008-03-21 05:08:58 -0400 |
---|---|---|
committer | Paul Mundt <lethal@linux-sh.org> | 2008-04-18 12:50:02 -0400 |
commit | 9460c0ce9b29825d279081d5078815a32c268ada (patch) | |
tree | 6881ce0126df1172856efaa582bd91e21fda1fc9 /include/asm-sh/uaccess_32.h | |
parent | 5c0cbd74bb56aeb7f3de883ab79c5f501622ccb1 (diff) |
sh: Fix up __access_ok() check for nommu.
Presently this only checks to see if an address is an RAM, but this
doesn't work with XIP, so just always return 1. Follows m68knommu.
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'include/asm-sh/uaccess_32.h')
-rw-r--r-- | include/asm-sh/uaccess_32.h | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/include/asm-sh/uaccess_32.h b/include/asm-sh/uaccess_32.h index c0318b608893..1e41fda74bd3 100644 --- a/include/asm-sh/uaccess_32.h +++ b/include/asm-sh/uaccess_32.h | |||
@@ -55,13 +55,10 @@ static inline void set_fs(mm_segment_t s) | |||
55 | * If we don't have an MMU (or if its disabled) the only thing we really have | 55 | * If we don't have an MMU (or if its disabled) the only thing we really have |
56 | * to look out for is if the address resides somewhere outside of what | 56 | * to look out for is if the address resides somewhere outside of what |
57 | * available RAM we have. | 57 | * available RAM we have. |
58 | * | ||
59 | * TODO: This check could probably also stand to be restricted somewhat more.. | ||
60 | * though it still does the Right Thing(tm) for the time being. | ||
61 | */ | 58 | */ |
62 | static inline int __access_ok(unsigned long addr, unsigned long size) | 59 | static inline int __access_ok(unsigned long addr, unsigned long size) |
63 | { | 60 | { |
64 | return ((addr >= memory_start) && ((addr + size) < memory_end)); | 61 | return 1; |
65 | } | 62 | } |
66 | #else /* CONFIG_MMU */ | 63 | #else /* CONFIG_MMU */ |
67 | #define __addr_ok(addr) \ | 64 | #define __addr_ok(addr) \ |