Skip to content

Commit 14a8d83

Browse files
mwajdeczThomas Hellström
authored andcommitted
drm/xe/pf: Use div_u64 when calculating GGTT profile
This will fix the following error seen on some 32-bit config: "ERROR: modpost: "__udivdi3" [drivers/gpu/drm/xe/xe.ko] undefined!" Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202511150929.3vUi6PEJ-lkp@intel.com/ Fixes: e448372 ("drm/xe/pf: Use migration-friendly GGTT auto-provisioning") Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com> Reviewed-by: Piotr Piórkowski <piotr.piorkowski@intel.com> Link: https://patch.msgid.link/20251115151323.10828-1-michal.wajdeczko@intel.com (cherry picked from commit 0f4435a) Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com>
1 parent bf213ac commit 14a8d83

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/gpu/drm/xe/xe_gt_sriov_pf_config.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -711,7 +711,7 @@ static u64 pf_profile_fair_ggtt(struct xe_gt *gt, unsigned int num_vfs)
711711
if (num_vfs > 56)
712712
return SZ_64M - SZ_8M;
713713

714-
return rounddown_pow_of_two(shareable / num_vfs);
714+
return rounddown_pow_of_two(div_u64(shareable, num_vfs));
715715
}
716716

717717
/**

0 commit comments

Comments
 (0)