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>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Mon, 17 Aug 2020 07:31:25 +0800
From:   kernel test robot <lkp@...el.com>
To:     Randy Dunlap <rdunlap@...radead.org>, linux-kernel@...r.kernel.org
Cc:     kbuild-all@...ts.01.org, clang-built-linux@...glegroups.com,
        Randy Dunlap <rdunlap@...radead.org>,
        Peter Zijlstra <peterz@...radead.org>,
        Ingo Molnar <mingo@...nel.org>
Subject: Re: [PATCH] seqlock: <linux/seqlock.h>: fix multiple kernel-doc
 warnings

Hi Randy,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on linus/master]
[also build test WARNING on v5.9-rc1 next-20200814]
[cannot apply to tip/locking/core linux/master]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/0day-ci/linux/commits/Randy-Dunlap/seqlock-linux-seqlock-h-fix-multiple-kernel-doc-warnings/20200817-062836
base:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 9123e3a74ec7b934a4a099e98af6a61c2f80bbf5
config: s390-randconfig-r025-20200817 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project ab9fc8bae805c785066779e76e7846aabad5609e)
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 s390 cross compiling tool for clang build
        # apt-get install binutils-s390x-linux-gnu
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=s390 

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

All warnings (new ones prefixed by >>):

   In file included from arch/s390/kernel/asm-offsets.c:11:
   In file included from include/linux/kvm_host.h:12:
   In file included from include/linux/sched.h:20:
   In file included from include/linux/hrtimer.h:20:
   include/linux/seqlock.h:156:8: error: 'inline' can only appear on functions
   static __always_inline void                                             \
          ^
   include/linux/compiler_attributes.h:70:41: note: expanded from macro '__always_inline'
   #define __always_inline                 inline __attribute__((__always_inline__))
                                           ^
   include/linux/compiler_types.h:144:16: note: expanded from macro 'inline'
   #define inline inline __gnu_inline __inline_maybe_unused notrace
                  ^
   In file included from arch/s390/kernel/asm-offsets.c:11:
   In file included from include/linux/kvm_host.h:12:
   In file included from include/linux/sched.h:20:
   In file included from include/linux/hrtimer.h:20:
   include/linux/seqlock.h:156:8: warning: '__gnu_inline__' attribute only applies to functions [-Wignored-attributes]
   include/linux/compiler_attributes.h:70:41: note: expanded from macro '__always_inline'
   #define __always_inline                 inline __attribute__((__always_inline__))
                                           ^
   include/linux/compiler_types.h:144:23: note: expanded from macro 'inline'
   #define inline inline __gnu_inline __inline_maybe_unused notrace
                         ^
   include/linux/compiler_attributes.h:167:56: note: expanded from macro '__gnu_inline'
   #define __gnu_inline                    __attribute__((__gnu_inline__))
                                                          ^
   In file included from arch/s390/kernel/asm-offsets.c:11:
   In file included from include/linux/kvm_host.h:12:
   In file included from include/linux/sched.h:20:
   In file included from include/linux/hrtimer.h:20:
>> include/linux/seqlock.h:156:8: warning: '__no_instrument_function__' attribute only applies to functions [-Wignored-attributes]
   include/linux/compiler_attributes.h:70:41: note: expanded from macro '__always_inline'
   #define __always_inline                 inline __attribute__((__always_inline__))
                                           ^
   include/linux/compiler_types.h:144:58: note: expanded from macro 'inline'
   #define inline inline __gnu_inline __inline_maybe_unused notrace
                                                            ^
   include/linux/compiler_types.h:124:34: note: expanded from macro 'notrace'
   #define notrace                 __attribute__((__no_instrument_function__))
                                                  ^
   In file included from arch/s390/kernel/asm-offsets.c:11:
   In file included from include/linux/kvm_host.h:12:
   In file included from include/linux/sched.h:20:
   In file included from include/linux/hrtimer.h:20:
   include/linux/seqlock.h:156:8: warning: '__always_inline__' attribute only applies to functions [-Wignored-attributes]
   include/linux/compiler_attributes.h:70:63: note: expanded from macro '__always_inline'
   #define __always_inline                 inline __attribute__((__always_inline__))
                                                                 ^
   In file included from arch/s390/kernel/asm-offsets.c:11:
   In file included from include/linux/kvm_host.h:12:
   In file included from include/linux/sched.h:20:
   In file included from include/linux/hrtimer.h:20:
   include/linux/seqlock.h:156:34: error: variable has incomplete type 'void'
   static __always_inline void                                             \
                                                                           ^
   include/linux/seqlock.h:157:10: error: expected ';' after top level declarator
   seqcount_##lockname##_init(seqcount_##lockname##_t *s, locktype *lock)  \
            ^
            ;
   include/linux/seqlock.h:213:1: error: unknown type name 'seqcount_raw_spinlock_t'
   SEQCOUNT_LOCKTYPE(raw_spinlock_t,       raw_spinlock,   false,  s->lock)
   ^
   include/linux/seqlock.h:177:29: note: expanded from macro 'SEQCOUNT_LOCKTYPE'
   __seqcount_##lockname##_ptr(seqcount_##lockname##_t *s)                 \
                               ^
   <scratch space>:28:1: note: expanded from here
   seqcount_raw_spinlock_t
   ^
   In file included from arch/s390/kernel/asm-offsets.c:11:
   In file included from include/linux/kvm_host.h:12:
   In file included from include/linux/sched.h:20:
   In file included from include/linux/hrtimer.h:20:
   include/linux/seqlock.h:213:1: error: unknown type name 'seqcount_raw_spinlock_t'
   include/linux/seqlock.h:183:37: note: expanded from macro 'SEQCOUNT_LOCKTYPE'
   __seqcount_##lockname##_preemptible(seqcount_##lockname##_t *s)         \
                                       ^
   <scratch space>:32:1: note: expanded from here
   seqcount_raw_spinlock_t
   ^
   In file included from arch/s390/kernel/asm-offsets.c:11:
   In file included from include/linux/kvm_host.h:12:
   In file included from include/linux/sched.h:20:
   In file included from include/linux/hrtimer.h:20:
   include/linux/seqlock.h:213:1: error: unknown type name 'seqcount_raw_spinlock_t'
   include/linux/seqlock.h:189:32: note: expanded from macro 'SEQCOUNT_LOCKTYPE'
   __seqcount_##lockname##_assert(seqcount_##lockname##_t *s)              \
                                  ^
   <scratch space>:36:1: note: expanded from here
   seqcount_raw_spinlock_t
   ^
   In file included from arch/s390/kernel/asm-offsets.c:11:
   In file included from include/linux/kvm_host.h:12:
   In file included from include/linux/sched.h:20:
   In file included from include/linux/hrtimer.h:20:
   include/linux/seqlock.h:751:17: error: implicit declaration of function '__seqcount_ptr' [-Werror,-Wimplicit-function-declaration]
           unsigned ret = read_seqcount_begin(&sl->seqcount);
                          ^
   include/linux/seqlock.h:306:24: note: expanded from macro 'read_seqcount_begin'
           read_seqcount_t_begin(__seqcount_ptr(s))
                                 ^
   include/linux/seqlock.h:248:28: note: expanded from macro '__seqcount_ptr'
   #define __seqcount_ptr(s)               __seqprop(s, ptr)
                                           ^
   include/linux/seqlock.h:241:15: note: expanded from macro '__seqprop'
           seqcount_t:             __seqcount_##prop((void *)(s)),         \
                                   ^
   <scratch space>:129:1: note: expanded from here
   __seqcount_ptr
   ^
   include/linux/seqlock.h:751:17: note: did you mean '__seqcount_init'?
   include/linux/seqlock.h:306:24: note: expanded from macro 'read_seqcount_begin'
           read_seqcount_t_begin(__seqcount_ptr(s))
                                 ^
   include/linux/seqlock.h:248:28: note: expanded from macro '__seqcount_ptr'
   #define __seqcount_ptr(s)               __seqprop(s, ptr)
                                           ^
   include/linux/seqlock.h:241:15: note: expanded from macro '__seqprop'
           seqcount_t:             __seqcount_##prop((void *)(s)),         \
                                   ^
   <scratch space>:129:1: note: expanded from here
   __seqcount_ptr
   ^
   include/linux/seqlock.h:71:20: note: '__seqcount_init' declared here
   static inline void __seqcount_init(seqcount_t *s, const char *name,
                      ^
   include/linux/seqlock.h:751:17: error: unknown type name 'seqcount_raw_spinlock_t'; did you mean 'seqcount_spinlock_t'?
           unsigned ret = read_seqcount_begin(&sl->seqcount);
                          ^
   include/linux/seqlock.h:306:24: note: expanded from macro 'read_seqcount_begin'
           read_seqcount_t_begin(__seqcount_ptr(s))
                                 ^

# https://github.com/0day-ci/linux/commit/360da27b2632939e5188f48d211b8a39cfdb8cde
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Randy-Dunlap/seqlock-linux-seqlock-h-fix-multiple-kernel-doc-warnings/20200817-062836
git checkout 360da27b2632939e5188f48d211b8a39cfdb8cde
vim +/__no_instrument_function__ +156 include/linux/seqlock.h

   139	
   140	/**
   141	 * typedef seqcount_LOCKNAME_t - sequence counter with LOCKTYPE associated
   142	 * @seqcount:	The real sequence counter
   143	 * @lock:	Pointer to the associated spinlock
   144	 *
   145	 * A plain sequence counter with external writer synchronization by a
   146	 * spinlock. The spinlock is associated to the sequence count in the
   147	 * static initializer or init function. This enables lockdep to validate
   148	 * that the write side critical section is properly serialized.
   149	 */
   150	
   151	/*
   152	 * seqcount_LOCKNAME_init() - runtime initializer for seqcount_LOCKNAME_t
   153	 * @s:		Pointer to the seqcount_LOCKNAME_t instance
   154	 * @lock:	Pointer to the associated LOCKTYPE
   155	 */
 > 156	static __always_inline void						\
   157	seqcount_##lockname##_init(seqcount_##lockname##_t *s, locktype *lock)	\
   158	{									\
   159		seqcount_init(&s->seqcount);					\
   160		__SEQ_LOCK(s->lock = lock);					\
   161	}									\
   162	

---
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" (21503 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ