CC: [email protected]
TO: Lee Jones <[email protected]>

tree:   https://git.linaro.org/people/lee.jones/linux.git android-3.18-preview
head:   6ba0539cefd299adcbcf8c6bf7db5f137ee09151
commit: 8214bf079208b146e63cd0a3ce0ed335a87ce7b3 [396/992] scripts/dtc: Export 
YYLOC global declaration
:::::: branch date: 3 hours ago
:::::: commit date: 8 weeks ago
config: arm64-randconfig-s031-20210413 (attached as .config)
compiler: aarch64-linux-gcc (GCC) 5.5.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-280-g2cd6d34e-dirty
        git remote add lee-linaro 
https://git.linaro.org/people/lee.jones/linux.git
        git fetch --no-tags lee-linaro android-3.18-preview
        git checkout 8214bf079208b146e63cd0a3ce0ed335a87ce7b3
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-5.5.0 make.cross C=1 
CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=arm64 

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


sparse warnings: (new ones prefixed by >>)
>> mm/mprotect.c:39:14: sparse: sparse: context imbalance in 
>> 'lock_pte_protection' - wrong count at exit
   mm/mprotect.c:128:9: sparse: sparse: context imbalance in 'change_pte_range' 
- unexpected unlock
   In file included from arch/arm64/include/asm/mmu.h:24:0,
                    from include/linux/mm_types.h:18,
                    from include/linux/mm.h:16,
                    from mm/mprotect.c:11:
   arch/arm64/include/asm/cpufeature.h: In function 'arm64_ftr_value':
   arch/arm64/include/asm/cpufeature.h:153:68: warning: signed and unsigned 
type in conditional expression [-Wsign-compare]
      cpuid_feature_extract_field_width(val, ftrp->shift, ftrp->width) :
                                                                       ^
   In file included from include/linux/cgroup.h:11:0,
                    from include/linux/hugetlb.h:8,
                    from mm/mprotect.c:12:
   include/linux/sched.h: At top level:
   include/linux/sched.h:1067:42: warning: type qualifiers ignored on function 
return type [-Wignored-qualifiers]
    const struct sched_group_energy * const(*sched_domain_energy_f)(int cpu);
                                             ^
   In file included from include/linux/mempolicy.h:14:0,
                    from include/linux/hugetlb.h:18,
                    from mm/mprotect.c:12:
   include/linux/pagemap.h: In function 'fault_in_multipages_readable':
   include/linux/pagemap.h:633:16: warning: variable 'c' set but not used 
[-Wunused-but-set-variable]
     volatile char c;
                   ^
--
>> sound/firewire/fireworks/fireworks_command.c:269:25: sparse: sparse: 
>> incorrect type in argument 1 (different base types) @@     expected unsigned 
>> int [usertype] *p @@     got restricted __be32 [usertype] * @@
   sound/firewire/fireworks/fireworks_command.c:269:25: sparse:     expected 
unsigned int [usertype] *p
   sound/firewire/fireworks/fireworks_command.c:269:25: sparse:     got 
restricted __be32 [usertype] *
   In file included from arch/arm64/include/asm/mmu.h:24:0,
                    from include/linux/mm_types.h:18,
                    from include/linux/mm.h:16,
                    from include/linux/scatterlist.h:6,
                    from include/linux/dma-mapping.h:9,
                    from include/linux/firewire.h:6,
                    from sound/firewire/fireworks/./fireworks.h:14,
                    from sound/firewire/fireworks/fireworks_command.c:9:
   arch/arm64/include/asm/cpufeature.h: In function 'arm64_ftr_value':
   arch/arm64/include/asm/cpufeature.h:153:68: warning: signed and unsigned 
type in conditional expression [-Wsign-compare]
      cpuid_feature_extract_field_width(val, ftrp->shift, ftrp->width) :
                                                                       ^
   In file included from include/sound/core.h:26:0,
                    from sound/firewire/fireworks/./fireworks.h:21,
                    from sound/firewire/fireworks/fireworks_command.c:9:
   include/linux/sched.h: At top level:
   include/linux/sched.h:1067:42: warning: type qualifiers ignored on function 
return type [-Wignored-qualifiers]
    const struct sched_group_energy * const(*sched_domain_energy_f)(int cpu);
                                             ^
   In file included from sound/firewire/fireworks/./fireworks.h:23:0,
                    from sound/firewire/fireworks/fireworks_command.c:9:
   include/sound/pcm.h: In function 'snd_pcm_chmap_substream':
   include/sound/pcm.h:1244:17: warning: comparison between signed and unsigned 
integer expressions [-Wsign-compare]
      if (s->number == idx)
                    ^

vim +/lock_pte_protection +39 mm/mprotect.c

^1da177e4c3f41 Linus Torvalds 2005-04-16  31  
1ad9f620c3a22f Mel Gorman     2014-04-07  32  /*
1ad9f620c3a22f Mel Gorman     2014-04-07  33   * For a prot_numa update we only 
hold mmap_sem for read so there is a
1ad9f620c3a22f Mel Gorman     2014-04-07  34   * potential race with faulting 
where a pmd was temporarily none. This
1ad9f620c3a22f Mel Gorman     2014-04-07  35   * function checks for a 
transhuge pmd under the appropriate lock. It
1ad9f620c3a22f Mel Gorman     2014-04-07  36   * returns a pte if it was 
successfully locked or NULL if it raced with
1ad9f620c3a22f Mel Gorman     2014-04-07  37   * a transhuge insertion.
1ad9f620c3a22f Mel Gorman     2014-04-07  38   */
1ad9f620c3a22f Mel Gorman     2014-04-07 @39  static pte_t 
*lock_pte_protection(struct vm_area_struct *vma, pmd_t *pmd,
1ad9f620c3a22f Mel Gorman     2014-04-07  40                    unsigned long 
addr, int prot_numa, spinlock_t **ptl)
1ad9f620c3a22f Mel Gorman     2014-04-07  41  {
1ad9f620c3a22f Mel Gorman     2014-04-07  42    pte_t *pte;
1ad9f620c3a22f Mel Gorman     2014-04-07  43    spinlock_t *pmdl;
1ad9f620c3a22f Mel Gorman     2014-04-07  44  
1ad9f620c3a22f Mel Gorman     2014-04-07  45    /* !prot_numa is protected by 
mmap_sem held for write */
1ad9f620c3a22f Mel Gorman     2014-04-07  46    if (!prot_numa)
1ad9f620c3a22f Mel Gorman     2014-04-07  47            return 
pte_offset_map_lock(vma->vm_mm, pmd, addr, ptl);
1ad9f620c3a22f Mel Gorman     2014-04-07  48  
1ad9f620c3a22f Mel Gorman     2014-04-07  49    pmdl = pmd_lock(vma->vm_mm, 
pmd);
1ad9f620c3a22f Mel Gorman     2014-04-07  50    if 
(unlikely(pmd_trans_huge(*pmd) || pmd_none(*pmd))) {
1ad9f620c3a22f Mel Gorman     2014-04-07  51            spin_unlock(pmdl);
1ad9f620c3a22f Mel Gorman     2014-04-07  52            return NULL;
1ad9f620c3a22f Mel Gorman     2014-04-07  53    }
1ad9f620c3a22f Mel Gorman     2014-04-07  54  
1ad9f620c3a22f Mel Gorman     2014-04-07  55    pte = 
pte_offset_map_lock(vma->vm_mm, pmd, addr, ptl);
1ad9f620c3a22f Mel Gorman     2014-04-07  56    spin_unlock(pmdl);
1ad9f620c3a22f Mel Gorman     2014-04-07  57    return pte;
1ad9f620c3a22f Mel Gorman     2014-04-07  58  }
1ad9f620c3a22f Mel Gorman     2014-04-07  59  

:::::: The code at line 39 was first introduced by commit
:::::: 1ad9f620c3a22fa800489455ce517c29e576934e mm: numa: recheck for transhuge 
pages under lock during protection changes

:::::: TO: Mel Gorman <[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