[groeck-staging:google-commits 5671/6115] arch/parisc/kernel/stacktrace.c:20:13: error: 'regs' undeclared

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



tree:   https://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging.git google-commits
head:   cfb9e87ff8218995cac59c8225da1b31f2fb2507
commit: d5fd1c46a3cebbef254611682b95c315163e4620 [5671/6115] parisc/unwind: call callback with toplevel address
config: parisc-randconfig-r036-20211004 (attached as .config)
compiler: hppa-linux-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging.git/commit/?id=d5fd1c46a3cebbef254611682b95c315163e4620
        git remote add groeck-staging https://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging.git
        git fetch --no-tags groeck-staging google-commits
        git checkout d5fd1c46a3cebbef254611682b95c315163e4620
        # save the attached .config to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=parisc SHELL=/bin/bash arch/parisc/kernel/

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@xxxxxxxxx>

All errors (new ones prefixed by >>):

   In file included from include/linux/kernel.h:11,
                    from include/linux/list.h:9,
                    from include/linux/module.h:12,
                    from arch/parisc/kernel/stacktrace.c:11:
   arch/parisc/kernel/stacktrace.c: In function 'dump_trace':
>> arch/parisc/kernel/stacktrace.c:20:13: error: 'regs' undeclared (first use in this function)
      20 |         if (regs)
         |             ^~~~
   include/linux/compiler.h:58:52: note: in definition of macro '__trace_if_var'
      58 | #define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
         |                                                    ^~~~
   arch/parisc/kernel/stacktrace.c:20:9: note: in expansion of macro 'if'
      20 |         if (regs)
         |         ^~
   arch/parisc/kernel/stacktrace.c:20:13: note: each undeclared identifier is reported only once for each function it appears in
      20 |         if (regs)
         |             ^~~~
   include/linux/compiler.h:58:52: note: in definition of macro '__trace_if_var'
      58 | #define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
         |                                                    ^~~~
   arch/parisc/kernel/stacktrace.c:20:9: note: in expansion of macro 'if'
      20 |         if (regs)
         |         ^~
>> arch/parisc/kernel/stacktrace.c:21:22: error: implicit declaration of function 'fn' [-Werror=implicit-function-declaration]
      21 |                 if (!fn(cookie, regs->iaoq[0]))
         |                      ^~
   include/linux/compiler.h:58:52: note: in definition of macro '__trace_if_var'
      58 | #define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
         |                                                    ^~~~
   arch/parisc/kernel/stacktrace.c:21:17: note: in expansion of macro 'if'
      21 |                 if (!fn(cookie, regs->iaoq[0]))
         |                 ^~
>> arch/parisc/kernel/stacktrace.c:21:25: error: 'cookie' undeclared (first use in this function)
      21 |                 if (!fn(cookie, regs->iaoq[0]))
         |                         ^~~~~~
   include/linux/compiler.h:58:52: note: in definition of macro '__trace_if_var'
      58 | #define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
         |                                                    ^~~~
   arch/parisc/kernel/stacktrace.c:21:17: note: in expansion of macro 'if'
      21 |                 if (!fn(cookie, regs->iaoq[0]))
         |                 ^~
   cc1: some warnings being treated as errors


vim +/regs +20 arch/parisc/kernel/stacktrace.c

    15	
    16	static void dump_trace(struct task_struct *task, struct stack_trace *trace)
    17	{
    18		struct unwind_frame_info info;
    19	
  > 20		if (regs)
  > 21			if (!fn(cookie, regs->iaoq[0]))
    22				return;
    23	
    24		unwind_frame_init_task(&info, task, NULL);
    25	
    26		/* unwind stack and save entries in stack_trace struct */
    27		trace->nr_entries = 0;
    28		while (trace->nr_entries < trace->max_entries) {
    29			if (unwind_once(&info) < 0 || info.ip == 0)
    30				break;
    31	
    32			if (__kernel_text_address(info.ip))
    33				trace->entries[trace->nr_entries++] = info.ip;
    34		}
    35	}
    36	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [LM Sensors]     [Linux Sound]     [ALSA Users]     [ALSA Devel]     [Linux Audio Users]     [Linux Media]     [Kernel]     [Gimp]     [Yosemite News]     [Linux Media]

  Powered by Linux