* kernel/bpf/percpu_freelist.c:176:17: sparse: sparse: context imbalance in '___pcpu_freelist_pop_nmi' - different lock contexts for basic block
@ 2021-03-23 9:22 kernel test robot
0 siblings, 0 replies; 6+ messages in thread
From: kernel test robot @ 2021-03-23 9:22 UTC (permalink / raw)
To: kbuild
[-- Attachment #1: Type: text/plain, Size: 4601 bytes --]
CC: kbuild-all(a)lists.01.org
CC: linux-kernel(a)vger.kernel.org
TO: Song Liu <songliubraving@fb.com>
CC: Daniel Borkmann <daniel@iogearbox.net>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 84196390620ac0e5070ae36af84c137c6216a7dc
commit: 39d8f0d1026a990604770a658708f5845f7dbec0 bpf: Use raw_spin_trylock() for pcpu_freelist_push/pop in NMI
date: 6 months ago
:::::: branch date: 15 hours ago
:::::: commit date: 6 months ago
config: ia64-randconfig-s031-20210322 (attached as .config)
compiler: ia64-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
# apt-get install sparse
# sparse version: v0.6.3-277-gc089cd2d-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=39d8f0d1026a990604770a658708f5845f7dbec0
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 39d8f0d1026a990604770a658708f5845f7dbec0
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=ia64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
sparse warnings: (new ones prefixed by >>)
>> kernel/bpf/percpu_freelist.c:176:17: sparse: sparse: context imbalance in '___pcpu_freelist_pop_nmi' - different lock contexts for basic block
vim +/___pcpu_freelist_pop_nmi +176 kernel/bpf/percpu_freelist.c
39d8f0d1026a99 Song Liu 2020-10-05 156
39d8f0d1026a99 Song Liu 2020-10-05 157 static struct pcpu_freelist_node *
39d8f0d1026a99 Song Liu 2020-10-05 158 ___pcpu_freelist_pop_nmi(struct pcpu_freelist *s)
39d8f0d1026a99 Song Liu 2020-10-05 159 {
39d8f0d1026a99 Song Liu 2020-10-05 160 struct pcpu_freelist_head *head;
39d8f0d1026a99 Song Liu 2020-10-05 161 struct pcpu_freelist_node *node;
39d8f0d1026a99 Song Liu 2020-10-05 162 int orig_cpu, cpu;
39d8f0d1026a99 Song Liu 2020-10-05 163
39d8f0d1026a99 Song Liu 2020-10-05 164 orig_cpu = cpu = raw_smp_processor_id();
39d8f0d1026a99 Song Liu 2020-10-05 165 while (1) {
39d8f0d1026a99 Song Liu 2020-10-05 166 head = per_cpu_ptr(s->freelist, cpu);
39d8f0d1026a99 Song Liu 2020-10-05 167 if (raw_spin_trylock(&head->lock)) {
39d8f0d1026a99 Song Liu 2020-10-05 168 node = head->first;
39d8f0d1026a99 Song Liu 2020-10-05 169 if (node) {
39d8f0d1026a99 Song Liu 2020-10-05 170 head->first = node->next;
39d8f0d1026a99 Song Liu 2020-10-05 171 raw_spin_unlock(&head->lock);
39d8f0d1026a99 Song Liu 2020-10-05 172 return node;
39d8f0d1026a99 Song Liu 2020-10-05 173 }
39d8f0d1026a99 Song Liu 2020-10-05 174 raw_spin_unlock(&head->lock);
39d8f0d1026a99 Song Liu 2020-10-05 175 }
39d8f0d1026a99 Song Liu 2020-10-05 @176 cpu = cpumask_next(cpu, cpu_possible_mask);
39d8f0d1026a99 Song Liu 2020-10-05 177 if (cpu >= nr_cpu_ids)
39d8f0d1026a99 Song Liu 2020-10-05 178 cpu = 0;
39d8f0d1026a99 Song Liu 2020-10-05 179 if (cpu == orig_cpu)
39d8f0d1026a99 Song Liu 2020-10-05 180 break;
39d8f0d1026a99 Song Liu 2020-10-05 181 }
39d8f0d1026a99 Song Liu 2020-10-05 182
39d8f0d1026a99 Song Liu 2020-10-05 183 /* cannot pop from per cpu lists, try extralist */
39d8f0d1026a99 Song Liu 2020-10-05 184 if (!raw_spin_trylock(&s->extralist.lock))
e19494edab82f5 Alexei Starovoitov 2016-03-07 185 return NULL;
39d8f0d1026a99 Song Liu 2020-10-05 186 node = s->extralist.first;
39d8f0d1026a99 Song Liu 2020-10-05 187 if (node)
39d8f0d1026a99 Song Liu 2020-10-05 188 s->extralist.first = node->next;
39d8f0d1026a99 Song Liu 2020-10-05 189 raw_spin_unlock(&s->extralist.lock);
39d8f0d1026a99 Song Liu 2020-10-05 190 return node;
e19494edab82f5 Alexei Starovoitov 2016-03-07 191 }
39d8f0d1026a99 Song Liu 2020-10-05 192
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 29090 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* kernel/bpf/percpu_freelist.c:176:17: sparse: sparse: context imbalance in '___pcpu_freelist_pop_nmi' - different lock contexts for basic block
@ 2021-08-16 11:48 kernel test robot
0 siblings, 0 replies; 6+ messages in thread
From: kernel test robot @ 2021-08-16 11:48 UTC (permalink / raw)
To: kbuild
[-- Attachment #1: Type: text/plain, Size: 4644 bytes --]
CC: kbuild-all(a)lists.01.org
CC: linux-kernel(a)vger.kernel.org
TO: Song Liu <songliubraving@fb.com>
CC: Daniel Borkmann <daniel@iogearbox.net>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 7c60610d476766e128cc4284bb6349732cbd6606
commit: 39d8f0d1026a990604770a658708f5845f7dbec0 bpf: Use raw_spin_trylock() for pcpu_freelist_push/pop in NMI
date: 11 months ago
:::::: branch date: 12 hours ago
:::::: commit date: 11 months ago
config: ia64-randconfig-s032-20210816 (attached as .config)
compiler: ia64-linux-gcc (GCC) 11.2.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.3-348-gf0e6938b-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=39d8f0d1026a990604770a658708f5845f7dbec0
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 39d8f0d1026a990604770a658708f5845f7dbec0
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=ia64 SHELL=/bin/bash kernel/bpf/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
sparse warnings: (new ones prefixed by >>)
>> kernel/bpf/percpu_freelist.c:176:17: sparse: sparse: context imbalance in '___pcpu_freelist_pop_nmi' - different lock contexts for basic block
vim +/___pcpu_freelist_pop_nmi +176 kernel/bpf/percpu_freelist.c
39d8f0d1026a99 Song Liu 2020-10-05 156
39d8f0d1026a99 Song Liu 2020-10-05 157 static struct pcpu_freelist_node *
39d8f0d1026a99 Song Liu 2020-10-05 158 ___pcpu_freelist_pop_nmi(struct pcpu_freelist *s)
39d8f0d1026a99 Song Liu 2020-10-05 159 {
39d8f0d1026a99 Song Liu 2020-10-05 160 struct pcpu_freelist_head *head;
39d8f0d1026a99 Song Liu 2020-10-05 161 struct pcpu_freelist_node *node;
39d8f0d1026a99 Song Liu 2020-10-05 162 int orig_cpu, cpu;
39d8f0d1026a99 Song Liu 2020-10-05 163
39d8f0d1026a99 Song Liu 2020-10-05 164 orig_cpu = cpu = raw_smp_processor_id();
39d8f0d1026a99 Song Liu 2020-10-05 165 while (1) {
39d8f0d1026a99 Song Liu 2020-10-05 166 head = per_cpu_ptr(s->freelist, cpu);
39d8f0d1026a99 Song Liu 2020-10-05 167 if (raw_spin_trylock(&head->lock)) {
39d8f0d1026a99 Song Liu 2020-10-05 168 node = head->first;
39d8f0d1026a99 Song Liu 2020-10-05 169 if (node) {
39d8f0d1026a99 Song Liu 2020-10-05 170 head->first = node->next;
39d8f0d1026a99 Song Liu 2020-10-05 171 raw_spin_unlock(&head->lock);
39d8f0d1026a99 Song Liu 2020-10-05 172 return node;
39d8f0d1026a99 Song Liu 2020-10-05 173 }
39d8f0d1026a99 Song Liu 2020-10-05 174 raw_spin_unlock(&head->lock);
39d8f0d1026a99 Song Liu 2020-10-05 175 }
39d8f0d1026a99 Song Liu 2020-10-05 @176 cpu = cpumask_next(cpu, cpu_possible_mask);
39d8f0d1026a99 Song Liu 2020-10-05 177 if (cpu >= nr_cpu_ids)
39d8f0d1026a99 Song Liu 2020-10-05 178 cpu = 0;
39d8f0d1026a99 Song Liu 2020-10-05 179 if (cpu == orig_cpu)
39d8f0d1026a99 Song Liu 2020-10-05 180 break;
39d8f0d1026a99 Song Liu 2020-10-05 181 }
39d8f0d1026a99 Song Liu 2020-10-05 182
39d8f0d1026a99 Song Liu 2020-10-05 183 /* cannot pop from per cpu lists, try extralist */
39d8f0d1026a99 Song Liu 2020-10-05 184 if (!raw_spin_trylock(&s->extralist.lock))
e19494edab82f5 Alexei Starovoitov 2016-03-07 185 return NULL;
39d8f0d1026a99 Song Liu 2020-10-05 186 node = s->extralist.first;
39d8f0d1026a99 Song Liu 2020-10-05 187 if (node)
39d8f0d1026a99 Song Liu 2020-10-05 188 s->extralist.first = node->next;
39d8f0d1026a99 Song Liu 2020-10-05 189 raw_spin_unlock(&s->extralist.lock);
39d8f0d1026a99 Song Liu 2020-10-05 190 return node;
e19494edab82f5 Alexei Starovoitov 2016-03-07 191 }
39d8f0d1026a99 Song Liu 2020-10-05 192
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 31812 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* kernel/bpf/percpu_freelist.c:176:17: sparse: sparse: context imbalance in '___pcpu_freelist_pop_nmi' - different lock contexts for basic block
@ 2021-05-25 9:11 kernel test robot
0 siblings, 0 replies; 6+ messages in thread
From: kernel test robot @ 2021-05-25 9:11 UTC (permalink / raw)
To: kbuild
[-- Attachment #1: Type: text/plain, Size: 4604 bytes --]
CC: kbuild-all(a)lists.01.org
CC: linux-kernel(a)vger.kernel.org
TO: Song Liu <songliubraving@fb.com>
CC: Daniel Borkmann <daniel@iogearbox.net>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: a050a6d2b7e80ca52b2f4141eaf3420d201b72b3
commit: 39d8f0d1026a990604770a658708f5845f7dbec0 bpf: Use raw_spin_trylock() for pcpu_freelist_push/pop in NMI
date: 8 months ago
:::::: branch date: 7 hours ago
:::::: commit date: 8 months ago
config: ia64-randconfig-s032-20210525 (attached as .config)
compiler: ia64-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
# apt-get install sparse
# sparse version: v0.6.3-341-g8af24329-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=39d8f0d1026a990604770a658708f5845f7dbec0
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 39d8f0d1026a990604770a658708f5845f7dbec0
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' W=1 ARCH=ia64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
sparse warnings: (new ones prefixed by >>)
>> kernel/bpf/percpu_freelist.c:176:17: sparse: sparse: context imbalance in '___pcpu_freelist_pop_nmi' - different lock contexts for basic block
vim +/___pcpu_freelist_pop_nmi +176 kernel/bpf/percpu_freelist.c
39d8f0d1026a99 Song Liu 2020-10-05 156
39d8f0d1026a99 Song Liu 2020-10-05 157 static struct pcpu_freelist_node *
39d8f0d1026a99 Song Liu 2020-10-05 158 ___pcpu_freelist_pop_nmi(struct pcpu_freelist *s)
39d8f0d1026a99 Song Liu 2020-10-05 159 {
39d8f0d1026a99 Song Liu 2020-10-05 160 struct pcpu_freelist_head *head;
39d8f0d1026a99 Song Liu 2020-10-05 161 struct pcpu_freelist_node *node;
39d8f0d1026a99 Song Liu 2020-10-05 162 int orig_cpu, cpu;
39d8f0d1026a99 Song Liu 2020-10-05 163
39d8f0d1026a99 Song Liu 2020-10-05 164 orig_cpu = cpu = raw_smp_processor_id();
39d8f0d1026a99 Song Liu 2020-10-05 165 while (1) {
39d8f0d1026a99 Song Liu 2020-10-05 166 head = per_cpu_ptr(s->freelist, cpu);
39d8f0d1026a99 Song Liu 2020-10-05 167 if (raw_spin_trylock(&head->lock)) {
39d8f0d1026a99 Song Liu 2020-10-05 168 node = head->first;
39d8f0d1026a99 Song Liu 2020-10-05 169 if (node) {
39d8f0d1026a99 Song Liu 2020-10-05 170 head->first = node->next;
39d8f0d1026a99 Song Liu 2020-10-05 171 raw_spin_unlock(&head->lock);
39d8f0d1026a99 Song Liu 2020-10-05 172 return node;
39d8f0d1026a99 Song Liu 2020-10-05 173 }
39d8f0d1026a99 Song Liu 2020-10-05 174 raw_spin_unlock(&head->lock);
39d8f0d1026a99 Song Liu 2020-10-05 175 }
39d8f0d1026a99 Song Liu 2020-10-05 @176 cpu = cpumask_next(cpu, cpu_possible_mask);
39d8f0d1026a99 Song Liu 2020-10-05 177 if (cpu >= nr_cpu_ids)
39d8f0d1026a99 Song Liu 2020-10-05 178 cpu = 0;
39d8f0d1026a99 Song Liu 2020-10-05 179 if (cpu == orig_cpu)
39d8f0d1026a99 Song Liu 2020-10-05 180 break;
39d8f0d1026a99 Song Liu 2020-10-05 181 }
39d8f0d1026a99 Song Liu 2020-10-05 182
39d8f0d1026a99 Song Liu 2020-10-05 183 /* cannot pop from per cpu lists, try extralist */
39d8f0d1026a99 Song Liu 2020-10-05 184 if (!raw_spin_trylock(&s->extralist.lock))
e19494edab82f5 Alexei Starovoitov 2016-03-07 185 return NULL;
39d8f0d1026a99 Song Liu 2020-10-05 186 node = s->extralist.first;
39d8f0d1026a99 Song Liu 2020-10-05 187 if (node)
39d8f0d1026a99 Song Liu 2020-10-05 188 s->extralist.first = node->next;
39d8f0d1026a99 Song Liu 2020-10-05 189 raw_spin_unlock(&s->extralist.lock);
39d8f0d1026a99 Song Liu 2020-10-05 190 return node;
e19494edab82f5 Alexei Starovoitov 2016-03-07 191 }
39d8f0d1026a99 Song Liu 2020-10-05 192
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 26472 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* kernel/bpf/percpu_freelist.c:176:17: sparse: sparse: context imbalance in '___pcpu_freelist_pop_nmi' - different lock contexts for basic block
@ 2021-04-25 5:05 kernel test robot
0 siblings, 0 replies; 6+ messages in thread
From: kernel test robot @ 2021-04-25 5:05 UTC (permalink / raw)
To: kbuild
[-- Attachment #1: Type: text/plain, Size: 4605 bytes --]
CC: kbuild-all(a)lists.01.org
CC: linux-kernel(a)vger.kernel.org
TO: Song Liu <songliubraving@fb.com>
CC: Daniel Borkmann <daniel@iogearbox.net>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 2a1d7946fa53cea2083e5981ff55a8176ab2be6b
commit: 39d8f0d1026a990604770a658708f5845f7dbec0 bpf: Use raw_spin_trylock() for pcpu_freelist_push/pop in NMI
date: 7 months ago
:::::: branch date: 12 hours ago
:::::: commit date: 7 months ago
config: ia64-randconfig-s031-20210425 (attached as .config)
compiler: ia64-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
# apt-get install sparse
# sparse version: v0.6.3-341-g8af24329-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=39d8f0d1026a990604770a658708f5845f7dbec0
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 39d8f0d1026a990604770a658708f5845f7dbec0
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' W=1 ARCH=ia64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
sparse warnings: (new ones prefixed by >>)
>> kernel/bpf/percpu_freelist.c:176:17: sparse: sparse: context imbalance in '___pcpu_freelist_pop_nmi' - different lock contexts for basic block
vim +/___pcpu_freelist_pop_nmi +176 kernel/bpf/percpu_freelist.c
39d8f0d1026a99 Song Liu 2020-10-05 156
39d8f0d1026a99 Song Liu 2020-10-05 157 static struct pcpu_freelist_node *
39d8f0d1026a99 Song Liu 2020-10-05 158 ___pcpu_freelist_pop_nmi(struct pcpu_freelist *s)
39d8f0d1026a99 Song Liu 2020-10-05 159 {
39d8f0d1026a99 Song Liu 2020-10-05 160 struct pcpu_freelist_head *head;
39d8f0d1026a99 Song Liu 2020-10-05 161 struct pcpu_freelist_node *node;
39d8f0d1026a99 Song Liu 2020-10-05 162 int orig_cpu, cpu;
39d8f0d1026a99 Song Liu 2020-10-05 163
39d8f0d1026a99 Song Liu 2020-10-05 164 orig_cpu = cpu = raw_smp_processor_id();
39d8f0d1026a99 Song Liu 2020-10-05 165 while (1) {
39d8f0d1026a99 Song Liu 2020-10-05 166 head = per_cpu_ptr(s->freelist, cpu);
39d8f0d1026a99 Song Liu 2020-10-05 167 if (raw_spin_trylock(&head->lock)) {
39d8f0d1026a99 Song Liu 2020-10-05 168 node = head->first;
39d8f0d1026a99 Song Liu 2020-10-05 169 if (node) {
39d8f0d1026a99 Song Liu 2020-10-05 170 head->first = node->next;
39d8f0d1026a99 Song Liu 2020-10-05 171 raw_spin_unlock(&head->lock);
39d8f0d1026a99 Song Liu 2020-10-05 172 return node;
39d8f0d1026a99 Song Liu 2020-10-05 173 }
39d8f0d1026a99 Song Liu 2020-10-05 174 raw_spin_unlock(&head->lock);
39d8f0d1026a99 Song Liu 2020-10-05 175 }
39d8f0d1026a99 Song Liu 2020-10-05 @176 cpu = cpumask_next(cpu, cpu_possible_mask);
39d8f0d1026a99 Song Liu 2020-10-05 177 if (cpu >= nr_cpu_ids)
39d8f0d1026a99 Song Liu 2020-10-05 178 cpu = 0;
39d8f0d1026a99 Song Liu 2020-10-05 179 if (cpu == orig_cpu)
39d8f0d1026a99 Song Liu 2020-10-05 180 break;
39d8f0d1026a99 Song Liu 2020-10-05 181 }
39d8f0d1026a99 Song Liu 2020-10-05 182
39d8f0d1026a99 Song Liu 2020-10-05 183 /* cannot pop from per cpu lists, try extralist */
39d8f0d1026a99 Song Liu 2020-10-05 184 if (!raw_spin_trylock(&s->extralist.lock))
e19494edab82f5 Alexei Starovoitov 2016-03-07 185 return NULL;
39d8f0d1026a99 Song Liu 2020-10-05 186 node = s->extralist.first;
39d8f0d1026a99 Song Liu 2020-10-05 187 if (node)
39d8f0d1026a99 Song Liu 2020-10-05 188 s->extralist.first = node->next;
39d8f0d1026a99 Song Liu 2020-10-05 189 raw_spin_unlock(&s->extralist.lock);
39d8f0d1026a99 Song Liu 2020-10-05 190 return node;
e19494edab82f5 Alexei Starovoitov 2016-03-07 191 }
39d8f0d1026a99 Song Liu 2020-10-05 192
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 45267 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* kernel/bpf/percpu_freelist.c:176:17: sparse: sparse: context imbalance in '___pcpu_freelist_pop_nmi' - different lock contexts for basic block
@ 2021-02-27 20:29 kernel test robot
0 siblings, 0 replies; 6+ messages in thread
From: kernel test robot @ 2021-02-27 20:29 UTC (permalink / raw)
To: kbuild
[-- Attachment #1: Type: text/plain, Size: 4602 bytes --]
CC: kbuild-all(a)lists.01.org
CC: linux-kernel(a)vger.kernel.org
TO: Song Liu <songliubraving@fb.com>
CC: Daniel Borkmann <daniel@iogearbox.net>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 5695e51619745d4fe3ec2506a2f0cd982c5e27a4
commit: 39d8f0d1026a990604770a658708f5845f7dbec0 bpf: Use raw_spin_trylock() for pcpu_freelist_push/pop in NMI
date: 5 months ago
:::::: branch date: 4 hours ago
:::::: commit date: 5 months ago
config: ia64-randconfig-s032-20210228 (attached as .config)
compiler: ia64-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
# apt-get install sparse
# sparse version: v0.6.3-241-geaceeafa-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=39d8f0d1026a990604770a658708f5845f7dbec0
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 39d8f0d1026a990604770a658708f5845f7dbec0
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=ia64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
"sparse warnings: (new ones prefixed by >>)"
>> kernel/bpf/percpu_freelist.c:176:17: sparse: sparse: context imbalance in '___pcpu_freelist_pop_nmi' - different lock contexts for basic block
vim +/___pcpu_freelist_pop_nmi +176 kernel/bpf/percpu_freelist.c
39d8f0d1026a99 Song Liu 2020-10-05 156
39d8f0d1026a99 Song Liu 2020-10-05 157 static struct pcpu_freelist_node *
39d8f0d1026a99 Song Liu 2020-10-05 158 ___pcpu_freelist_pop_nmi(struct pcpu_freelist *s)
39d8f0d1026a99 Song Liu 2020-10-05 159 {
39d8f0d1026a99 Song Liu 2020-10-05 160 struct pcpu_freelist_head *head;
39d8f0d1026a99 Song Liu 2020-10-05 161 struct pcpu_freelist_node *node;
39d8f0d1026a99 Song Liu 2020-10-05 162 int orig_cpu, cpu;
39d8f0d1026a99 Song Liu 2020-10-05 163
39d8f0d1026a99 Song Liu 2020-10-05 164 orig_cpu = cpu = raw_smp_processor_id();
39d8f0d1026a99 Song Liu 2020-10-05 165 while (1) {
39d8f0d1026a99 Song Liu 2020-10-05 166 head = per_cpu_ptr(s->freelist, cpu);
39d8f0d1026a99 Song Liu 2020-10-05 167 if (raw_spin_trylock(&head->lock)) {
39d8f0d1026a99 Song Liu 2020-10-05 168 node = head->first;
39d8f0d1026a99 Song Liu 2020-10-05 169 if (node) {
39d8f0d1026a99 Song Liu 2020-10-05 170 head->first = node->next;
39d8f0d1026a99 Song Liu 2020-10-05 171 raw_spin_unlock(&head->lock);
39d8f0d1026a99 Song Liu 2020-10-05 172 return node;
39d8f0d1026a99 Song Liu 2020-10-05 173 }
39d8f0d1026a99 Song Liu 2020-10-05 174 raw_spin_unlock(&head->lock);
39d8f0d1026a99 Song Liu 2020-10-05 175 }
39d8f0d1026a99 Song Liu 2020-10-05 @176 cpu = cpumask_next(cpu, cpu_possible_mask);
39d8f0d1026a99 Song Liu 2020-10-05 177 if (cpu >= nr_cpu_ids)
39d8f0d1026a99 Song Liu 2020-10-05 178 cpu = 0;
39d8f0d1026a99 Song Liu 2020-10-05 179 if (cpu == orig_cpu)
39d8f0d1026a99 Song Liu 2020-10-05 180 break;
39d8f0d1026a99 Song Liu 2020-10-05 181 }
39d8f0d1026a99 Song Liu 2020-10-05 182
39d8f0d1026a99 Song Liu 2020-10-05 183 /* cannot pop from per cpu lists, try extralist */
39d8f0d1026a99 Song Liu 2020-10-05 184 if (!raw_spin_trylock(&s->extralist.lock))
e19494edab82f5 Alexei Starovoitov 2016-03-07 185 return NULL;
39d8f0d1026a99 Song Liu 2020-10-05 186 node = s->extralist.first;
39d8f0d1026a99 Song Liu 2020-10-05 187 if (node)
39d8f0d1026a99 Song Liu 2020-10-05 188 s->extralist.first = node->next;
39d8f0d1026a99 Song Liu 2020-10-05 189 raw_spin_unlock(&s->extralist.lock);
39d8f0d1026a99 Song Liu 2020-10-05 190 return node;
e19494edab82f5 Alexei Starovoitov 2016-03-07 191 }
39d8f0d1026a99 Song Liu 2020-10-05 192
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 24268 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* kernel/bpf/percpu_freelist.c:176:17: sparse: sparse: context imbalance in '___pcpu_freelist_pop_nmi' - different lock contexts for basic block
@ 2021-02-04 6:27 kernel test robot
0 siblings, 0 replies; 6+ messages in thread
From: kernel test robot @ 2021-02-04 6:27 UTC (permalink / raw)
To: kbuild
[-- Attachment #1: Type: text/plain, Size: 4603 bytes --]
CC: kbuild-all(a)lists.01.org
CC: linux-kernel(a)vger.kernel.org
TO: Song Liu <songliubraving@fb.com>
CC: Daniel Borkmann <daniel@iogearbox.net>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 61556703b610a104de324e4f061dc6cf7b218b46
commit: 39d8f0d1026a990604770a658708f5845f7dbec0 bpf: Use raw_spin_trylock() for pcpu_freelist_push/pop in NMI
date: 4 months ago
:::::: branch date: 11 hours ago
:::::: commit date: 4 months ago
config: ia64-randconfig-s032-20210204 (attached as .config)
compiler: ia64-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
# apt-get install sparse
# sparse version: v0.6.3-215-g0fb77bb6-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=39d8f0d1026a990604770a658708f5845f7dbec0
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 39d8f0d1026a990604770a658708f5845f7dbec0
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=ia64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
"sparse warnings: (new ones prefixed by >>)"
>> kernel/bpf/percpu_freelist.c:176:17: sparse: sparse: context imbalance in '___pcpu_freelist_pop_nmi' - different lock contexts for basic block
vim +/___pcpu_freelist_pop_nmi +176 kernel/bpf/percpu_freelist.c
39d8f0d1026a99 Song Liu 2020-10-05 156
39d8f0d1026a99 Song Liu 2020-10-05 157 static struct pcpu_freelist_node *
39d8f0d1026a99 Song Liu 2020-10-05 158 ___pcpu_freelist_pop_nmi(struct pcpu_freelist *s)
39d8f0d1026a99 Song Liu 2020-10-05 159 {
39d8f0d1026a99 Song Liu 2020-10-05 160 struct pcpu_freelist_head *head;
39d8f0d1026a99 Song Liu 2020-10-05 161 struct pcpu_freelist_node *node;
39d8f0d1026a99 Song Liu 2020-10-05 162 int orig_cpu, cpu;
39d8f0d1026a99 Song Liu 2020-10-05 163
39d8f0d1026a99 Song Liu 2020-10-05 164 orig_cpu = cpu = raw_smp_processor_id();
39d8f0d1026a99 Song Liu 2020-10-05 165 while (1) {
39d8f0d1026a99 Song Liu 2020-10-05 166 head = per_cpu_ptr(s->freelist, cpu);
39d8f0d1026a99 Song Liu 2020-10-05 167 if (raw_spin_trylock(&head->lock)) {
39d8f0d1026a99 Song Liu 2020-10-05 168 node = head->first;
39d8f0d1026a99 Song Liu 2020-10-05 169 if (node) {
39d8f0d1026a99 Song Liu 2020-10-05 170 head->first = node->next;
39d8f0d1026a99 Song Liu 2020-10-05 171 raw_spin_unlock(&head->lock);
39d8f0d1026a99 Song Liu 2020-10-05 172 return node;
39d8f0d1026a99 Song Liu 2020-10-05 173 }
39d8f0d1026a99 Song Liu 2020-10-05 174 raw_spin_unlock(&head->lock);
39d8f0d1026a99 Song Liu 2020-10-05 175 }
39d8f0d1026a99 Song Liu 2020-10-05 @176 cpu = cpumask_next(cpu, cpu_possible_mask);
39d8f0d1026a99 Song Liu 2020-10-05 177 if (cpu >= nr_cpu_ids)
39d8f0d1026a99 Song Liu 2020-10-05 178 cpu = 0;
39d8f0d1026a99 Song Liu 2020-10-05 179 if (cpu == orig_cpu)
39d8f0d1026a99 Song Liu 2020-10-05 180 break;
39d8f0d1026a99 Song Liu 2020-10-05 181 }
39d8f0d1026a99 Song Liu 2020-10-05 182
39d8f0d1026a99 Song Liu 2020-10-05 183 /* cannot pop from per cpu lists, try extralist */
39d8f0d1026a99 Song Liu 2020-10-05 184 if (!raw_spin_trylock(&s->extralist.lock))
e19494edab82f5 Alexei Starovoitov 2016-03-07 185 return NULL;
39d8f0d1026a99 Song Liu 2020-10-05 186 node = s->extralist.first;
39d8f0d1026a99 Song Liu 2020-10-05 187 if (node)
39d8f0d1026a99 Song Liu 2020-10-05 188 s->extralist.first = node->next;
39d8f0d1026a99 Song Liu 2020-10-05 189 raw_spin_unlock(&s->extralist.lock);
39d8f0d1026a99 Song Liu 2020-10-05 190 return node;
e19494edab82f5 Alexei Starovoitov 2016-03-07 191 }
39d8f0d1026a99 Song Liu 2020-10-05 192
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 28166 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2021-08-16 11:48 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-23 9:22 kernel/bpf/percpu_freelist.c:176:17: sparse: sparse: context imbalance in '___pcpu_freelist_pop_nmi' - different lock contexts for basic block kernel test robot
-- strict thread matches above, loose matches on Subject: below --
2021-08-16 11:48 kernel test robot
2021-05-25 9:11 kernel test robot
2021-04-25 5:05 kernel test robot
2021-02-27 20:29 kernel test robot
2021-02-04 6:27 kernel test robot
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.