lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:   Mon, 14 Jun 2021 21:59:36 +0800
From:   kernel test robot <lkp@...el.com>
To:     Ingo Molnar <mingo@...nel.org>
Cc:     kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org,
        x86@...nel.org
Subject: [tip:tmp.tmp2 242/364] include/linux/kthread.h:55:3: error: implicit
 declaration of function 'wake_up_process'; did you mean 'wake_up_poll'?

Hi Ingo,

First bad commit (maybe != root cause):

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git tmp.tmp2
head:   adcceb5eb7aee38e4a9c15bdf599655f0e1b1324
commit: 880b182db2f9eaa03034f29e0ba191fcffc4e7f5 [242/364] sched/headers, kthread: Remove <linux/sched.h> from <linux/kthread.h>
config: x86_64-rhel-8.3 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
        # https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git/commit/?id=880b182db2f9eaa03034f29e0ba191fcffc4e7f5
        git remote add tip https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git
        git fetch --no-tags tip tmp.tmp2
        git checkout 880b182db2f9eaa03034f29e0ba191fcffc4e7f5
        # save the attached .config to linux build tree
        make W=1 ARCH=x86_64 

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

All errors (new ones prefixed by >>):

   In file included from include/linux/srcu.h:20,
                    from include/linux/notifier.h:16,
                    from arch/x86/include/asm/uprobes.h:13,
                    from include/linux/uprobes.h:49,
                    from include/linux/mm_types.h:14,
                    from include/linux/mmzone.h:21,
                    from include/linux/gfp.h:7,
                    from include/linux/mm.h:12,
                    from include/linux/ring_buffer.h:5,
                    from kernel/trace/ring_buffer_benchmark.c:7:
   include/linux/rcuwait.h: In function 'rcuwait_active':
   include/linux/rcupdate.h:364:9: error: dereferencing pointer to incomplete type 'struct task_struct'
     364 |  typeof(*p) *_________p1 = (typeof(*p) *__force)READ_ONCE(p); \
         |         ^
   include/linux/rcupdate.h:474:31: note: in expansion of macro '__rcu_access_pointer'
     474 | #define rcu_access_pointer(p) __rcu_access_pointer((p), __rcu)
         |                               ^~~~~~~~~~~~~~~~~~~~
   include/linux/rcuwait.h:33:11: note: in expansion of macro 'rcu_access_pointer'
      33 |  return !!rcu_access_pointer(w->task);
         |           ^~~~~~~~~~~~~~~~~~
   kernel/trace/ring_buffer_benchmark.c: At top level:
>> kernel/trace/ring_buffer_benchmark.c:45:28: error: 'MAX_NICE' undeclared here (not in a function)
      45 | static int producer_nice = MAX_NICE;
         |                            ^~~~~~~~
   kernel/trace/ring_buffer_benchmark.c: In function 'ring_buffer_consumer':
>> kernel/trace/ring_buffer_benchmark.c:219:3: error: implicit declaration of function 'set_current_state'; did you mean 'set_current_groups'? [-Werror=implicit-function-declaration]
     219 |   set_current_state(TASK_INTERRUPTIBLE);
         |   ^~~~~~~~~~~~~~~~~
         |   set_current_groups
>> kernel/trace/ring_buffer_benchmark.c:223:3: error: implicit declaration of function 'schedule' [-Werror=implicit-function-declaration]
     223 |   schedule();
         |   ^~~~~~~~
>> kernel/trace/ring_buffer_benchmark.c:225:2: error: implicit declaration of function '__set_current_state' [-Werror=implicit-function-declaration]
     225 |  __set_current_state(TASK_RUNNING);
         |  ^~~~~~~~~~~~~~~~~~~
   kernel/trace/ring_buffer_benchmark.c: In function 'ring_buffer_producer':
>> kernel/trace/ring_buffer_benchmark.c:268:4: error: implicit declaration of function 'wake_up_process'; did you mean 'wake_up_poll'? [-Werror=implicit-function-declaration]
     268 |    wake_up_process(consumer);
         |    ^~~~~~~~~~~~~~~
         |    wake_up_poll
   kernel/trace/ring_buffer_benchmark.c:281:4: error: implicit declaration of function 'cond_resched'; did you mean 'should_resched'? [-Werror=implicit-function-declaration]
     281 |    cond_resched();
         |    ^~~~~~~~~~~~
         |    should_resched
   kernel/trace/ring_buffer_benchmark.c: In function 'ring_buffer_producer_thread':
>> kernel/trace/ring_buffer_benchmark.c:419:3: error: implicit declaration of function 'schedule_timeout'; did you mean 'schedule_work'? [-Werror=implicit-function-declaration]
     419 |   schedule_timeout(HZ * SLEEP_TIME);
         |   ^~~~~~~~~~~~~~~~
         |   schedule_work
   kernel/trace/ring_buffer_benchmark.c: In function 'ring_buffer_benchmark_init':
>> kernel/trace/ring_buffer_benchmark.c:459:4: error: implicit declaration of function 'sched_set_fifo' [-Werror=implicit-function-declaration]
     459 |    sched_set_fifo(consumer);
         |    ^~~~~~~~~~~~~~
>> kernel/trace/ring_buffer_benchmark.c:461:4: error: implicit declaration of function 'sched_set_fifo_low' [-Werror=implicit-function-declaration]
     461 |    sched_set_fifo_low(consumer);
         |    ^~~~~~~~~~~~~~~~~~
>> kernel/trace/ring_buffer_benchmark.c:463:4: error: implicit declaration of function 'set_user_nice'; did you mean 'seq_user_ns'? [-Werror=implicit-function-declaration]
     463 |    set_user_nice(consumer, consumer_nice);
         |    ^~~~~~~~~~~~~
         |    seq_user_ns
   In file included from include/linux/uaccess.h:11,
                    from arch/x86/include/asm/fpu/xstate.h:5,
                    from arch/x86/include/asm/pgtable.h:26,
                    from include/linux/pgtable.h:6,
                    from include/linux/mm.h:35,
                    from include/linux/ring_buffer.h:5,
                    from kernel/trace/ring_buffer_benchmark.c:7:
   kernel/trace/ring_buffer_benchmark.c: At top level:
   arch/x86/include/asm/uaccess.h:46:20: warning: 'pagefault_disabled' used but never defined
      46 | static inline bool pagefault_disabled(void);
         |                    ^~~~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors
--
   In file included from lib/kunit/try-catch.c:13:
   lib/kunit/try-catch.c: In function 'kunit_try_catch_run':
>> include/linux/kthread.h:55:3: error: implicit declaration of function 'wake_up_process'; did you mean 'wake_up_poll'? [-Werror=implicit-function-declaration]
      55 |   wake_up_process(__k);        \
         |   ^~~~~~~~~~~~~~~
   lib/kunit/try-catch.c:68:16: note: in expansion of macro 'kthread_run'
      68 |  task_struct = kthread_run(kunit_generic_run_threadfn_adapter,
         |                ^~~~~~~~~~~
   cc1: some warnings being treated as errors


vim +55 include/linux/kthread.h

ac687e6e8c2618 Peter Zijlstra 2021-01-12  40  
^1da177e4c3f41 Linus Torvalds 2005-04-16  41  /**
9e37bd301ee130 Randy Dunlap   2006-06-25  42   * kthread_run - create and wake a thread.
^1da177e4c3f41 Linus Torvalds 2005-04-16  43   * @threadfn: the function to run until signal_pending(current).
^1da177e4c3f41 Linus Torvalds 2005-04-16  44   * @data: data ptr for @threadfn.
^1da177e4c3f41 Linus Torvalds 2005-04-16  45   * @namefmt: printf-style name for the thread.
^1da177e4c3f41 Linus Torvalds 2005-04-16  46   *
^1da177e4c3f41 Linus Torvalds 2005-04-16  47   * Description: Convenient wrapper for kthread_create() followed by
9e37bd301ee130 Randy Dunlap   2006-06-25  48   * wake_up_process().  Returns the kthread or ERR_PTR(-ENOMEM).
9e37bd301ee130 Randy Dunlap   2006-06-25  49   */
^1da177e4c3f41 Linus Torvalds 2005-04-16  50  #define kthread_run(threadfn, data, namefmt, ...)			   \
^1da177e4c3f41 Linus Torvalds 2005-04-16  51  ({									   \
^1da177e4c3f41 Linus Torvalds 2005-04-16  52  	struct task_struct *__k						   \
^1da177e4c3f41 Linus Torvalds 2005-04-16  53  		= kthread_create(threadfn, data, namefmt, ## __VA_ARGS__); \
^1da177e4c3f41 Linus Torvalds 2005-04-16  54  	if (!IS_ERR(__k))						   \
^1da177e4c3f41 Linus Torvalds 2005-04-16 @55  		wake_up_process(__k);					   \
^1da177e4c3f41 Linus Torvalds 2005-04-16  56  	__k;								   \
^1da177e4c3f41 Linus Torvalds 2005-04-16  57  })
^1da177e4c3f41 Linus Torvalds 2005-04-16  58  

:::::: The code at line 55 was first introduced by commit
:::::: 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 Linux-2.6.12-rc2

:::::: TO: Linus Torvalds <torvalds@...970.osdl.org>
:::::: CC: Linus Torvalds <torvalds@...970.osdl.org>

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

Download attachment ".config.gz" of type "application/gzip" (41434 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ