OSDN Git Service

powerpc: Fix ABIv2 issue with dereference_function_descriptor
authorAnton Blanchard <anton@samba.org>
Tue, 11 Mar 2014 01:15:27 +0000 (12:15 +1100)
committerAnton Blanchard <anton@samba.org>
Wed, 23 Apr 2014 00:05:26 +0000 (10:05 +1000)
Don't try and dereference a function descriptor on ABIv2.

Signed-off-by: Anton Blanchard <anton@samba.org>
arch/powerpc/include/asm/sections.h

index d0e784e..d1bb96d 100644 (file)
@@ -39,6 +39,7 @@ static inline int overlaps_kernel_text(unsigned long start, unsigned long end)
                (unsigned long)_stext < end;
 }
 
+#if !defined(_CALL_ELF) || _CALL_ELF != 2
 #undef dereference_function_descriptor
 static inline void *dereference_function_descriptor(void *ptr)
 {
@@ -49,6 +50,7 @@ static inline void *dereference_function_descriptor(void *ptr)
                ptr = p;
        return ptr;
 }
+#endif
 
 #endif