android_kernel_xiaomi_sm7250/include/asm-sparc64/ftrace.h
Ingo Molnar 760378e149 fix "ftrace: store mcount address in rec->ip"
Alexander Beregalov reported this build failure:

$ make CROSS_COMPILE=sparc64-unknown-linux-gnu- image modules && sudo
make modules_install
  CHK     include/linux/version.h
  CHK     include/linux/utsrelease.h
  CALL    scripts/checksyscalls.sh
  CHK     include/linux/compile.h
dnsdomainname: Unknown host
  CC      arch/sparc64/kernel/sparc64_ksyms.o
arch/sparc64/kernel/sparc64_ksyms.c:116: error: '_mcount' undeclared
here (not in a function)
cc1: warnings being treated as errors
arch/sparc64/kernel/sparc64_ksyms.c:116: error: type defaults to 'int'
in declaration of '_mcount'

And bisected it back to:

| commit 395a59d0f8
| Author: Abhishek Sagar <sagar.abhishek@gmail.com>
| Date:   Sat Jun 21 23:47:27 2008 +0530
|
|     ftrace: store mcount address in rec->ip

the mcount prototype is only available under CONFIG_FTRACE,
extend it to CONFIG_MCOUNT as well.

Reported-and-bisected-by: Alexander Beregalov <a.beregalov@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
2008-07-01 17:46:14 +02:00

15 lines
267 B
C

#ifndef _ASM_SPARC64_FTRACE
#define _ASM_SPARC64_FTRACE
#ifdef CONFIG_MCOUNT
#define MCOUNT_ADDR ((long)(_mcount))
#define MCOUNT_INSN_SIZE 4 /* sizeof mcount call */
#ifndef __ASSEMBLY__
extern void _mcount(void);
#endif
#endif
#endif /* _ASM_SPARC64_FTRACE */