diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2008-10-14 20:31:54 -0400 |
---|---|---|
committer | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2008-10-14 20:31:54 -0400 |
commit | 6dc6472581f693b5fc95aebedf67b4960fb85cf0 (patch) | |
tree | 06a5a9a08519950575505273eabced331ed51405 /arch/powerpc/include/asm/sections.h | |
parent | ee673eaa72d8d185012b1027a05e25aba18c267f (diff) | |
parent | 8acd3a60bcca17c6d89c73cee3ad6057eb83ba1e (diff) |
Merge commit 'origin'
Manual fixup of conflicts on:
arch/powerpc/include/asm/dcr-regs.h
drivers/net/ibm_newemac/core.h
Diffstat (limited to 'arch/powerpc/include/asm/sections.h')
-rw-r--r-- | arch/powerpc/include/asm/sections.h | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/arch/powerpc/include/asm/sections.h b/arch/powerpc/include/asm/sections.h index baf318aec533..6fbce725c710 100644 --- a/arch/powerpc/include/asm/sections.h +++ b/arch/powerpc/include/asm/sections.h | |||
@@ -2,6 +2,8 @@ | |||
2 | #define _ASM_POWERPC_SECTIONS_H | 2 | #define _ASM_POWERPC_SECTIONS_H |
3 | #ifdef __KERNEL__ | 3 | #ifdef __KERNEL__ |
4 | 4 | ||
5 | #include <linux/elf.h> | ||
6 | #include <linux/uaccess.h> | ||
5 | #include <asm-generic/sections.h> | 7 | #include <asm-generic/sections.h> |
6 | 8 | ||
7 | #ifdef __powerpc64__ | 9 | #ifdef __powerpc64__ |
@@ -23,7 +25,15 @@ static inline int overlaps_kernel_text(unsigned long start, unsigned long end) | |||
23 | } | 25 | } |
24 | 26 | ||
25 | #undef dereference_function_descriptor | 27 | #undef dereference_function_descriptor |
26 | void *dereference_function_descriptor(void *); | 28 | static inline void *dereference_function_descriptor(void *ptr) |
29 | { | ||
30 | struct ppc64_opd_entry *desc = ptr; | ||
31 | void *p; | ||
32 | |||
33 | if (!probe_kernel_address(&desc->funcaddr, p)) | ||
34 | ptr = p; | ||
35 | return ptr; | ||
36 | } | ||
27 | 37 | ||
28 | #endif | 38 | #endif |
29 | 39 | ||