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]
Message-ID: <201705050729.bnS8ZRcq%fengguang.wu@intel.com>
Date:   Fri, 5 May 2017 07:11:02 +0800
From:   kbuild test robot <fengguang.wu@...el.com>
To:     "Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>
Cc:     kbuild-all@...org, linux-kernel@...r.kernel.org
Subject: [rcu:rcu/dev 90/90] include/linux/spinlock_api_smp.h:126:2: note: in
 expansion of macro 'local_irq_disable'

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-rcu.git rcu/dev
head:   894c3990aadbe57e0e87f9d18307fa2a4e27af7f
commit: 894c3990aadbe57e0e87f9d18307fa2a4e27af7f [90/90] fixup! rcu: Move ktime needs to rcutiny.h and remove ktime.h from rcupdate.h
config: sparc64-defconfig (attached as .config)
compiler: sparc64-linux-gnu-gcc (Debian 6.1.1-9) 6.1.1 20160705
reproduce:
        wget https://raw.githubusercontent.com/01org/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout 894c3990aadbe57e0e87f9d18307fa2a4e27af7f
        # save the attached .config to linux build tree
        make.cross ARCH=sparc64 

All warnings (new ones prefixed by >>):

   In file included from arch/sparc/include/asm/irqflags.h:4:0,
                    from include/linux/irqflags.h:15,
                    from include/linux/rcupdate.h:36,
                    from include/linux/init_task.h:4,
                    from init/init_task.c:1:
   arch/sparc/include/asm/irqflags_64.h:17:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'unsigned'
    static inline notrace unsigned long arch_local_save_flags(void)
                          ^~~~~~~~
   arch/sparc/include/asm/irqflags_64.h:29:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'void'
    static inline notrace void arch_local_irq_restore(unsigned long flags)
                          ^~~~
   arch/sparc/include/asm/irqflags_64.h:39:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'void'
    static inline notrace void arch_local_irq_disable(void)
                          ^~~~
   arch/sparc/include/asm/irqflags_64.h:49:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'void'
    static inline notrace void arch_local_irq_enable(void)
                          ^~~~
   arch/sparc/include/asm/irqflags_64.h:59:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'int'
    static inline notrace int arch_irqs_disabled_flags(unsigned long flags)
                          ^~~
   arch/sparc/include/asm/irqflags_64.h:64:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'int'
    static inline notrace int arch_irqs_disabled(void)
                          ^~~
   arch/sparc/include/asm/irqflags_64.h:69:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'unsigned'
    static inline notrace unsigned long arch_local_irq_save(void)
                          ^~~~~~~~
   In file included from include/linux/rcupdate.h:36:0,
                    from include/linux/init_task.h:4,
                    from init/init_task.c:1:
   include/asm-generic/cmpxchg-local.h: In function '__cmpxchg_local_generic':
   include/linux/irqflags.h:64:11: error: implicit declaration of function 'arch_local_irq_save' [-Werror=implicit-function-declaration]
      flags = arch_local_irq_save();  \
              ^
   include/asm-generic/cmpxchg-local.h:25:2: note: in expansion of macro 'raw_local_irq_save'
     raw_local_irq_save(flags);
     ^~~~~~~~~~~~~~~~~~
   include/linux/irqflags.h:69:3: error: implicit declaration of function 'arch_local_irq_restore' [-Werror=implicit-function-declaration]
      arch_local_irq_restore(flags);  \
      ^
   include/asm-generic/cmpxchg-local.h:46:2: note: in expansion of macro 'raw_local_irq_restore'
     raw_local_irq_restore(flags);
     ^~~~~~~~~~~~~~~~~~~~~
   In file included from include/linux/rcupdate.h:36:0,
                    from include/linux/init_task.h:4,
                    from init/init_task.c:1:
   include/linux/spinlock_api_smp.h: In function '__raw_spin_lock_irq':
   include/linux/irqflags.h:59:34: error: implicit declaration of function 'arch_local_irq_disable' [-Werror=implicit-function-declaration]
    #define raw_local_irq_disable()  arch_local_irq_disable()
                                     ^
   include/linux/irqflags.h:121:34: note: in expansion of macro 'raw_local_irq_disable'
    #define local_irq_disable() do { raw_local_irq_disable(); } while (0)
                                     ^~~~~~~~~~~~~~~~~~~~~
>> include/linux/spinlock_api_smp.h:126:2: note: in expansion of macro 'local_irq_disable'
     local_irq_disable();
     ^~~~~~~~~~~~~~~~~
   include/linux/spinlock_api_smp.h: In function '__raw_spin_unlock_irq':
   include/linux/irqflags.h:60:33: error: implicit declaration of function 'arch_local_irq_enable' [-Werror=implicit-function-declaration]
    #define raw_local_irq_enable()  arch_local_irq_enable()
                                    ^
   include/linux/irqflags.h:120:33: note: in expansion of macro 'raw_local_irq_enable'
    #define local_irq_enable() do { raw_local_irq_enable(); } while (0)
                                    ^~~~~~~~~~~~~~~~~~~~
>> include/linux/spinlock_api_smp.h:168:2: note: in expansion of macro 'local_irq_enable'
     local_irq_enable();
     ^~~~~~~~~~~~~~~~
   In file included from arch/sparc/include/asm/bug.h:20:0,
                    from include/linux/bug.h:4,
                    from include/linux/thread_info.h:11,
                    from include/asm-generic/preempt.h:4,
                    from ./arch/sparc/include/generated/asm/preempt.h:1,
                    from include/linux/preempt.h:80,
                    from include/linux/rcupdate.h:37,
                    from include/linux/init_task.h:4,
                    from init/init_task.c:1:
   include/linux/dma-mapping.h: In function 'dma_free_attrs':
   include/linux/irqflags.h:74:11: error: implicit declaration of function 'arch_local_save_flags' [-Werror=implicit-function-declaration]
      flags = arch_local_save_flags(); \
              ^
   include/asm-generic/bug.h:92:25: note: in definition of macro 'WARN_ON'
     int __ret_warn_on = !!(condition);    \
                            ^~~~~~~~~
   include/linux/irqflags.h:142:3: note: in expansion of macro 'raw_local_save_flags'
      raw_local_save_flags(_flags);  \
      ^~~~~~~~~~~~~~~~~~~~
   include/linux/dma-mapping.h:505:10: note: in expansion of macro 'irqs_disabled'
     WARN_ON(irqs_disabled());
             ^~~~~~~~~~~~~
   include/linux/irqflags.h:79:3: error: implicit declaration of function 'arch_irqs_disabled_flags' [-Werror=implicit-function-declaration]
      arch_irqs_disabled_flags(flags); \
      ^
   include/asm-generic/bug.h:92:25: note: in definition of macro 'WARN_ON'
     int __ret_warn_on = !!(condition);    \
                            ^~~~~~~~~
   include/linux/irqflags.h:143:3: note: in expansion of macro 'raw_irqs_disabled_flags'
      raw_irqs_disabled_flags(_flags); \
      ^~~~~~~~~~~~~~~~~~~~~~~
   include/linux/dma-mapping.h:505:10: note: in expansion of macro 'irqs_disabled'
     WARN_ON(irqs_disabled());
             ^~~~~~~~~~~~~
   cc1: some warnings being treated as errors
--
   In file included from arch/sparc/include/asm/irqflags.h:4:0,
                    from include/linux/irqflags.h:15,
                    from include/linux/rcupdate.h:36,
                    from lib/assoc_array.c:14:
   arch/sparc/include/asm/irqflags_64.h:17:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'unsigned'
    static inline notrace unsigned long arch_local_save_flags(void)
                          ^~~~~~~~
   arch/sparc/include/asm/irqflags_64.h:29:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'void'
    static inline notrace void arch_local_irq_restore(unsigned long flags)
                          ^~~~
   arch/sparc/include/asm/irqflags_64.h:39:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'void'
    static inline notrace void arch_local_irq_disable(void)
                          ^~~~
   arch/sparc/include/asm/irqflags_64.h:49:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'void'
    static inline notrace void arch_local_irq_enable(void)
                          ^~~~
   arch/sparc/include/asm/irqflags_64.h:59:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'int'
    static inline notrace int arch_irqs_disabled_flags(unsigned long flags)
                          ^~~
   arch/sparc/include/asm/irqflags_64.h:64:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'int'
    static inline notrace int arch_irqs_disabled(void)
                          ^~~
   arch/sparc/include/asm/irqflags_64.h:69:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'unsigned'
    static inline notrace unsigned long arch_local_irq_save(void)
                          ^~~~~~~~
   In file included from include/linux/rcupdate.h:36:0,
                    from lib/assoc_array.c:14:
   include/asm-generic/cmpxchg-local.h: In function '__cmpxchg_local_generic':
   include/linux/irqflags.h:64:11: error: implicit declaration of function 'arch_local_irq_save' [-Werror=implicit-function-declaration]
      flags = arch_local_irq_save();  \
              ^
   include/asm-generic/cmpxchg-local.h:25:2: note: in expansion of macro 'raw_local_irq_save'
     raw_local_irq_save(flags);
     ^~~~~~~~~~~~~~~~~~
   include/linux/irqflags.h:69:3: error: implicit declaration of function 'arch_local_irq_restore' [-Werror=implicit-function-declaration]
      arch_local_irq_restore(flags);  \
      ^
   include/asm-generic/cmpxchg-local.h:46:2: note: in expansion of macro 'raw_local_irq_restore'
     raw_local_irq_restore(flags);
     ^~~~~~~~~~~~~~~~~~~~~
   include/linux/spinlock_api_smp.h: In function '__raw_spin_lock_irq':
   include/linux/irqflags.h:59:34: error: implicit declaration of function 'arch_local_irq_disable' [-Werror=implicit-function-declaration]
    #define raw_local_irq_disable()  arch_local_irq_disable()
                                     ^
   include/linux/irqflags.h:121:34: note: in expansion of macro 'raw_local_irq_disable'
    #define local_irq_disable() do { raw_local_irq_disable(); } while (0)
                                     ^~~~~~~~~~~~~~~~~~~~~
>> include/linux/spinlock_api_smp.h:126:2: note: in expansion of macro 'local_irq_disable'
     local_irq_disable();
     ^~~~~~~~~~~~~~~~~
   include/linux/spinlock_api_smp.h: In function '__raw_spin_unlock_irq':
   include/linux/irqflags.h:60:33: error: implicit declaration of function 'arch_local_irq_enable' [-Werror=implicit-function-declaration]
    #define raw_local_irq_enable()  arch_local_irq_enable()
                                    ^
   include/linux/irqflags.h:120:33: note: in expansion of macro 'raw_local_irq_enable'
    #define local_irq_enable() do { raw_local_irq_enable(); } while (0)
                                    ^~~~~~~~~~~~~~~~~~~~
>> include/linux/spinlock_api_smp.h:168:2: note: in expansion of macro 'local_irq_enable'
     local_irq_enable();
     ^~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors

vim +/local_irq_disable +126 include/linux/spinlock_api_smp.h

69d0ee73 Heiko Carstens  2009-08-31  120  #endif
69d0ee73 Heiko Carstens  2009-08-31  121  	return flags;
69d0ee73 Heiko Carstens  2009-08-31  122  }
69d0ee73 Heiko Carstens  2009-08-31  123  
9c1721aa Thomas Gleixner 2009-12-03  124  static inline void __raw_spin_lock_irq(raw_spinlock_t *lock)
69d0ee73 Heiko Carstens  2009-08-31  125  {
69d0ee73 Heiko Carstens  2009-08-31 @126  	local_irq_disable();
69d0ee73 Heiko Carstens  2009-08-31  127  	preempt_disable();
69d0ee73 Heiko Carstens  2009-08-31  128  	spin_acquire(&lock->dep_map, 0, 0, _RET_IP_);
9828ea9d Thomas Gleixner 2009-12-03  129  	LOCK_CONTENDED(lock, do_raw_spin_trylock, do_raw_spin_lock);
69d0ee73 Heiko Carstens  2009-08-31  130  }
69d0ee73 Heiko Carstens  2009-08-31  131  
9c1721aa Thomas Gleixner 2009-12-03  132  static inline void __raw_spin_lock_bh(raw_spinlock_t *lock)
69d0ee73 Heiko Carstens  2009-08-31  133  {
9ea4c380 Peter Zijlstra  2013-11-19  134  	__local_bh_disable_ip(_RET_IP_, SOFTIRQ_LOCK_OFFSET);
69d0ee73 Heiko Carstens  2009-08-31  135  	spin_acquire(&lock->dep_map, 0, 0, _RET_IP_);
9828ea9d Thomas Gleixner 2009-12-03  136  	LOCK_CONTENDED(lock, do_raw_spin_trylock, do_raw_spin_lock);
69d0ee73 Heiko Carstens  2009-08-31  137  }
69d0ee73 Heiko Carstens  2009-08-31  138  
9c1721aa Thomas Gleixner 2009-12-03  139  static inline void __raw_spin_lock(raw_spinlock_t *lock)
69d0ee73 Heiko Carstens  2009-08-31  140  {
69d0ee73 Heiko Carstens  2009-08-31  141  	preempt_disable();
69d0ee73 Heiko Carstens  2009-08-31  142  	spin_acquire(&lock->dep_map, 0, 0, _RET_IP_);
9828ea9d Thomas Gleixner 2009-12-03  143  	LOCK_CONTENDED(lock, do_raw_spin_trylock, do_raw_spin_lock);
69d0ee73 Heiko Carstens  2009-08-31  144  }
69d0ee73 Heiko Carstens  2009-08-31  145  
ae58403f Chen Gang       2013-06-19  146  #endif /* !CONFIG_GENERIC_LOCKBREAK || CONFIG_DEBUG_LOCK_ALLOC */
69d0ee73 Heiko Carstens  2009-08-31  147  
9c1721aa Thomas Gleixner 2009-12-03  148  static inline void __raw_spin_unlock(raw_spinlock_t *lock)
69d0ee73 Heiko Carstens  2009-08-31  149  {
69d0ee73 Heiko Carstens  2009-08-31  150  	spin_release(&lock->dep_map, 1, _RET_IP_);
9828ea9d Thomas Gleixner 2009-12-03  151  	do_raw_spin_unlock(lock);
69d0ee73 Heiko Carstens  2009-08-31  152  	preempt_enable();
69d0ee73 Heiko Carstens  2009-08-31  153  }
69d0ee73 Heiko Carstens  2009-08-31  154  
9c1721aa Thomas Gleixner 2009-12-03  155  static inline void __raw_spin_unlock_irqrestore(raw_spinlock_t *lock,
69d0ee73 Heiko Carstens  2009-08-31  156  					    unsigned long flags)
69d0ee73 Heiko Carstens  2009-08-31  157  {
69d0ee73 Heiko Carstens  2009-08-31  158  	spin_release(&lock->dep_map, 1, _RET_IP_);
9828ea9d Thomas Gleixner 2009-12-03  159  	do_raw_spin_unlock(lock);
69d0ee73 Heiko Carstens  2009-08-31  160  	local_irq_restore(flags);
69d0ee73 Heiko Carstens  2009-08-31  161  	preempt_enable();
69d0ee73 Heiko Carstens  2009-08-31  162  }
69d0ee73 Heiko Carstens  2009-08-31  163  
9c1721aa Thomas Gleixner 2009-12-03  164  static inline void __raw_spin_unlock_irq(raw_spinlock_t *lock)
69d0ee73 Heiko Carstens  2009-08-31  165  {
69d0ee73 Heiko Carstens  2009-08-31  166  	spin_release(&lock->dep_map, 1, _RET_IP_);
9828ea9d Thomas Gleixner 2009-12-03  167  	do_raw_spin_unlock(lock);
69d0ee73 Heiko Carstens  2009-08-31 @168  	local_irq_enable();
69d0ee73 Heiko Carstens  2009-08-31  169  	preempt_enable();
69d0ee73 Heiko Carstens  2009-08-31  170  }
69d0ee73 Heiko Carstens  2009-08-31  171  

:::::: The code at line 126 was first introduced by commit
:::::: 69d0ee7377eef808e34ba5542b554ec97244b871 locking: Move spinlock function bodies to header file

:::::: TO: Heiko Carstens <heiko.carstens@...ibm.com>
:::::: CC: Ingo Molnar <mingo@...e.hu>

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

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ