aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/lib/feature-fixups.c
diff options
context:
space:
mode:
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>2010-02-26 02:29:17 -0500
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2010-02-26 02:29:17 -0500
commit3d98ffbffb16f2a1569b83cb78db0b5100e6c937 (patch)
tree3604899600b8ce7c95d67b9299e1fb6b91005773 /arch/powerpc/lib/feature-fixups.c
parent874f2f997dbe041a6c6e509dae8656ed9022d65d (diff)
powerpc: Fix lwsync feature fixup vs. modules on 64-bit
Anton's commit enabling the use of the lwsync fixup mechanism on 64-bit breaks modules. The lwsync fixup section uses .long instead of the FTR_ENTRY_OFFSET macro used by other fixups sections, and thus will generate 32-bit relocations that our module loader cannot resolve. This changes it to use the same type as other feature sections. Note however that we might want to consider using 32-bit for all the feature fixup offsets and add support for R_PPC_REL32 to module_64.c instead as that would reduce the size of the kernel image. I'll leave that as an exercise for the reader for now... Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/lib/feature-fixups.c')
-rw-r--r--arch/powerpc/lib/feature-fixups.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/powerpc/lib/feature-fixups.c b/arch/powerpc/lib/feature-fixups.c
index 4dee652dfca..e640175b65a 100644
--- a/arch/powerpc/lib/feature-fixups.c
+++ b/arch/powerpc/lib/feature-fixups.c
@@ -112,7 +112,8 @@ void do_feature_fixups(unsigned long value, void *fixup_start, void *fixup_end)
112 112
113void do_lwsync_fixups(unsigned long value, void *fixup_start, void *fixup_end) 113void do_lwsync_fixups(unsigned long value, void *fixup_start, void *fixup_end)
114{ 114{
115 int *start, *end, *dest; 115 long *start, *end;
116 unsigned int *dest;
116 117
117 if (!(value & CPU_FTR_LWSYNC)) 118 if (!(value & CPU_FTR_LWSYNC))
118 return ; 119 return ;