[PATCH v5 21/25] drm/xe/madvise: Skip vma invalidation if mem attr are unchanged
kernel test robot
lkp at intel.com
Wed Jul 30 20:57:56 UTC 2025
Hi Himal,
kernel test robot noticed the following build warnings:
[auto build test WARNING on next-20250730]
[cannot apply to drm-xe/drm-xe-next linus/master v6.16 v6.16-rc7 v6.16-rc6 v6.16]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Himal-Prasad-Ghimiray/drm-gpuvm-Pass-map-arguments-through-a-struct/20250731-003813
base: next-20250730
patch link: https://lore.kernel.org/r/20250730130050.1001648-22-himal.prasad.ghimiray%40intel.com
patch subject: [PATCH v5 21/25] drm/xe/madvise: Skip vma invalidation if mem attr are unchanged
config: arm-randconfig-004-20250731 (https://download.01.org/0day-ci/archive/20250731/202507310458.N20slFKu-lkp@intel.com/config)
compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 8f09b03aebb71c154f3bbe725c29e3f47d37c26e)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250731/202507310458.N20slFKu-lkp@intel.com/reproduce)
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 at intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202507310458.N20slFKu-lkp@intel.com/
All warnings (new ones prefixed by >>):
>> drivers/gpu/drm/xe/xe_vm_madvise.c:200:4: warning: variable 'tile_mask' is uninitialized when used here [-Wuninitialized]
200 | tile_mask |= xe_svm_ranges_zap_ptes_in_range(vm,
| ^~~~~~~~~
drivers/gpu/drm/xe/xe_vm_madvise.c:184:18: note: initialize the variable 'tile_mask' to silence this warning
184 | u8 id, tile_mask;
| ^
| = '\0'
1 warning generated.
vim +/tile_mask +200 drivers/gpu/drm/xe/xe_vm_madvise.c
179
180 static u8 xe_zap_ptes_in_madvise_range(struct xe_vm *vm, u64 start, u64 end)
181 {
182 struct drm_gpuva *gpuva;
183 struct xe_tile *tile;
184 u8 id, tile_mask;
185
186 lockdep_assert_held_write(&vm->lock);
187
188 /* Wait for pending binds */
189 if (dma_resv_wait_timeout(xe_vm_resv(vm), DMA_RESV_USAGE_BOOKKEEP,
190 false, MAX_SCHEDULE_TIMEOUT) <= 0)
191 XE_WARN_ON(1);
192
193 drm_gpuvm_for_each_va_range(gpuva, &vm->gpuvm, start, end) {
194 struct xe_vma *vma = gpuva_to_vma(gpuva);
195
196 if (vma->skip_invalidation || xe_vma_is_null(vma))
197 continue;
198
199 if (xe_vma_is_cpu_addr_mirror(vma)) {
> 200 tile_mask |= xe_svm_ranges_zap_ptes_in_range(vm,
201 xe_vma_start(vma),
202 xe_vma_end(vma));
203 } else {
204 for_each_tile(tile, vm->xe, id) {
205 if (xe_pt_zap_ptes(tile, vma)) {
206 tile_mask |= BIT(id);
207
208 /*
209 * WRITE_ONCE pairs with READ_ONCE
210 * in xe_vm_has_valid_gpu_mapping()
211 */
212 WRITE_ONCE(vma->tile_invalidated,
213 vma->tile_invalidated | BIT(id));
214 }
215 }
216 }
217 }
218
219 return tile_mask;
220 }
221
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
More information about the Intel-xe
mailing list