From: kbuild test robot <fengguang.wu@intel.com>
Cc: kbuild-all@01.org, Johannes Weiner <hannes@cmpxchg.org>,
Mel Gorman <mgorman@suse.de>,
Andrew Morton <akpm@linux-foundation.org>,
Linux Memory Management List <linux-mm@kvack.org>
Subject: [mmotm:master 201/309] arch/m68k/include/asm/atomic.h:74:2: note: in expansion of macro 'ATOMIC_OP'
Date: Thu, 23 Jun 2016 10:57:22 +0800 [thread overview]
Message-ID: <201606231019.Fi18pXbK%fengguang.wu@intel.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 6027 bytes --]
tree: git://git.cmpxchg.org/linux-mmotm.git master
head: 90fbe8d8441dfa4fc00ac1bc49bc695ec2659b8e
commit: 5c3cf7b159aee92080899618bd0b578db6c0de85 [201/309] mm: move vmscan writes and file write accounting to the node
config: m68k-sun3_defconfig (attached as .config)
compiler: m68k-linux-gcc (GCC) 4.9.0
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
git checkout 5c3cf7b159aee92080899618bd0b578db6c0de85
# save the attached .config to linux build tree
make.cross ARCH=m68k
All warnings (new ones prefixed by >>):
In file included from include/linux/atomic.h:4:0,
from include/linux/spinlock.h:406,
from include/linux/wait.h:8,
from include/linux/fs.h:5,
from include/linux/dax.h:4,
from mm/filemap.c:14:
mm/filemap.c: In function '__delete_from_page_cache':
arch/m68k/include/asm/atomic.h:36:2: warning: array subscript is above array bounds [-Warray-bounds]
__asm__ __volatile__(#asm_op "l %1,%0" : "+m" (*v) : ASM_DI (i));\
^
>> arch/m68k/include/asm/atomic.h:74:2: note: in expansion of macro 'ATOMIC_OP'
ATOMIC_OP(op, c_op, asm_op) \
^
>> arch/m68k/include/asm/atomic.h:77:1: note: in expansion of macro 'ATOMIC_OPS'
ATOMIC_OPS(add, +=, add)
^
--
In file included from include/linux/atomic.h:4:0,
from include/linux/spinlock.h:406,
from include/linux/wait.h:8,
from include/linux/fs.h:5,
from mm/shmem.c:24:
mm/shmem.c: In function 'shmem_add_to_page_cache':
arch/m68k/include/asm/atomic.h:36:2: warning: array subscript is above array bounds [-Warray-bounds]
__asm__ __volatile__(#asm_op "l %1,%0" : "+m" (*v) : ASM_DI (i));\
^
>> arch/m68k/include/asm/atomic.h:74:2: note: in expansion of macro 'ATOMIC_OP'
ATOMIC_OP(op, c_op, asm_op) \
^
>> arch/m68k/include/asm/atomic.h:77:1: note: in expansion of macro 'ATOMIC_OPS'
ATOMIC_OPS(add, +=, add)
^
vim +/ATOMIC_OP +74 arch/m68k/include/asm/atomic.h
69f99746 Greg Ungerer 2010-09-08 30 #define ASM_DI "di"
49148020 Sam Ravnborg 2009-01-16 31 #endif
b417b717 Geert Uytterhoeven 2010-05-23 32
d839bae4 Peter Zijlstra 2014-03-23 33 #define ATOMIC_OP(op, c_op, asm_op) \
d839bae4 Peter Zijlstra 2014-03-23 34 static inline void atomic_##op(int i, atomic_t *v) \
d839bae4 Peter Zijlstra 2014-03-23 35 { \
d839bae4 Peter Zijlstra 2014-03-23 @36 __asm__ __volatile__(#asm_op "l %1,%0" : "+m" (*v) : ASM_DI (i));\
d839bae4 Peter Zijlstra 2014-03-23 37 } \
d839bae4 Peter Zijlstra 2014-03-23 38
d839bae4 Peter Zijlstra 2014-03-23 39 #ifdef CONFIG_RMW_INSNS
d839bae4 Peter Zijlstra 2014-03-23 40
d839bae4 Peter Zijlstra 2014-03-23 41 #define ATOMIC_OP_RETURN(op, c_op, asm_op) \
d839bae4 Peter Zijlstra 2014-03-23 42 static inline int atomic_##op##_return(int i, atomic_t *v) \
d839bae4 Peter Zijlstra 2014-03-23 43 { \
d839bae4 Peter Zijlstra 2014-03-23 44 int t, tmp; \
d839bae4 Peter Zijlstra 2014-03-23 45 \
d839bae4 Peter Zijlstra 2014-03-23 46 __asm__ __volatile__( \
d839bae4 Peter Zijlstra 2014-03-23 47 "1: movel %2,%1\n" \
d839bae4 Peter Zijlstra 2014-03-23 48 " " #asm_op "l %3,%1\n" \
d839bae4 Peter Zijlstra 2014-03-23 49 " casl %2,%1,%0\n" \
d839bae4 Peter Zijlstra 2014-03-23 50 " jne 1b" \
d839bae4 Peter Zijlstra 2014-03-23 51 : "+m" (*v), "=&d" (t), "=&d" (tmp) \
d839bae4 Peter Zijlstra 2014-03-23 52 : "g" (i), "2" (atomic_read(v))); \
d839bae4 Peter Zijlstra 2014-03-23 53 return t; \
69f99746 Greg Ungerer 2010-09-08 54 }
69f99746 Greg Ungerer 2010-09-08 55
d839bae4 Peter Zijlstra 2014-03-23 56 #else
d839bae4 Peter Zijlstra 2014-03-23 57
d839bae4 Peter Zijlstra 2014-03-23 58 #define ATOMIC_OP_RETURN(op, c_op, asm_op) \
d839bae4 Peter Zijlstra 2014-03-23 59 static inline int atomic_##op##_return(int i, atomic_t * v) \
d839bae4 Peter Zijlstra 2014-03-23 60 { \
d839bae4 Peter Zijlstra 2014-03-23 61 unsigned long flags; \
d839bae4 Peter Zijlstra 2014-03-23 62 int t; \
d839bae4 Peter Zijlstra 2014-03-23 63 \
d839bae4 Peter Zijlstra 2014-03-23 64 local_irq_save(flags); \
d839bae4 Peter Zijlstra 2014-03-23 65 t = (v->counter c_op i); \
d839bae4 Peter Zijlstra 2014-03-23 66 local_irq_restore(flags); \
d839bae4 Peter Zijlstra 2014-03-23 67 \
d839bae4 Peter Zijlstra 2014-03-23 68 return t; \
69f99746 Greg Ungerer 2010-09-08 69 }
69f99746 Greg Ungerer 2010-09-08 70
d839bae4 Peter Zijlstra 2014-03-23 71 #endif /* CONFIG_RMW_INSNS */
d839bae4 Peter Zijlstra 2014-03-23 72
d839bae4 Peter Zijlstra 2014-03-23 73 #define ATOMIC_OPS(op, c_op, asm_op) \
d839bae4 Peter Zijlstra 2014-03-23 @74 ATOMIC_OP(op, c_op, asm_op) \
d839bae4 Peter Zijlstra 2014-03-23 75 ATOMIC_OP_RETURN(op, c_op, asm_op)
d839bae4 Peter Zijlstra 2014-03-23 76
d839bae4 Peter Zijlstra 2014-03-23 @77 ATOMIC_OPS(add, +=, add)
d839bae4 Peter Zijlstra 2014-03-23 78 ATOMIC_OPS(sub, -=, sub)
d839bae4 Peter Zijlstra 2014-03-23 79
74b1bc50 Peter Zijlstra 2014-04-23 80 ATOMIC_OP(and, &=, and)
:::::: The code at line 74 was first introduced by commit
:::::: d839bae4269aea46bff4133066a411cfba5c7c46 locking,arch,m68k: Fold atomic_ops
:::::: TO: Peter Zijlstra <peterz@infradead.org>
:::::: CC: Ingo Molnar <mingo@kernel.org>
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
[-- Attachment #2: .config.gz --]
[-- Type: application/octet-stream, Size: 11736 bytes --]
reply other threads:[~2016-06-23 2:58 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201606231019.Fi18pXbK%fengguang.wu@intel.com \
--to=fengguang.wu@intel.com \
--cc=akpm@linux-foundation.org \
--cc=hannes@cmpxchg.org \
--cc=kbuild-all@01.org \
--cc=linux-mm@kvack.org \
--cc=mgorman@suse.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox