tree: https://gitee.com/openeuler/kernel.git OLK-6.6 head: 16a0cbac6609f8ba10a91a9d52b15bf28243c3ee commit: 5d3b64fd78b80ec49285f2186e7b5ac5850f76e4 [1667/1667] etmem: add etmem scan feature config: arm64-randconfig-r111-20241227 (https://download.01.org/0day-ci/archive/20241227/202412270547.i7G0fcKP-lkp@i...) compiler: aarch64-linux-gcc (GCC) 14.2.0 reproduce: (https://download.01.org/0day-ci/archive/20241227/202412270547.i7G0fcKP-lkp@i...)
If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot lkp@intel.com | Closes: https://lore.kernel.org/oe-kbuild-all/202412270547.i7G0fcKP-lkp@intel.com/
sparse warnings: (new ones prefixed by >>) fs/proc/etmem_scan.c:269:18: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected void [noderef] __user *buf @@ got void *buf @@ fs/proc/etmem_scan.c:269:18: sparse: expected void [noderef] __user *buf fs/proc/etmem_scan.c:269:18: sparse: got void *buf
fs/proc/etmem_scan.c:737:16: sparse: sparse: cast removes address space '__rcu' of expression
fs/proc/etmem_scan.c:1361:40: sparse: sparse: incorrect type in assignment (incompatible argument 2 (different address spaces)) @@ expected long ( *extern [addressable] [assigned] [toplevel] read )( ... ) @@ got long ( * )( ... ) @@ fs/proc/etmem_scan.c:1361:40: sparse: expected long ( *extern [addressable] [assigned] [toplevel] read )( ... ) fs/proc/etmem_scan.c:1361:40: sparse: got long ( * )( ... ) fs/proc/etmem_scan.c:697:46: sparse: sparse: self-comparison always evaluates to false fs/proc/etmem_scan.c:720:46: sparse: sparse: self-comparison always evaluates to false
vim +/__rcu +737 fs/proc/etmem_scan.c
724 725 static int arm_page_range(struct page_idle_ctrl *pic, 726 unsigned long addr, 727 unsigned long end) 728 { 729 pgd_t *pgd; 730 unsigned long next; 731 struct kvm *kvm = pic->kvm; 732 int err = 0; 733 734 WARN_ON(addr >= end); 735 736 read_lock(&pic->kvm->mmu_lock);
737 pgd = (pgd_t *)kvm->arch.mmu.pgt->pgd + pgd_index(addr) * PTRS_PER_PTE;
738 read_unlock(&pic->kvm->mmu_lock); 739 740 local_irq_disable(); 741 do { 742 next = pgd_addr_end(addr, end); 743 if (!pgd_present(*pgd)) { 744 set_restart_gpa(next, "PGD_HOLE"); 745 continue; 746 } 747 748 err = arm_p4d_range(pic, pgd, addr, next); 749 if (err) 750 break; 751 } while (pgd++, addr = next, addr != end); 752 753 local_irq_enable(); 754 return err; 755 } 756 #endif 757