diff options
author | Ingo Molnar <mingo@elte.hu> | 2008-06-19 07:28:11 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-06-19 07:33:11 -0400 |
commit | 7aa413def76146f7b3784228556d9e4bc562eab3 (patch) | |
tree | a90291b6fd72f46f33bc5af07813784c0468d23d | |
parent | a1bf9631be7332ce0641e299ddafad2d8223100f (diff) |
x86, MM: virtual address debug, cleanups
Signed-off-by: Ingo Molnar <mingo@elte.hu>
-rw-r--r-- | include/linux/mmdebug.h | 4 | ||||
-rw-r--r-- | mm/vmalloc.c | 6 |
2 files changed, 6 insertions, 4 deletions
diff --git a/include/linux/mmdebug.h b/include/linux/mmdebug.h index 860ed1a71bbe..8a5509877192 100644 --- a/include/linux/mmdebug.h +++ b/include/linux/mmdebug.h | |||
@@ -6,13 +6,13 @@ | |||
6 | #ifdef CONFIG_DEBUG_VM | 6 | #ifdef CONFIG_DEBUG_VM |
7 | #define VM_BUG_ON(cond) BUG_ON(cond) | 7 | #define VM_BUG_ON(cond) BUG_ON(cond) |
8 | #else | 8 | #else |
9 | #define VM_BUG_ON(cond) do { } while(0) | 9 | #define VM_BUG_ON(cond) do { } while (0) |
10 | #endif | 10 | #endif |
11 | 11 | ||
12 | #ifdef CONFIG_DEBUG_VIRTUAL | 12 | #ifdef CONFIG_DEBUG_VIRTUAL |
13 | #define VIRTUAL_BUG_ON(cond) BUG_ON(cond) | 13 | #define VIRTUAL_BUG_ON(cond) BUG_ON(cond) |
14 | #else | 14 | #else |
15 | #define VIRTUAL_BUG_ON(cond) do { } while(0) | 15 | #define VIRTUAL_BUG_ON(cond) do { } while (0) |
16 | #endif | 16 | #endif |
17 | 17 | ||
18 | #endif | 18 | #endif |
diff --git a/mm/vmalloc.c b/mm/vmalloc.c index dc41e9c8ca6f..830a5580c5d7 100644 --- a/mm/vmalloc.c +++ b/mm/vmalloc.c | |||
@@ -180,8 +180,10 @@ struct page *vmalloc_to_page(const void *vmalloc_addr) | |||
180 | pmd_t *pmd; | 180 | pmd_t *pmd; |
181 | pte_t *ptep, pte; | 181 | pte_t *ptep, pte; |
182 | 182 | ||
183 | /* XXX we might need to change this if we add VIRTUAL_BUG_ON for | 183 | /* |
184 | * architectures that do not vmalloc module space */ | 184 | * XXX we might need to change this if we add VIRTUAL_BUG_ON for |
185 | * architectures that do not vmalloc module space | ||
186 | */ | ||
185 | VIRTUAL_BUG_ON(!is_vmalloc_addr(vmalloc_addr) && | 187 | VIRTUAL_BUG_ON(!is_vmalloc_addr(vmalloc_addr) && |
186 | !is_module_address(addr)); | 188 | !is_module_address(addr)); |
187 | 189 | ||