CC: kbuild-all(a)lists.01.org TO: Maarten Lankhorst tree: git://people.freedesktop.org/~mlankhorst/linux ttm head: 2fd51ce6e707358af329fa2d4a91ab7dd7b84c5e commit: cbea27e180f0edbb6eb5c4f2cb24f18ba8f78352 [3/8] drm/i915: Use ttm mmap handling for ttm bo's. :::::: branch date: 4 hours ago :::::: commit date: 9 hours ago config: i386-randconfig-m021-20210525 (attached as .config) compiler: gcc-9 (Debian 9.3.0-22) 9.3.0 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot Reported-by: Dan Carpenter smatch warnings: drivers/gpu/drm/i915/selftests/igt_mmap.c:45 igt_mmap_offset() error: uninitialized symbol 'addr'. vim +/addr +45 drivers/gpu/drm/i915/selftests/igt_mmap.c 6fedafacae1b95 Chris Wilson 2019-11-07 11 cbea27e180f0ed Maarten Lankhorst 2021-05-05 12 unsigned long igt_mmap_offset(struct drm_i915_private *i915, cbea27e180f0ed Maarten Lankhorst 2021-05-05 13 u64 offset, cbea27e180f0ed Maarten Lankhorst 2021-05-05 14 unsigned long size, 6fedafacae1b95 Chris Wilson 2019-11-07 15 unsigned long prot, 6fedafacae1b95 Chris Wilson 2019-11-07 16 unsigned long flags) 6fedafacae1b95 Chris Wilson 2019-11-07 17 { cbea27e180f0ed Maarten Lankhorst 2021-05-05 18 struct drm_vma_offset_node *node; 6fedafacae1b95 Chris Wilson 2019-11-07 19 struct file *file; cbea27e180f0ed Maarten Lankhorst 2021-05-05 20 unsigned long addr; 6fedafacae1b95 Chris Wilson 2019-11-07 21 int err; 6fedafacae1b95 Chris Wilson 2019-11-07 22 cbea27e180f0ed Maarten Lankhorst 2021-05-05 23 /* no need to refcount, we own this object */ cbea27e180f0ed Maarten Lankhorst 2021-05-05 24 drm_vma_offset_lock_lookup(i915->drm.vma_offset_manager); cbea27e180f0ed Maarten Lankhorst 2021-05-05 25 node = drm_vma_offset_exact_lookup_locked(i915->drm.vma_offset_manager, cbea27e180f0ed Maarten Lankhorst 2021-05-05 26 offset / PAGE_SIZE, size / PAGE_SIZE); cbea27e180f0ed Maarten Lankhorst 2021-05-05 27 drm_vma_offset_unlock_lookup(i915->drm.vma_offset_manager); cbea27e180f0ed Maarten Lankhorst 2021-05-05 28 cbea27e180f0ed Maarten Lankhorst 2021-05-05 29 if (GEM_WARN_ON(!node)) { cbea27e180f0ed Maarten Lankhorst 2021-05-05 30 pr_info("Failed to lookup %Lx\n", offset); cbea27e180f0ed Maarten Lankhorst 2021-05-05 31 return -ENOENT; cbea27e180f0ed Maarten Lankhorst 2021-05-05 32 } cbea27e180f0ed Maarten Lankhorst 2021-05-05 33 6fedafacae1b95 Chris Wilson 2019-11-07 34 /* Pretend to open("/dev/dri/card0") */ 6fedafacae1b95 Chris Wilson 2019-11-07 35 file = mock_drm_getfile(i915->drm.primary, O_RDWR); 6fedafacae1b95 Chris Wilson 2019-11-07 36 if (IS_ERR(file)) 6fedafacae1b95 Chris Wilson 2019-11-07 37 return PTR_ERR(file); 6fedafacae1b95 Chris Wilson 2019-11-07 38 6fedafacae1b95 Chris Wilson 2019-11-07 39 err = drm_vma_node_allow(node, file->private_data); 6fedafacae1b95 Chris Wilson 2019-11-07 40 if (err) { 6fedafacae1b95 Chris Wilson 2019-11-07 41 addr = err; 6fedafacae1b95 Chris Wilson 2019-11-07 42 goto out_file; 6fedafacae1b95 Chris Wilson 2019-11-07 43 } 6fedafacae1b95 Chris Wilson 2019-11-07 44 6fedafacae1b95 Chris Wilson 2019-11-07 @45 addr = vm_mmap(file, addr, drm_vma_node_size(node) << PAGE_SHIFT, :::::: The code@line 45 was first introduced by commit :::::: 6fedafacae1b951af104d862888a446b6c3f3a39 drm/i915/selftests: Wrap vm_mmap() around GEM objects :::::: TO: Chris Wilson :::::: CC: Chris Wilson --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org