All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: [peterz-queue:sched/core-sched 41/42] fs/../kernel/sched/sched.h:2461:20: error: static declaration of 'double_rq_lock' follows non-static declaration
Date: Wed, 03 Mar 2021 01:23:24 +0800	[thread overview]
Message-ID: <202103030120.Mzb9A5jT-lkp@intel.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 11728 bytes --]

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git sched/core-sched
head:   5e50471743a68f484b7d1ad91c7fd809f6a30145
commit: 2b9410cf5104df69fceb025cc73d7a0d97bd8aa7 [41/42] sched: Prepare to drop stop_machine() for core sched
config: x86_64-randconfig-a011-20210302 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 5de09ef02e24d234d9fc0cd1c6dfe18a1bb784b0)
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
        # install x86_64 cross compiling tool for clang build
        # apt-get install binutils-x86-64-linux-gnu
        # https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git/commit/?id=2b9410cf5104df69fceb025cc73d7a0d97bd8aa7
        git remote add peterz-queue https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git
        git fetch --no-tags peterz-queue sched/core-sched
        git checkout 2b9410cf5104df69fceb025cc73d7a0d97bd8aa7
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64 

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

All errors (new ones prefixed by >>):

   In file included from fs/io-wq.c:20:
>> fs/../kernel/sched/sched.h:2461:20: error: static declaration of 'double_rq_lock' follows non-static declaration
   static inline void double_rq_lock(struct rq *rq1, struct rq *rq2)
                      ^
   fs/../kernel/sched/sched.h:2331:13: note: previous declaration is here
   extern void double_rq_lock(struct rq *rq1, struct rq *rq2);
               ^
   1 error generated.
--
                                                       ^
   kernel/sched/sched.h:1152:20: note: 'sched_core_enabled' declared here
   static inline bool sched_core_enabled(struct rq *rq)
                      ^
   kernel/sched/core.c:400:7: error: member reference base type 'bool (struct rq *)' (aka '_Bool (struct rq *)') is not a structure or union
           if (!static_branch_unlikely(&__sched_core_enabled))
                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/jump_label.h:481:75: note: expanded from macro 'static_branch_unlikely'
   #define static_branch_unlikely(x)       unlikely_notrace(static_key_enabled(&(x)->key))
                                           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
   include/linux/jump_label.h:389:44: note: expanded from macro 'static_key_enabled'
           if (!__builtin_types_compatible_p(typeof(*x), struct static_key) &&     \
                                                     ^
   include/linux/compiler.h:21:49: note: expanded from macro 'unlikely_notrace'
   #define unlikely_notrace(x)     __builtin_expect(!!(x), 0)
                                                       ^
   kernel/sched/core.c:400:31: error: use of undeclared identifier '__sched_core_enabled'; did you mean 'sched_core_enabled'?
           if (!static_branch_unlikely(&__sched_core_enabled))
                                        ^~~~~~~~~~~~~~~~~~~~
                                        sched_core_enabled
   include/linux/jump_label.h:481:73: note: expanded from macro 'static_branch_unlikely'
   #define static_branch_unlikely(x)       unlikely_notrace(static_key_enabled(&(x)->key))
                                                                                 ^
   include/linux/jump_label.h:390:44: note: expanded from macro 'static_key_enabled'
               !__builtin_types_compatible_p(typeof(*x), struct static_key_true) &&\
                                                     ^
   include/linux/compiler.h:21:49: note: expanded from macro 'unlikely_notrace'
   #define unlikely_notrace(x)     __builtin_expect(!!(x), 0)
                                                       ^
   kernel/sched/sched.h:1152:20: note: 'sched_core_enabled' declared here
   static inline bool sched_core_enabled(struct rq *rq)
                      ^
   kernel/sched/core.c:400:7: error: member reference base type 'bool (struct rq *)' (aka '_Bool (struct rq *)') is not a structure or union
           if (!static_branch_unlikely(&__sched_core_enabled))
                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/jump_label.h:481:75: note: expanded from macro 'static_branch_unlikely'
   #define static_branch_unlikely(x)       unlikely_notrace(static_key_enabled(&(x)->key))
                                           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
   include/linux/jump_label.h:390:44: note: expanded from macro 'static_key_enabled'
               !__builtin_types_compatible_p(typeof(*x), struct static_key_true) &&\
                                                     ^
   include/linux/compiler.h:21:49: note: expanded from macro 'unlikely_notrace'
   #define unlikely_notrace(x)     __builtin_expect(!!(x), 0)
                                                       ^
   kernel/sched/core.c:400:31: error: use of undeclared identifier '__sched_core_enabled'; did you mean 'sched_core_enabled'?
           if (!static_branch_unlikely(&__sched_core_enabled))
                                        ^~~~~~~~~~~~~~~~~~~~
                                        sched_core_enabled
   include/linux/jump_label.h:481:73: note: expanded from macro 'static_branch_unlikely'
   #define static_branch_unlikely(x)       unlikely_notrace(static_key_enabled(&(x)->key))
                                                                                 ^
   include/linux/jump_label.h:391:44: note: expanded from macro 'static_key_enabled'
               !__builtin_types_compatible_p(typeof(*x), struct static_key_false)) \
                                                     ^
   include/linux/compiler.h:21:49: note: expanded from macro 'unlikely_notrace'
   #define unlikely_notrace(x)     __builtin_expect(!!(x), 0)
                                                       ^
   kernel/sched/sched.h:1152:20: note: 'sched_core_enabled' declared here
   static inline bool sched_core_enabled(struct rq *rq)
                      ^
   kernel/sched/core.c:400:7: error: member reference base type 'bool (struct rq *)' (aka '_Bool (struct rq *)') is not a structure or union
           if (!static_branch_unlikely(&__sched_core_enabled))
                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/jump_label.h:481:75: note: expanded from macro 'static_branch_unlikely'
   #define static_branch_unlikely(x)       unlikely_notrace(static_key_enabled(&(x)->key))
                                           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
   include/linux/jump_label.h:391:44: note: expanded from macro 'static_key_enabled'
               !__builtin_types_compatible_p(typeof(*x), struct static_key_false)) \
                                                     ^
   include/linux/compiler.h:21:49: note: expanded from macro 'unlikely_notrace'
   #define unlikely_notrace(x)     __builtin_expect(!!(x), 0)
                                                       ^
   kernel/sched/core.c:400:31: error: use of undeclared identifier '__sched_core_enabled'; did you mean 'sched_core_enabled'?
           if (!static_branch_unlikely(&__sched_core_enabled))
                                        ^~~~~~~~~~~~~~~~~~~~
                                        sched_core_enabled
   include/linux/jump_label.h:481:73: note: expanded from macro 'static_branch_unlikely'
   #define static_branch_unlikely(x)       unlikely_notrace(static_key_enabled(&(x)->key))
                                                                                 ^
   include/linux/jump_label.h:393:40: note: expanded from macro 'static_key_enabled'
           static_key_count((struct static_key *)x) > 0;                           \
                                                 ^
   include/linux/compiler.h:21:49: note: expanded from macro 'unlikely_notrace'
   #define unlikely_notrace(x)     __builtin_expect(!!(x), 0)
                                                       ^
   kernel/sched/sched.h:1152:20: note: 'sched_core_enabled' declared here
   static inline bool sched_core_enabled(struct rq *rq)
                      ^
   kernel/sched/core.c:400:7: error: member reference base type 'bool (struct rq *)' (aka '_Bool (struct rq *)') is not a structure or union
           if (!static_branch_unlikely(&__sched_core_enabled))
                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/jump_label.h:481:75: note: expanded from macro 'static_branch_unlikely'
   #define static_branch_unlikely(x)       unlikely_notrace(static_key_enabled(&(x)->key))
                                           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
   include/linux/jump_label.h:393:40: note: expanded from macro 'static_key_enabled'
           static_key_count((struct static_key *)x) > 0;                           \
                                                 ^
   include/linux/compiler.h:21:49: note: expanded from macro 'unlikely_notrace'
   #define unlikely_notrace(x)     __builtin_expect(!!(x), 0)
                                                       ^
>> kernel/sched/core.c:424:11: error: no member named 'cpu' in 'struct rq'
           if (rq1->cpu > rq2->cpu)
               ~~~  ^
   kernel/sched/core.c:424:22: error: no member named 'cpu' in 'struct rq'
           if (rq1->cpu > rq2->cpu)
                          ~~~  ^
   19 errors generated.


vim +/double_rq_lock +2461 fs/../kernel/sched/sched.h

029632fbb7b7c9 kernel/sched.h       Peter Zijlstra 2011-10-25  2454  
029632fbb7b7c9 kernel/sched.h       Peter Zijlstra 2011-10-25  2455  /*
029632fbb7b7c9 kernel/sched.h       Peter Zijlstra 2011-10-25  2456   * double_rq_lock - safely lock two runqueues
029632fbb7b7c9 kernel/sched.h       Peter Zijlstra 2011-10-25  2457   *
029632fbb7b7c9 kernel/sched.h       Peter Zijlstra 2011-10-25  2458   * Note this does not disable interrupts like task_rq_lock,
029632fbb7b7c9 kernel/sched.h       Peter Zijlstra 2011-10-25  2459   * you need to do so manually before calling.
029632fbb7b7c9 kernel/sched.h       Peter Zijlstra 2011-10-25  2460   */
029632fbb7b7c9 kernel/sched.h       Peter Zijlstra 2011-10-25 @2461  static inline void double_rq_lock(struct rq *rq1, struct rq *rq2)
029632fbb7b7c9 kernel/sched.h       Peter Zijlstra 2011-10-25  2462  	__acquires(rq1->lock)
029632fbb7b7c9 kernel/sched.h       Peter Zijlstra 2011-10-25  2463  	__acquires(rq2->lock)
029632fbb7b7c9 kernel/sched.h       Peter Zijlstra 2011-10-25  2464  {
029632fbb7b7c9 kernel/sched.h       Peter Zijlstra 2011-10-25  2465  	BUG_ON(!irqs_disabled());
029632fbb7b7c9 kernel/sched.h       Peter Zijlstra 2011-10-25  2466  	BUG_ON(rq1 != rq2);
b75054e70706ab kernel/sched/sched.h Peter Zijlstra 2021-03-02  2467  	raw_spin_rq_lock(rq1);
029632fbb7b7c9 kernel/sched.h       Peter Zijlstra 2011-10-25  2468  	__acquire(rq2->lock);	/* Fake it out ;) */
029632fbb7b7c9 kernel/sched.h       Peter Zijlstra 2011-10-25  2469  }
029632fbb7b7c9 kernel/sched.h       Peter Zijlstra 2011-10-25  2470  

:::::: The code at line 2461 was first introduced by commit
:::::: 029632fbb7b7c9d85063cc9eb470de6c54873df3 sched: Make separate sched*.c translation units

:::::: TO: Peter Zijlstra <a.p.zijlstra@chello.nl>
:::::: CC: Ingo Molnar <mingo@elte.hu>

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

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 25658 bytes --]

             reply	other threads:[~2021-03-02 17:23 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-02 17:23 kernel test robot [this message]
  -- strict thread matches above, loose matches on Subject: below --
2021-03-02 16:44 [peterz-queue:sched/core-sched 41/42] fs/../kernel/sched/sched.h:2461:20: error: static declaration of 'double_rq_lock' follows non-static declaration kernel test robot

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202103030120.Mzb9A5jT-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=kbuild-all@lists.01.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.