diff options
author | David S. Miller <davem@davemloft.net> | 2017-06-19 11:13:13 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-06-19 11:13:13 -0700 |
commit | d8f431a0de4099c80fe38d65432853682c05d67b (patch) | |
tree | c5b85ee17fcc6d70940393316a23045ab4c387e1 /arch/sparc | |
parent | 5faab9e0f03c4eef97886b45436015e107f79f5f (diff) | |
parent | f5a651f1d5e524cab345250a783702fb6a3f14d6 (diff) | |
download | op-kernel-dev-d8f431a0de4099c80fe38d65432853682c05d67b.zip op-kernel-dev-d8f431a0de4099c80fe38d65432853682c05d67b.tar.gz |
Merge branch 'sparc-Suppressing-version-generation-failed-warnings-in-sparc'
Nagarathnam Muthusamy says:
====================
sparc: Suppressing version generation failed warnings in sparc
Compiling the sparc build of upstream kernel generates lots of warnings
regarding version generation failure for functions defined in assembly files.
This can be easily suppressed by adding those function prototypes to
asm/asm-prototypes.h as in powerpc architecture. The following series of patches
aims to clean the following warnings.
WARNING: EXPORT symbol "atomic_add" [vmlinux] version generation failed, symbol will
not be versioned.
WARNING: EXPORT symbol "xor_niagara_4" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "atomic_sub_return" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "atomic64_sub" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "xor_vis_3" [vmlinux] version generation failed, symbol will
not be versioned.
WARNING: EXPORT symbol "atomic_xor" [vmlinux] version generation failed, symbol will
not be versioned.
WARNING: EXPORT symbol "_mcount" [vmlinux] version generation failed, symbol will not
be versioned.
WARNING: EXPORT symbol "sun4v_niagara2_getperf" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "atomic64_fetch_xor" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "atomic_fetch_xor" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "__bzero" [vmlinux] version generation failed, symbol will not
be versioned.
WARNING: EXPORT symbol "atomic64_fetch_and" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "raw_copy_to_user" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "__flushw_user" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "sun4v_niagara2_setperf" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "__arch_hweight64" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "__ffs" [vmlinux] version generation failed, symbol will not
be versioned.
WARNING: EXPORT symbol "prom_root_node" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "csum_partial_copy_nocheck" [vmlinux] version generation
failed, symbol will not be versioned.
WARNING: EXPORT symbol "memcpy" [vmlinux] version generation failed, symbol will not
be versioned.
WARNING: EXPORT symbol "atomic_fetch_or" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "xor_vis_4" [vmlinux] version generation failed, symbol will
not be versioned.
WARNING: EXPORT symbol "__arch_hweight32" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "ffs" [vmlinux] version generation failed, symbol will not be
versioned.
WARNING: EXPORT symbol "atomic_and" [vmlinux] version generation failed, symbol will
not be versioned.
WARNING: EXPORT symbol "xor_niagara_3" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "atomic64_and" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "real_hard_smp_processor_id" [vmlinux] version generation
failed, symbol will not be versioned.
WARNING: EXPORT symbol "clear_user_page" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "memmove" [vmlinux] version generation failed, symbol will not
be versioned.
WARNING: EXPORT symbol "raw_copy_from_user" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "atomic64_add_return" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "__memscan_generic" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "atomic_sub" [vmlinux] version generation failed, symbol will
not be versioned.
WARNING: EXPORT symbol "__memscan_zero" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "atomic64_add" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "strncmp" [vmlinux] version generation failed, symbol will not
be versioned.
WARNING: EXPORT symbol "atomic64_fetch_sub" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "xor_vis_5" [vmlinux] version generation failed, symbol will
not be versioned.
WARNING: EXPORT symbol "ip_fast_csum" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "test_and_change_bit" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "__arch_hweight8" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "strlen" [vmlinux] version generation failed, symbol will not
be versioned.
WARNING: EXPORT symbol "xor_niagara_2" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "atomic64_fetch_or" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "atomic64_or" [vmlinux] version generation failed, symbol will
not be versioned.
WARNING: EXPORT symbol "atomic_fetch_sub" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "atomic_fetch_add" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "clear_bit" [vmlinux] version generation failed, symbol will
not be versioned.
WARNING: EXPORT symbol "sun4v_mach_set_watchdog" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "set_bit" [vmlinux] version generation failed, symbol will not
be versioned.
WARNING: EXPORT symbol "__csum_partial_copy_from_user" [vmlinux] version generation
failed, symbol will not be versioned.
WARNING: EXPORT symbol "memset" [vmlinux] version generation failed, symbol will not
be versioned.
WARNING: EXPORT symbol "__csum_partial_copy_to_user" [vmlinux] version generation
failed, symbol will not be versioned.
WARNING: EXPORT symbol "atomic64_fetch_add" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "change_bit" [vmlinux] version generation failed, symbol will
not be versioned.
WARNING: EXPORT symbol "__clear_user" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "atomic64_sub_return" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "__arch_hweight16" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "tlb_type" [vmlinux] version generation failed, symbol will
not be versioned.
WARNING: EXPORT symbol "VISenter" [vmlinux] version generation failed, symbol will
not be versioned.
WARNING: EXPORT symbol "test_and_set_bit" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "xor_niagara_5" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "_clear_page" [vmlinux] version generation failed, symbol will
not be versioned.
WARNING: EXPORT symbol "xor_vis_2" [vmlinux] version generation failed, symbol will
not be versioned.
WARNING: EXPORT symbol "atomic64_xor" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "test_and_clear_bit" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "csum_partial" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "atomic_fetch_and" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "copy_user_page" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "sun4v_chip_type" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "raw_copy_in_user" [vmlinux] version generation failed, symbol
will not be versioned.
WARNING: EXPORT symbol "memcmp" [vmlinux] version generation failed, symbol will not
be versioned.
WARNING: EXPORT symbol "atomic_add_return" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "atomic_or" [vmlinux] version generation failed, symbol will
not be versioned.
WARNING: EXPORT symbol "atomic64_dec_if_positive" [vmlinux] version generation
failed, symbol will not be versioned.
WARNING: EXPORT symbol "sun4v_niagara_setperf" [vmlinux] version generation failed,
symbol will not be versioned.
WARNING: EXPORT symbol "sun4v_niagara_getperf" [vmlinux] version generation failed,
symbol will not be versioned.
With the fix, all these warnings will be removed during compilation.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc')
-rw-r--r-- | arch/sparc/include/asm/asm-prototypes.h | 24 | ||||
-rw-r--r-- | arch/sparc/lib/atomic_64.S | 44 | ||||
-rw-r--r-- | arch/sparc/lib/checksum_64.S | 1 | ||||
-rw-r--r-- | arch/sparc/lib/csum_copy.S | 1 | ||||
-rw-r--r-- | arch/sparc/lib/memscan_64.S | 2 | ||||
-rw-r--r-- | arch/sparc/lib/memset.S | 1 |
6 files changed, 55 insertions, 18 deletions
diff --git a/arch/sparc/include/asm/asm-prototypes.h b/arch/sparc/include/asm/asm-prototypes.h new file mode 100644 index 0000000..d381e11 --- /dev/null +++ b/arch/sparc/include/asm/asm-prototypes.h @@ -0,0 +1,24 @@ +/* + * Copyright (c) 2017 Oracle and/or its affiliates. All rights reserved. + */ + +#include <asm/xor.h> +#include <asm/checksum.h> +#include <asm/trap_block.h> +#include <asm/uaccess.h> +#include <asm/atomic.h> +#include <asm/ftrace.h> +#include <asm/cacheflush.h> +#include <asm/oplib.h> +#include <linux/atomic.h> + +void *__memscan_zero(void *, size_t); +void *__memscan_generic(void *, int, size_t); +void *__bzero(void *, size_t); +void VISenter(void); /* Dummy prototype to supress warning */ +#undef memcpy +#undef memset +void *memcpy(void *dest, const void *src, size_t n); +void *memset(void *s, int c, size_t n); +typedef int TItype __attribute__((mode(TI))); +TItype __multi3(TItype a, TItype b); diff --git a/arch/sparc/lib/atomic_64.S b/arch/sparc/lib/atomic_64.S index 1c6a1bd..ce17c30 100644 --- a/arch/sparc/lib/atomic_64.S +++ b/arch/sparc/lib/atomic_64.S @@ -62,19 +62,23 @@ ENTRY(atomic_fetch_##op) /* %o0 = increment, %o1 = atomic_ptr */ \ ENDPROC(atomic_fetch_##op); \ EXPORT_SYMBOL(atomic_fetch_##op); -#define ATOMIC_OPS(op) ATOMIC_OP(op) ATOMIC_OP_RETURN(op) ATOMIC_FETCH_OP(op) +ATOMIC_OP(add) +ATOMIC_OP_RETURN(add) +ATOMIC_FETCH_OP(add) -ATOMIC_OPS(add) -ATOMIC_OPS(sub) +ATOMIC_OP(sub) +ATOMIC_OP_RETURN(sub) +ATOMIC_FETCH_OP(sub) -#undef ATOMIC_OPS -#define ATOMIC_OPS(op) ATOMIC_OP(op) ATOMIC_FETCH_OP(op) +ATOMIC_OP(and) +ATOMIC_FETCH_OP(and) -ATOMIC_OPS(and) -ATOMIC_OPS(or) -ATOMIC_OPS(xor) +ATOMIC_OP(or) +ATOMIC_FETCH_OP(or) + +ATOMIC_OP(xor) +ATOMIC_FETCH_OP(xor) -#undef ATOMIC_OPS #undef ATOMIC_FETCH_OP #undef ATOMIC_OP_RETURN #undef ATOMIC_OP @@ -124,19 +128,23 @@ ENTRY(atomic64_fetch_##op) /* %o0 = increment, %o1 = atomic_ptr */ \ ENDPROC(atomic64_fetch_##op); \ EXPORT_SYMBOL(atomic64_fetch_##op); -#define ATOMIC64_OPS(op) ATOMIC64_OP(op) ATOMIC64_OP_RETURN(op) ATOMIC64_FETCH_OP(op) +ATOMIC64_OP(add) +ATOMIC64_OP_RETURN(add) +ATOMIC64_FETCH_OP(add) + +ATOMIC64_OP(sub) +ATOMIC64_OP_RETURN(sub) +ATOMIC64_FETCH_OP(sub) -ATOMIC64_OPS(add) -ATOMIC64_OPS(sub) +ATOMIC64_OP(and) +ATOMIC64_FETCH_OP(and) -#undef ATOMIC64_OPS -#define ATOMIC64_OPS(op) ATOMIC64_OP(op) ATOMIC64_FETCH_OP(op) +ATOMIC64_OP(or) +ATOMIC64_FETCH_OP(or) -ATOMIC64_OPS(and) -ATOMIC64_OPS(or) -ATOMIC64_OPS(xor) +ATOMIC64_OP(xor) +ATOMIC64_FETCH_OP(xor) -#undef ATOMIC64_OPS #undef ATOMIC64_FETCH_OP #undef ATOMIC64_OP_RETURN #undef ATOMIC64_OP diff --git a/arch/sparc/lib/checksum_64.S b/arch/sparc/lib/checksum_64.S index f673217..6cfa521 100644 --- a/arch/sparc/lib/checksum_64.S +++ b/arch/sparc/lib/checksum_64.S @@ -38,6 +38,7 @@ csum_partial_fix_alignment: .align 32 .globl csum_partial + .type csum_partial,#function EXPORT_SYMBOL(csum_partial) csum_partial: /* %o0=buff, %o1=len, %o2=sum */ prefetch [%o0 + 0x000], #n_reads diff --git a/arch/sparc/lib/csum_copy.S b/arch/sparc/lib/csum_copy.S index 0ecbafc..b1051e7 100644 --- a/arch/sparc/lib/csum_copy.S +++ b/arch/sparc/lib/csum_copy.S @@ -65,6 +65,7 @@ add %o5, %o4, %o4 .globl FUNC_NAME + .type FUNC_NAME,#function EXPORT_SYMBOL(FUNC_NAME) FUNC_NAME: /* %o0=src, %o1=dst, %o2=len, %o3=sum */ LOAD(prefetch, %o0 + 0x000, #n_reads) diff --git a/arch/sparc/lib/memscan_64.S b/arch/sparc/lib/memscan_64.S index daa96f4..5efee1f 100644 --- a/arch/sparc/lib/memscan_64.S +++ b/arch/sparc/lib/memscan_64.S @@ -14,6 +14,8 @@ .text .align 32 .globl __memscan_zero, __memscan_generic + .type __memscan_zero,#function + .type __memscan_generic,#function .globl memscan EXPORT_SYMBOL(__memscan_zero) EXPORT_SYMBOL(__memscan_generic) diff --git a/arch/sparc/lib/memset.S b/arch/sparc/lib/memset.S index bb539b4..e23338d 100644 --- a/arch/sparc/lib/memset.S +++ b/arch/sparc/lib/memset.S @@ -63,6 +63,7 @@ __bzero_begin: .globl __bzero + .type __bzero,#function .globl memset EXPORT_SYMBOL(__bzero) EXPORT_SYMBOL(memset) |