CC: [email protected]
CC: [email protected]
TO: "Matthew Wilcox (Oracle)" <[email protected]>

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-rcu.git 
willy-maple
head:   7e346d2845b4bd77663394f39fa70456e0084c86
commit: 7e346d2845b4bd77663394f39fa70456e0084c86 [2/2] vma_iterator and 
/proc/$pid/maps
:::::: branch date: 22 hours ago
:::::: commit date: 22 hours ago
config: mips-randconfig-s031-20210202 (attached as .config)
compiler: mips64-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/paulmck/linux-rcu.git/commit/?id=7e346d2845b4bd77663394f39fa70456e0084c86
        git remote add rcu 
https://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-rcu.git
        git fetch --no-tags rcu willy-maple
        git checkout 7e346d2845b4bd77663394f39fa70456e0084c86
        # 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=mips 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <[email protected]>


"sparse warnings: (new ones prefixed by >>)"
   command-line: note: in included file:
   builtin:1:9: sparse: sparse: preprocessor token __ATOMIC_ACQUIRE redefined
   builtin:0:0: sparse: this was the original definition
   builtin:1:9: sparse: sparse: preprocessor token __ATOMIC_SEQ_CST redefined
   builtin:0:0: sparse: this was the original definition
   builtin:1:9: sparse: sparse: preprocessor token __ATOMIC_ACQ_REL redefined
   builtin:0:0: sparse: this was the original definition
   builtin:1:9: sparse: sparse: preprocessor token __ATOMIC_RELEASE redefined
   builtin:0:0: sparse: this was the original definition
>> fs/proc/task_mmu.c:141:13: sparse: sparse: context imbalance in 'm_start' - 
>> different lock contexts for basic block
   fs/proc/task_mmu.c: note: in included file (through include/linux/rbtree.h, 
include/linux/mm_types.h, include/linux/mmzone.h, ...):
   include/linux/rcupdate.h:698:9: sparse: sparse: context imbalance in 
'm_stop' - unexpected unlock
   fs/proc/task_mmu.c:583:17: sparse: sparse: context imbalance in 
'smaps_pte_range' - unexpected unlock
   fs/proc/task_mmu.c:1130:28: sparse: sparse: context imbalance in 
'clear_refs_pte_range' - unexpected unlock
   fs/proc/task_mmu.c:1467:28: sparse: sparse: context imbalance in 
'pagemap_pmd_range' - unexpected unlock

vim +/m_start +141 fs/proc/task_mmu.c

7e346d2845b4bd Matthew Wilcox (Oracle  2020-03-01  140) 
0c255321f879c3 Oleg Nesterov           2014-10-09 @141  static void 
*m_start(struct seq_file *m, loff_t *ppos)
a6198797cc3fd6 Matt Mackall            2008-02-04  142  {
a6198797cc3fd6 Matt Mackall            2008-02-04  143          struct 
proc_maps_private *priv = m->private;
4781f2c3abddc4 Matthew Wilcox (Oracle  2020-04-06  144)         unsigned long 
last_addr = *ppos;
a6198797cc3fd6 Matt Mackall            2008-02-04  145          struct 
mm_struct *mm;
0c255321f879c3 Oleg Nesterov           2014-10-09  146          struct 
vm_area_struct *vma;
a6198797cc3fd6 Matt Mackall            2008-02-04  147  
c2e88d22e8ea69 Matthew Wilcox (Oracle  2020-04-06  148)         /* See 
m_next(). Zero at the start or after lseek. */
b8c20a9b85b057 Oleg Nesterov           2014-10-09  149          if (last_addr 
== -1UL)
b8c20a9b85b057 Oleg Nesterov           2014-10-09  150                  return 
NULL;
b8c20a9b85b057 Oleg Nesterov           2014-10-09  151  
2c03376d2db005 Oleg Nesterov           2014-10-09  152          priv->task = 
get_proc_task(priv->inode);
a6198797cc3fd6 Matt Mackall            2008-02-04  153          if (!priv->task)
ec6fd8a4355cda Al Viro                 2011-02-15  154                  return 
ERR_PTR(-ESRCH);
a6198797cc3fd6 Matt Mackall            2008-02-04  155  
29a40ace841cba Oleg Nesterov           2014-10-09  156          mm = priv->mm;
d07ded611e46d2 Matthew Wilcox (Oracle  2020-04-06  157)         if (!mm || 
!mmget_not_zero(mm)) {
d07ded611e46d2 Matthew Wilcox (Oracle  2020-04-06  158)                 
put_task_struct(priv->task);
d07ded611e46d2 Matthew Wilcox (Oracle  2020-04-06  159)                 
priv->task = NULL;
29a40ace841cba Oleg Nesterov           2014-10-09  160                  return 
NULL;
d07ded611e46d2 Matthew Wilcox (Oracle  2020-04-06  161)         }
a6198797cc3fd6 Matt Mackall            2008-02-04  162  
7e346d2845b4bd Matthew Wilcox (Oracle  2020-03-01  163)         
vma_iter_init(&priv->iter, mm, last_addr);
8a713e7df3352b Konstantin Khlebnikov   2019-07-11  164  
9e7814404b77c3 KAMEZAWA Hiroyuki       2012-10-19  165          
hold_task_mempolicy(priv);
a6198797cc3fd6 Matt Mackall            2008-02-04  166  
7e346d2845b4bd Matthew Wilcox (Oracle  2020-03-01  167)         rcu_read_lock();
7e346d2845b4bd Matthew Wilcox (Oracle  2020-03-01  168)         if (*ppos == 
-2UL)
7e346d2845b4bd Matthew Wilcox (Oracle  2020-03-01  169)                 return 
get_gate_vma(priv->mm);
a6198797cc3fd6 Matt Mackall            2008-02-04  170  
7e346d2845b4bd Matthew Wilcox (Oracle  2020-03-01  171)         return 
proc_get_vma(priv, ppos);
a6198797cc3fd6 Matt Mackall            2008-02-04  172  }
a6198797cc3fd6 Matt Mackall            2008-02-04  173  

:::::: The code at line 141 was first introduced by commit
:::::: 0c255321f879c36bd74f58f9c7ed235ea6b919cb fs/proc/task_mmu.c: simplify 
m_start() to make it readable

:::::: TO: Oleg Nesterov <[email protected]>
:::::: CC: Linus Torvalds <[email protected]>

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/[email protected]

Attachment: .config.gz
Description: application/gzip

_______________________________________________
kbuild mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to