tree:   https://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-rcu.git 
rcu/next
head:   f0909808dc46d6ae79a08a42def577bd7880aa4d
commit: 0d6eb99818da24d0c55962c7c0d4a9f8dc71a6bb [19/20] membarrier: Provide 
register sync core cmd
config: xtensa-allyesconfig (attached as .config)
compiler: xtensa-linux-gcc (GCC) 4.9.0
reproduce:
        wget 
https://raw.githubusercontent.com/01org/lkp-tests/master/sbin/make.cross -O 
~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout 0d6eb99818da24d0c55962c7c0d4a9f8dc71a6bb
        # save the attached .config to linux build tree
        make.cross ARCH=xtensa 

All errors (new ones prefixed by >>):

   In file included from include/linux/ptrace.h:5:0,
                    from arch/xtensa/kernel/asm-offsets.c:21:
   include/linux/sched.h: In function 'membarrier_sched_out':
>> include/linux/sched.h:1653:3: error: implicit declaration of function 
>> 'sync_core' [-Werror=implicit-function-declaration]
      sync_core();
      ^
   cc1: some warnings being treated as errors
   make[2]: *** [arch/xtensa/kernel/asm-offsets.s] Error 1
   make[2]: Target '__build' not remade because of errors.
   make[1]: *** [prepare0] Error 2
   make[1]: Target 'prepare' not remade because of errors.
   make: *** [sub-make] Error 2

vim +/sync_core +1653 include/linux/sched.h

  1630  
  1631  #ifdef CONFIG_MEMBARRIER
  1632  static inline void membarrier_fork(struct task_struct *t,
  1633                  unsigned long clone_flags)
  1634  {
  1635          /*
  1636           * Coherence of membarrier_sync_core against thread fork is
  1637           * protected by siglock. membarrier_fork is called with siglock
  1638           * held.
  1639           */
  1640          t->membarrier_sync_core = current->membarrier_sync_core;
  1641  }
  1642  static inline void membarrier_execve(struct task_struct *t)
  1643  {
  1644          t->membarrier_sync_core = 0;
  1645  }
  1646  static inline void membarrier_sched_out(struct task_struct *t)
  1647  {
  1648          /*
  1649           * Core serialization is performed before the memory barrier
  1650           * preceding the store to rq->curr.
  1651           */
  1652          if (unlikely(READ_ONCE(t->membarrier_sync_core)))
> 1653                  sync_core();
  1654  }
  1655  static inline void membarrier_sched_in(struct task_struct *t)
  1656  {
  1657          /*
  1658           * Core serialization is performed after the memory barrier
  1659           * following the store to rq->curr.
  1660           */
  1661          if (unlikely(READ_ONCE(t->membarrier_sync_core)))
  1662                  sync_core();
  1663  }
  1664  #else
  1665  static inline void membarrier_fork(struct task_struct *t,
  1666                  unsigned long clone_flags)
  1667  {
  1668  }
  1669  static inline void membarrier_execve(struct task_struct *t)
  1670  {
  1671  }
  1672  static inline void membarrier_sched_out(struct task_struct *t)
  1673  {
  1674  }
  1675  static inline void membarrier_sched_in(struct task_struct *t)
  1676  {
  1677  }
  1678  #endif
  1679  

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

Attachment: .config.gz
Description: application/gzip

Reply via email to