]> www.infradead.org Git - linux.git/commit
drm/xe/tests: Fix the shrinker test compiler warnings.
authorThomas Hellström <thomas.hellstrom@linux.intel.com>
Fri, 4 Oct 2024 14:11:20 +0000 (16:11 +0200)
committerThomas Hellström <thomas.hellstrom@linux.intel.com>
Wed, 9 Oct 2024 10:18:22 +0000 (12:18 +0200)
commit7a7593e5885bc172050a75ddf2bb6aeb96c8a8a0
treefa4ee5afe825d8e839ff3a65c01278f591d71f3d
parent67ec9f87bd6c57db1251bb2244d242f7ca5a0b6a
drm/xe/tests: Fix the shrinker test compiler warnings.

The xe_bo_shrink_kunit test has an uninitialized value and illegal
integer size conversions on 32-bit. Fix.

v2:
- Use div64_u64 to ensure the u64 division compiles everywhere. (Matt Auld)

Reported-by: Nathan Chancellor <nathan@kernel.org>
Closes: https://lore.kernel.org/20240913195649.GA61514@thelio-3990X/
Fixes: 5a90b60db5e6 ("drm/xe: Add a xe_bo subtest for shrinking / swapping")
Cc: dri-devel@lists.freedesktop.org
Cc: Matthew Auld <matthew.auld@intel.com>
Reviewed-by: Matthew Auld <matthew.auld@intel.com> #v1
Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20241004141121.186177-1-thomas.hellstrom@linux.intel.com
drivers/gpu/drm/xe/tests/xe_bo.c