Hi Andrii, I love your patch! Perhaps something to improve: [auto build test WARNING on bpf-next/master] [also build test WARNING on next-20200512] [cannot apply to bpf/master rcu/dev v5.7-rc5] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Andrii-Nakryiko/BPF-ring-buffer/20200514-032857 base: https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git master config: riscv-rv32_defconfig (attached as .config) compiler: riscv32-linux-gcc (GCC) 9.3.0 reproduce: wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day GCC_VERSION=9.3.0 make.cross ARCH=riscv If you fix the issue, kindly add following tag as appropriate Reported-by: kbuild test robot All warnings (new ones prefixed by >>): In file included from include/linux/kernel.h:11, from include/linux/list.h:9, from include/linux/timer.h:5, from include/linux/workqueue.h:9, from include/linux/bpf.h:9, from kernel/bpf/ringbuf.c:1: kernel/bpf/ringbuf.c: In function 'bpf_ringbuf_commit': include/linux/compiler.h:350:38: error: call to '__compiletime_assert_155' declared with attribute error: Need native word sized stores/loads for atomicity. 350 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__) | ^ include/linux/compiler.h:331:4: note: in definition of macro '__compiletime_assert' 331 | prefix ## suffix(); | ^~~~~~ include/linux/compiler.h:350:2: note: in expansion of macro '_compiletime_assert' 350 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__) | ^~~~~~~~~~~~~~~~~~~ include/linux/compiler.h:353:2: note: in expansion of macro 'compiletime_assert' 353 | compiletime_assert(__native_word(t), | ^~~~~~~~~~~~~~~~~~ >> arch/riscv/include/asm/barrier.h:40:2: note: in expansion of macro 'compiletime_assert_atomic_type' 40 | compiletime_assert_atomic_type(*p); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ include/asm-generic/barrier.h:157:29: note: in expansion of macro '__smp_load_acquire' 157 | #define smp_load_acquire(p) __smp_load_acquire(p) | ^~~~~~~~~~~~~~~~~~ kernel/bpf/ringbuf.c:354:13: note: in expansion of macro 'smp_load_acquire' 354 | cons_pos = smp_load_acquire(&rb->consumer_pos) & rb->mask; | ^~~~~~~~~~~~~~~~ vim +/compiletime_assert_atomic_type +40 arch/riscv/include/asm/barrier.h 8d235b174af5d0 Andrea Parri 2018-02-27 36 8d235b174af5d0 Andrea Parri 2018-02-27 37 #define __smp_load_acquire(p) \ 8d235b174af5d0 Andrea Parri 2018-02-27 38 ({ \ 8d235b174af5d0 Andrea Parri 2018-02-27 39 typeof(*p) ___p1 = READ_ONCE(*p); \ 8d235b174af5d0 Andrea Parri 2018-02-27 @40 compiletime_assert_atomic_type(*p); \ 8d235b174af5d0 Andrea Parri 2018-02-27 41 RISCV_FENCE(r,rw); \ 8d235b174af5d0 Andrea Parri 2018-02-27 42 ___p1; \ 8d235b174af5d0 Andrea Parri 2018-02-27 43 }) 8d235b174af5d0 Andrea Parri 2018-02-27 44 :::::: The code at line 40 was first introduced by commit :::::: 8d235b174af5d0af35ff206c15041fc2b02a0993 riscv/barrier: Define __smp_{store_release,load_acquire} :::::: TO: Andrea Parri :::::: CC: Palmer Dabbelt --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org