public inbox for llvm@lists.linux.dev
 help / color / mirror / Atom feed
* [linux-next:master 678/1146] drivers/gpu/drm/xe/tests/xe_gt_sriov_pf_config_kunit.c:71:22: warning: implicit conversion from 'unsigned long long' to 'resource_size_t' (aka 'unsigned int') changes value from 14940110848 to 2055208960
@ 2026-02-24  3:23 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2026-02-24  3:23 UTC (permalink / raw)
  To: Michal Wajdeczko; +Cc: llvm, oe-kbuild-all, Piotr Piórkowski 

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   779cae956c8316aebc1946ef86ca001f99658270
commit: cbe29da6f7c0d0541ec135e7292b35b97f8ca402 [678/1146] drm/xe/tests: Add KUnit tests for new VRAM fair provisioning
config: i386-buildonly-randconfig-001-20260224 (https://download.01.org/0day-ci/archive/20260224/202602241144.LxOYPgFa-lkp@intel.com/config)
compiler: clang version 20.1.8 (https://github.com/llvm/llvm-project 87f0227cb60147a26a1eeb4fb06e3b505e9c7261)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260224/202602241144.LxOYPgFa-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@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202602241144.LxOYPgFa-lkp@intel.com/

All warnings (new ones prefixed by >>):

   In file included from drivers/gpu/drm/xe/xe_gt_sriov_pf_config.c:3271:
>> drivers/gpu/drm/xe/tests/xe_gt_sriov_pf_config_kunit.c:71:22: warning: implicit conversion from 'unsigned long long' to 'resource_size_t' (aka 'unsigned int') changes value from 14940110848 to 2055208960 [-Wconstant-conversion]
      71 |         vram->usable_size = TEST_VRAM;
         |                           ~ ^~~~~~~~~
   drivers/gpu/drm/xe/tests/xe_gt_sriov_pf_config_kunit.c:14:19: note: expanded from macro 'TEST_VRAM'
      14 | #define TEST_VRAM       0x37a800000ull
         |                         ^~~~~~~~~~~~~~
   1 warning generated.


vim +71 drivers/gpu/drm/xe/tests/xe_gt_sriov_pf_config_kunit.c

    44	
    45	static int pf_gt_config_test_init(struct kunit *test)
    46	{
    47		struct xe_pci_fake_data fake = {
    48			.sriov_mode = XE_SRIOV_MODE_PF,
    49			.platform = XE_BATTLEMAGE, /* any random DGFX platform with SR-IOV */
    50			.subplatform = XE_SUBPLATFORM_NONE,
    51			.graphics_verx100 = 2001,
    52		};
    53		struct xe_vram_region *vram;
    54		struct xe_device *xe;
    55		struct xe_gt *gt;
    56	
    57		test->priv = &fake;
    58		xe_kunit_helper_xe_device_test_init(test);
    59	
    60		xe = test->priv;
    61		KUNIT_ASSERT_TRUE(test, IS_SRIOV_PF(xe));
    62	
    63		gt = xe_root_mmio_gt(xe);
    64		KUNIT_ASSERT_NOT_ERR_OR_NULL(test, gt);
    65		test->priv = gt;
    66	
    67		/* pretend it has some VRAM */
    68		KUNIT_ASSERT_TRUE(test, IS_DGFX(xe));
    69		vram = kunit_kzalloc(test, sizeof(*vram), GFP_KERNEL);
    70		KUNIT_ASSERT_NOT_ERR_OR_NULL(test, vram);
  > 71		vram->usable_size = TEST_VRAM;
    72		xe->mem.vram = vram;
    73		xe->tiles[0].mem.vram = vram;
    74	
    75		/* pretend we have a valid LMTT */
    76		KUNIT_ASSERT_TRUE(test, xe_device_has_lmtt(xe));
    77		KUNIT_ASSERT_GE(test, GRAPHICS_VERx100(xe), 1260);
    78		xe->tiles[0].sriov.pf.lmtt.ops = &lmtt_ml_ops;
    79	
    80		/* pretend it can support up to 63 VFs */
    81		xe->sriov.pf.device_total_vfs = TEST_MAX_VFS;
    82		xe->sriov.pf.driver_max_vfs = TEST_MAX_VFS;
    83		KUNIT_ASSERT_EQ(test, xe_sriov_pf_get_totalvfs(xe), 63);
    84	
    85		pf_set_admin_mode(xe, false);
    86		KUNIT_ASSERT_EQ(test, xe_sriov_init(xe), 0);
    87	
    88		/* more sanity checks */
    89		KUNIT_EXPECT_EQ(test, GUC_ID_MAX + 1, SZ_64K);
    90		KUNIT_EXPECT_EQ(test, GUC_NUM_DOORBELLS, SZ_256);
    91	
    92		return 0;
    93	}
    94	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2026-02-24  3:24 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-02-24  3:23 [linux-next:master 678/1146] drivers/gpu/drm/xe/tests/xe_gt_sriov_pf_config_kunit.c:71:22: warning: implicit conversion from 'unsigned long long' to 'resource_size_t' (aka 'unsigned int') changes value from 14940110848 to 2055208960 kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox