Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Dixit, Ashutosh" <ashutosh.dixit@intel.com>
To: Harish Chegondi <harish.chegondi@intel.com>
Cc: <intel-xe@lists.freedesktop.org>
Subject: Re: [PATCH v11 7/8] drm/xe/uapi: Add a device query to get EU stall sampling information
Date: Tue, 25 Feb 2025 08:56:39 -0800	[thread overview]
Message-ID: <85cyf6j73s.wl-ashutosh.dixit@intel.com> (raw)
In-Reply-To: <b029a6dbdd157202be1c7b47e8fbbacd2a120551.1740474556.git.harish.chegondi@intel.com>

On Tue, 25 Feb 2025 01:20:24 -0800, Harish Chegondi wrote:
>
> +static int query_eu_stall(struct xe_device *xe,
> +			  struct drm_xe_device_query *query)
> +{
> +	void __user *query_ptr = u64_to_user_ptr(query->data);
> +	struct drm_xe_query_eu_stall *info;
> +	size_t size, array_size;
> +	const u64 *rates;
> +	u32 num_rates;
> +	int ret;
> +
> +	if (!(xe->info.platform == XE_PVC || GRAPHICS_VER(xe) >= 20)) {
> +		drm_dbg(&xe->drm, "EU stall monitoring is not supported on this platform\n");
> +		return -ENODEV;
> +	}

Why not move has_eu_stall_sampling_support() into xe_eu_stall.h and use it
here? Or leave that function definition in the .c and move the declaration
to .h. Otherwise the same check is repeated twice and someone has to
remember to change in two places?

  reply	other threads:[~2025-02-25 16:56 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-25  9:20 [PATCH v11 0/8] Add support for EU stall sampling Harish Chegondi
2025-02-25  9:20 ` [PATCH v11 1/8] drm/xe/topology: Add a function to find the index of the last enabled DSS in a mask Harish Chegondi
2025-02-25  9:20 ` [PATCH v11 2/8] drm/xe/uapi: Introduce API for EU stall sampling Harish Chegondi
2025-02-25  9:20 ` [PATCH v11 3/8] drm/xe/eustall: Add support to init, enable and disable " Harish Chegondi
2025-02-25  9:20 ` [PATCH v11 4/8] drm/xe/eustall: Add support to read() and poll() EU stall data Harish Chegondi
2025-02-25 20:55   ` Dixit, Ashutosh
2025-02-25  9:20 ` [PATCH v11 5/8] drm/xe/eustall: Add support to handle dropped " Harish Chegondi
2025-02-25 23:34   ` Dixit, Ashutosh
2025-02-25  9:20 ` [PATCH v11 6/8] drm/xe/eustall: Add EU stall sampling support for Xe2 Harish Chegondi
2025-02-25  9:20 ` [PATCH v11 7/8] drm/xe/uapi: Add a device query to get EU stall sampling information Harish Chegondi
2025-02-25 16:56   ` Dixit, Ashutosh [this message]
2025-02-25  9:20 ` [PATCH v11 8/8] drm/xe/eustall: Add workaround 22016596838 which applies to PVC Harish Chegondi
2025-02-25  9:35 ` ✓ CI.Patch_applied: success for Add support for EU stall sampling Patchwork
2025-02-25  9:35 ` ✗ CI.checkpatch: warning " Patchwork
2025-02-25  9:36 ` ✓ CI.KUnit: success " Patchwork
2025-02-25  9:53 ` ✓ CI.Build: " Patchwork
2025-02-25  9:55 ` ✗ CI.Hooks: failure " Patchwork
2025-02-25  9:56 ` ✓ CI.checksparse: success " Patchwork
2025-02-25 10:16 ` ✓ Xe.CI.BAT: " Patchwork
2025-02-25 16:21 ` ✓ Xe.CI.Full: " Patchwork

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=85cyf6j73s.wl-ashutosh.dixit@intel.com \
    --to=ashutosh.dixit@intel.com \
    --cc=harish.chegondi@intel.com \
    --cc=intel-xe@lists.freedesktop.org \
    /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