Hi liubo,
FYI, the error/warning still remains.
tree: https://gitee.com/openeuler/kernel.git OLK-5.10 head: 5a1d9701155c6908c76c68951170f10279685143 commit: 79246e864484015e1ef3c7ecec2d18a6b27199ec [5448/30000] etmem: etmem scan module Replace WARN_ONCE() with debug_printk for "nothing read" config: arm64-randconfig-004-20240914 (https://download.01.org/0day-ci/archive/20240914/202409140258.tMEI5GEF-lkp@i...) compiler: aarch64-linux-gcc (GCC) 14.1.0 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240914/202409140258.tMEI5GEF-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/202409140258.tMEI5GEF-lkp@intel.com/
All warnings (new ones prefixed by >>):
fs/proc/etmem_scan.c: In function 'mm_idle_walk_range': fs/proc/etmem_scan.c:1244:61: warning: suggest braces around empty body in an 'if' statement [-Wempty-body] 1244 | pic->next_hva, end); | ^
fs/proc/etmem_scan.c:1247:45: warning: suggest braces around empty body in an 'else' statement [-Wempty-body]
1247 | debug_printk("nothing read"); | ^
vim +/else +1247 fs/proc/etmem_scan.c
1201 1202 static int mm_idle_walk_range(struct page_idle_ctrl *pic, 1203 unsigned long start, 1204 unsigned long end, 1205 struct mm_walk *walk) 1206 { 1207 struct vm_area_struct *vma; 1208 int ret = 0; 1209 1210 ret = init_page_idle_ctrl_buffer(pic); 1211 if (ret) 1212 return ret; 1213 1214 for (; start < end;) { 1215 down_read(&walk->mm->mmap_lock); 1216 vma = find_vma(walk->mm, start); 1217 if (vma) { 1218 if (end > vma->vm_start) { 1219 local_irq_disable(); 1220 ret = walk_page_range(walk->mm, start, end, 1221 walk->ops, walk->private); 1222 local_irq_enable(); 1223 } else 1224 set_restart_gpa(vma->vm_start, "VMA-HOLE"); 1225 } else 1226 set_restart_gpa(TASK_SIZE, "EOF"); 1227 up_read(&walk->mm->mmap_lock); 1228 1229 WARN_ONCE(pic->gpa_to_hva, "non-zero gpa_to_hva"); 1230 if (ret != PAGE_IDLE_KBUF_FULL && end > pic->restart_gpa) 1231 pic->restart_gpa = end; 1232 start = pic->restart_gpa; 1233 ret = page_idle_copy_user(pic, start, end); 1234 if (ret) 1235 break; 1236 } 1237 1238 if (start > pic->next_hva) 1239 set_next_hva(start, "NEXT-START"); 1240 1241 if (pic->bytes_copied) { 1242 if (ret != PAGE_IDLE_BUF_FULL && pic->next_hva < end) 1243 debug_printk("partial scan: next_hva=%pK end=%pK\n",
1244 pic->next_hva, end);
1245 ret = 0; 1246 } else
1247 debug_printk("nothing read");
1248 return ret; 1249 } 1250