public inbox for intel-xe@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Nathan Chancellor <nathan@kernel.org>
To: Michal Wajdeczko <michal.wajdeczko@intel.com>
Cc: intel-xe@lists.freedesktop.org,
	"Piotr Piórkowski" <piotr.piorkowski@intel.com>
Subject: Re: [PATCH v2 06/10] drm/xe/tests: Add KUnit tests for new VRAM fair provisioning
Date: Thu, 26 Feb 2026 18:16:39 -0700	[thread overview]
Message-ID: <20260227011639.GA1683727@ax162> (raw)
In-Reply-To: <20260218205553.3561-7-michal.wajdeczko@intel.com>

Hi Michal,

On Wed, Feb 18, 2026 at 09:55:48PM +0100, Michal Wajdeczko wrote:
...
> diff --git a/drivers/gpu/drm/xe/tests/xe_gt_sriov_pf_config_kunit.c b/drivers/gpu/drm/xe/tests/xe_gt_sriov_pf_config_kunit.c
> index 3889dc3e49ca..305dbd4e5d1a 100644
> --- a/drivers/gpu/drm/xe/tests/xe_gt_sriov_pf_config_kunit.c
> +++ b/drivers/gpu/drm/xe/tests/xe_gt_sriov_pf_config_kunit.c
> @@ -11,6 +11,7 @@
>  #include "xe_pci_test.h"
>  
>  #define TEST_MAX_VFS	63
> +#define TEST_VRAM	0x37a800000ull
...
> @@ -50,6 +64,19 @@ static int pf_gt_config_test_init(struct kunit *test)
>  	KUNIT_ASSERT_NOT_ERR_OR_NULL(test, gt);
>  	test->priv = gt;
>  
> +	/* pretend it has some VRAM */
> +	KUNIT_ASSERT_TRUE(test, IS_DGFX(xe));
> +	vram = kunit_kzalloc(test, sizeof(*vram), GFP_KERNEL);
> +	KUNIT_ASSERT_NOT_ERR_OR_NULL(test, vram);
> +	vram->usable_size = TEST_VRAM;

FWIW, this causes warnings for a 32-bit resource_size_t:

  $ make -skj"$(nproc)" ARCH=arm CROSS_COMPILE=arm-linux-gnueabi- mrproper allyesconfig drivers/gpu/drm/xe/xe_gt_sriov_pf_config.o
  In file included from drivers/gpu/drm/xe/xe_gt_sriov_pf_config.c:3329:
  drivers/gpu/drm/xe/tests/xe_gt_sriov_pf_config_kunit.c: In function 'pf_gt_config_test_init':
  drivers/gpu/drm/xe/tests/xe_gt_sriov_pf_config_kunit.c:14:25: error: conversion from 'long long unsigned int' to 'resource_size_t' {aka 'unsigned int'} changes value from '14940110848' to '2055208960' [-Werror=overflow]
     14 | #define TEST_VRAM       0x37a800000ull
        |                         ^~~~~~~~~~~~~~
  drivers/gpu/drm/xe/tests/xe_gt_sriov_pf_config_kunit.c:71:29: note: in expansion of macro 'TEST_VRAM'
     71 |         vram->usable_size = TEST_VRAM;
        |                             ^~~~~~~~~
  cc1: all warnings being treated as errors

Cheers,
Nathan

  reply	other threads:[~2026-02-27  1:16 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-18 20:55 [PATCH v2 00/10] drm/xe/pf: Allow to change VFs VRAM quota using sysfs Michal Wajdeczko
2026-02-18 20:55 ` [PATCH v2 01/10] drm/xe/pf: Expose LMTT page size Michal Wajdeczko
2026-02-20  8:22   ` Piotr Piórkowski
2026-02-18 20:55 ` [PATCH v2 02/10] drm/xe/pf: Add locked variants of VRAM configuration functions Michal Wajdeczko
2026-02-18 20:55 ` [PATCH v2 03/10] drm/xe/pf: Add functions for VRAM provisioning Michal Wajdeczko
2026-02-18 20:55 ` [PATCH v2 04/10] drm/xe/pf: Allow to change VFs VRAM quota using sysfs Michal Wajdeczko
2026-02-18 21:21   ` Rodrigo Vivi
2026-02-18 20:55 ` [PATCH v2 05/10] drm/xe/pf: Use migration-friendly VRAM auto-provisioning Michal Wajdeczko
2026-02-18 20:55 ` [PATCH v2 06/10] drm/xe/tests: Add KUnit tests for new VRAM fair provisioning Michal Wajdeczko
2026-02-27  1:16   ` Nathan Chancellor [this message]
2026-02-18 20:55 ` [PATCH v2 07/10] drm/xe/pf: Don't check for empty config Michal Wajdeczko
2026-02-18 20:55 ` [PATCH v2 08/10] drm/xe/pf: Prefer guard(mutex) when doing fair LMEM provisioning Michal Wajdeczko
2026-02-18 20:55 ` [PATCH v2 09/10] drm/xe/pf: Skip VRAM auto-provisioning if already provisioned Michal Wajdeczko
2026-02-18 20:55 ` [PATCH v2 10/10] drm/xe/pf: Add documentation for vram_quota Michal Wajdeczko
2026-02-18 21:21   ` Rodrigo Vivi
2026-02-18 21:01 ` ✗ CI.checkpatch: warning for drm/xe/pf: Allow to change VFs VRAM quota using sysfs (rev2) Patchwork
2026-02-18 21:03 ` ✓ CI.KUnit: success " Patchwork
2026-02-18 21:47 ` ✗ Xe.CI.BAT: failure " Patchwork
2026-02-20 10:35   ` Michal Wajdeczko
2026-02-18 23:19 ` ✗ Xe.CI.FULL: " Patchwork
2026-02-20 10:37   ` Michal Wajdeczko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260227011639.GA1683727@ax162 \
    --to=nathan@kernel.org \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=michal.wajdeczko@intel.com \
    --cc=piotr.piorkowski@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox