Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Dixit, Ashutosh" <ashutosh.dixit@intel.com>
To: Umesh Nerlige Ramappa <umesh.nerlige.ramappa@intel.com>
Cc: <intel-xe@lists.freedesktop.org>
Subject: Re: [PATCH] drm/xe/oa: Allow oa_exponent value of 0
Date: Tue, 11 Feb 2025 18:12:50 -0800	[thread overview]
Message-ID: <85bjv73o7x.wl-ashutosh.dixit@intel.com> (raw)
In-Reply-To: <20250212010736.1428108-1-umesh.nerlige.ramappa@intel.com>

On Tue, 11 Feb 2025 17:07:36 -0800, Umesh Nerlige Ramappa wrote:
>

Hi Umesh,

> OA exponent value of 0 is a valid value for periodic reports. Allow user
> to pass 0 for the OA sampling interval since it gets converted to 2 gt
> clock ticks.
>
> Signed-off-by: Umesh Nerlige Ramappa <umesh.nerlige.ramappa@intel.com>
> ---
>  drivers/gpu/drm/xe/xe_oa.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/xe/xe_oa.c b/drivers/gpu/drm/xe/xe_oa.c
> index a692dffcb638..268403b9b527 100644
> --- a/drivers/gpu/drm/xe/xe_oa.c
> +++ b/drivers/gpu/drm/xe/xe_oa.c
> @@ -2025,7 +2025,7 @@ int xe_oa_stream_open_ioctl(struct drm_device *dev, u64 data, struct drm_file *f
>		goto err_exec_q;
>	}
>
> -	if (param.period_exponent > 0) {
> +	if (param.period_exponent >= 0) {
>		u64 oa_period, oa_freq_hz;
>
>		/* Requesting samples from OAG buffer is a privileged operation */
> --
> 2.34.1
>

I think this also would need to be changed:

static int xe_oa_stream_init(struct xe_oa_stream *stream,
			     struct xe_oa_open_param *param)
{
	...
	stream->periodic = param->period_exponent > 0;

Ashutosh

  reply	other threads:[~2025-02-12  2:12 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-12  1:07 [PATCH] drm/xe/oa: Allow oa_exponent value of 0 Umesh Nerlige Ramappa
2025-02-12  2:12 ` Dixit, Ashutosh [this message]
2025-02-12  2:18 ` ✓ CI.Patch_applied: success for " Patchwork
2025-02-12  2:18 ` ✓ CI.checkpatch: " Patchwork
2025-02-12  2:20 ` ✓ CI.KUnit: " Patchwork
2025-02-12  2:36 ` ✓ CI.Build: " Patchwork
2025-02-12  2:39 ` ✓ CI.Hooks: " Patchwork
2025-02-12  2:40 ` ✓ CI.checksparse: " Patchwork
2025-02-12  3:00 ` ✓ Xe.CI.BAT: " Patchwork
2025-02-12  8:20 ` ✗ Xe.CI.Full: failure " 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=85bjv73o7x.wl-ashutosh.dixit@intel.com \
    --to=ashutosh.dixit@intel.com \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=umesh.nerlige.ramappa@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