* [jpoimboe:sframe 5/10] arch/x86/events/core.c:2856:6: warning: no previous prototype for function '__perf_callchain_user'
@ 2023-11-09 20:38 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2023-11-09 20:38 UTC (permalink / raw)
To: Josh Poimboeuf; +Cc: llvm, oe-kbuild-all
tree: https://git.kernel.org/pub/scm/linux/kernel/git/jpoimboe/linux.git sframe
head: ec004e900e02c9c85cf8c89d4c26d4168a6c5d18
commit: f19cd074272c3fd160c2d637cc0f65cfffad1e81 [5/10] perf/x86: Add HAVE_PERF_CALLCHAIN_DEFERRED
config: x86_64-rhel-8.3-rust (https://download.01.org/0day-ci/archive/20231110/202311100457.J76Vb8Yp-lkp@intel.com/config)
compiler: clang version 16.0.4 (https://github.com/llvm/llvm-project.git ae42196bc493ffe877a7e3dff8be32035dea4d07)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20231110/202311100457.J76Vb8Yp-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202311100457.J76Vb8Yp-lkp@intel.com/
All warnings (new ones prefixed by >>):
>> arch/x86/events/core.c:2856:6: warning: no previous prototype for function '__perf_callchain_user' [-Wmissing-prototypes]
void __perf_callchain_user(struct perf_callchain_entry_ctx *entry,
^
arch/x86/events/core.c:2856:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void __perf_callchain_user(struct perf_callchain_entry_ctx *entry,
^
static
1 warning generated.
vim +/__perf_callchain_user +2856 arch/x86/events/core.c
2855
> 2856 void __perf_callchain_user(struct perf_callchain_entry_ctx *entry,
2857 struct pt_regs *regs, bool atomic)
2858 {
2859 struct stack_frame frame;
2860 const struct stack_frame __user *fp;
2861
2862 if (perf_guest_state()) {
2863 /* TODO: We don't support guest os callchain now */
2864 return;
2865 }
2866
2867 /*
2868 * We don't know what to do with VM86 stacks.. ignore them for now.
2869 */
2870 if (regs->flags & (X86_VM_MASK | PERF_EFLAGS_VM))
2871 return;
2872
2873 fp = (void __user *)regs->bp;
2874
2875 perf_callchain_store(entry, regs->ip);
2876
2877 if (atomic && !nmi_uaccess_okay())
2878 return;
2879
2880 if (atomic)
2881 pagefault_disable();
2882
2883 if (__perf_callchain_user32(regs, entry))
2884 goto done;
2885
2886 while (entry->nr < entry->max_stack) {
2887 if (!valid_user_frame(fp, sizeof(frame)))
2888 break;
2889
2890 if (__get_user(frame.next_frame, &fp->next_frame))
2891 break;
2892 if (__get_user(frame.return_address, &fp->return_address))
2893 break;
2894
2895 perf_callchain_store(entry, frame.return_address);
2896 fp = (void __user *)frame.next_frame;
2897 }
2898 done:
2899 if (atomic)
2900 pagefault_enable();
2901 }
2902
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2023-11-09 20:40 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-11-09 20:38 [jpoimboe:sframe 5/10] arch/x86/events/core.c:2856:6: warning: no previous prototype for function '__perf_callchain_user' kernel test robot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox