Re: [PATCH v5 3/3] locking/mutex: Ensure forward progress of waiter-spinner

From: kbuild test robot
Date: Wed Aug 10 2016 - 22:01:50 EST


Hi Waiman,

[auto build test ERROR on tip/locking/core]
[also build test ERROR on v4.8-rc1 next-20160809]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url: https://github.com/0day-ci/linux/commits/Waiman-Long/locking-mutex-Enable-optimistic-spinning-of-lock-waiter/20160811-074736
config: sparc64-defconfig (attached as .config)
compiler: sparc64-linux-gnu-gcc (Debian 5.4.0-6) 5.4.0 20160609
reproduce:
wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
make.cross ARCH=sparc64

All error/warnings (new ones prefixed by >>):

In file included from arch/sparc/include/asm/processor.h:4:0,
from include/linux/mutex.h:19,
from kernel/locking/mutex.c:20:
kernel/locking/mutex.c: In function 'mutex_optimistic_spin':
>> arch/sparc/include/asm/processor_64.h:208:21: error: expected expression before 'asm'
#define cpu_relax() asm volatile("\n99:\n\t" \
^
>> arch/sparc/include/asm/processor_64.h:219:32: note: in expansion of macro 'cpu_relax'
#define cpu_relax_lowlatency() cpu_relax()
^
kernel/locking/mutex.c:355:10: note: in expansion of macro 'cpu_relax_lowlatency'
for (;; cpu_relax_lowlatency()) {
^

vim +/cpu_relax +219 arch/sparc/include/asm/processor_64.h

f5e706ad8 include/asm-sparc/processor_64.h Sam Ravnborg 2008-07-17 202
187818cd6 arch/sparc/include/asm/processor_64.h David S. Miller 2012-10-28 203 /* Please see the commentary in asm/backoff.h for a description of
08f800730 arch/sparc/include/asm/processor_64.h Adam Buchbinder 2016-03-04 204 * what these instructions are doing and how they have been chosen.
187818cd6 arch/sparc/include/asm/processor_64.h David S. Miller 2012-10-28 205 * To make a long story short, we are trying to yield the current cpu
187818cd6 arch/sparc/include/asm/processor_64.h David S. Miller 2012-10-28 206 * strand during busy loops.
187818cd6 arch/sparc/include/asm/processor_64.h David S. Miller 2012-10-28 207 */
e9b9eb59f arch/sparc/include/asm/processor_64.h David S. Miller 2012-10-27 @208 #define cpu_relax() asm volatile("\n99:\n\t" \
270c10e00 arch/sparc/include/asm/processor_64.h David S. Miller 2012-10-27 209 "rd %%ccr, %%g0\n\t" \
e9b9eb59f arch/sparc/include/asm/processor_64.h David S. Miller 2012-10-27 210 "rd %%ccr, %%g0\n\t" \
e9b9eb59f arch/sparc/include/asm/processor_64.h David S. Miller 2012-10-27 211 "rd %%ccr, %%g0\n\t" \
187818cd6 arch/sparc/include/asm/processor_64.h David S. Miller 2012-10-28 212 ".section .pause_3insn_patch,\"ax\"\n\t"\
e9b9eb59f arch/sparc/include/asm/processor_64.h David S. Miller 2012-10-27 213 ".word 99b\n\t" \
e9b9eb59f arch/sparc/include/asm/processor_64.h David S. Miller 2012-10-27 214 "wr %%g0, 128, %%asr27\n\t" \
e9b9eb59f arch/sparc/include/asm/processor_64.h David S. Miller 2012-10-27 215 "nop\n\t" \
e9b9eb59f arch/sparc/include/asm/processor_64.h David S. Miller 2012-10-27 216 "nop\n\t" \
e9b9eb59f arch/sparc/include/asm/processor_64.h David S. Miller 2012-10-27 217 ".previous" \
270c10e00 arch/sparc/include/asm/processor_64.h David S. Miller 2012-10-27 218 ::: "memory")
3a6bfbc91 arch/sparc/include/asm/processor_64.h Davidlohr Bueso 2014-06-29 @219 #define cpu_relax_lowlatency() cpu_relax()
f5e706ad8 include/asm-sparc/processor_64.h Sam Ravnborg 2008-07-17 220
f5e706ad8 include/asm-sparc/processor_64.h Sam Ravnborg 2008-07-17 221 /* Prefetch support. This is tuned for UltraSPARC-III and later.
f5e706ad8 include/asm-sparc/processor_64.h Sam Ravnborg 2008-07-17 222 * UltraSPARC-I will treat these as nops, and UltraSPARC-II has

:::::: The code at line 219 was first introduced by commit
:::::: 3a6bfbc91df04b081a44d419e0260bad54abddf7 arch, locking: Ciao arch_mutex_cpu_relax()

:::::: TO: Davidlohr Bueso <davidlohr@xxxxxx>
:::::: CC: Ingo Molnar <mingo@xxxxxxxxxx>

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

Attachment: .config.gz
Description: Binary data