Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Andi Shyti <andi.shyti@linux.intel.com>
To: Jonathan Cavitt <jonathan.cavitt@intel.com>
Cc: chris.p.wilson@linux.intel.com, intel-gfx@lists.freedesktop.org,
	matthew.d.roper@intel.com, nirmoy.das@intel.com
Subject: Re: [Intel-gfx] [PATCH 3/3] drm/i915/gt: Apply workaround 22016122933 correctly
Date: Thu, 27 Jul 2023 14:20:16 +0200	[thread overview]
Message-ID: <ZMJhAMoG1RHE6Hnq@ashyti-mobl2.lan> (raw)
In-Reply-To: <20230726155356.1652979-3-jonathan.cavitt@intel.com>

Hi Jonathan,

On Wed, Jul 26, 2023 at 08:53:56AM -0700, Jonathan Cavitt wrote:
> WA_22016122933 was recently applied to all MeteorLake engines, which is
> simultaneously too broad (should only apply to Media engines) and too
> specific (should apply to all platforms that use the same media engine
> as MeteorLake).  Correct this in cases where coherency settings are
> modified.
> 
> There were also two additional places where the workaround was applied
> unconditionally.  The change was confirmed as necessary for all
> platforms, so the workaround label was removed.
> 
> Signed-off-by: Jonathan Cavitt <jonathan.cavitt@intel.com>
> Suggested-by: Matt Roper <matthew.d.roper@intel.com>

nitpick: the tag part is in chronological order. First Matt
suggested it and then you developed and sent.

> ---
>  drivers/gpu/drm/i915/gt/intel_gt.c        | 5 +++--
>  drivers/gpu/drm/i915/gt/intel_gt.h        | 6 ++++++
>  drivers/gpu/drm/i915/gt/intel_lrc.c       | 7 ++++---
>  drivers/gpu/drm/i915/gt/uc/intel_gsc_fw.c | 4 ----
>  drivers/gpu/drm/i915/gt/uc/intel_guc.c    | 7 ++++---
>  drivers/gpu/drm/i915/gt/uc/intel_guc_ct.c | 4 ----
>  6 files changed, 17 insertions(+), 16 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/gt/intel_gt.c b/drivers/gpu/drm/i915/gt/intel_gt.c
> index 62eda0ab9bfc..b0f029f2380d 100644
> --- a/drivers/gpu/drm/i915/gt/intel_gt.c
> +++ b/drivers/gpu/drm/i915/gt/intel_gt.c
> @@ -1139,9 +1139,10 @@ enum i915_map_type intel_gt_coherent_map_type(struct intel_gt *gt,
>  					      bool always_coherent)
>  {
>  	/*
> -	 * Wa_22016122933: always return I915_MAP_WC for MTL
> +	 * Wa_22016122933: always return I915_MAP_WC for Media
> +	 * version 13.0 when the object is on the Media GT
>  	 */
> -	if (i915_gem_object_is_lmem(obj) || IS_METEORLAKE(gt->i915))
> +	if (i915_gem_object_is_lmem(obj) || intel_gt_needs_wa_22016122933(gt))
>  		return I915_MAP_WC;
>  	if (HAS_LLC(gt->i915) || always_coherent)
>  		return I915_MAP_WB;
> diff --git a/drivers/gpu/drm/i915/gt/intel_gt.h b/drivers/gpu/drm/i915/gt/intel_gt.h
> index adb442aaa522..2444ceb42b1b 100644
> --- a/drivers/gpu/drm/i915/gt/intel_gt.h
> +++ b/drivers/gpu/drm/i915/gt/intel_gt.h
> @@ -6,6 +6,7 @@
>  #ifndef __INTEL_GT__
>  #define __INTEL_GT__
>  
> +#include "i915_drv.h"
>  #include "intel_engine_types.h"
>  #include "intel_gt_types.h"
>  #include "intel_reset.h"
> @@ -24,6 +25,11 @@ static inline bool gt_is_root(struct intel_gt *gt)
>  	return !gt->info.id;
>  }
>  
> +static inline bool intel_gt_needs_wa_22016122933(struct intel_gt *gt)
> +{
> +	return MEDIA_VER_FULL(gt->i915) == IP_VER(13, 0) && gt->type == GT_MEDIA;
> +}
> +

I like this format! I think we should make it a standard way to
handle workarounds.

Reviewed-by: Andi Shyti <andi.shyti@linux.intel.com> 

Andi

[...]

  reply	other threads:[~2023-07-27 12:20 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-26 15:53 [Intel-gfx] [PATCH 1/3] drm/i915/gt: Simplify shmem_create_from_object map_type selection Jonathan Cavitt
2023-07-26 15:53 ` [Intel-gfx] [PATCH 2/3] drm/i915: Make i915_coherent_map_type GT-centric Jonathan Cavitt
2023-07-27 11:35   ` Tvrtko Ursulin
2023-07-28  1:34     ` Andi Shyti
2023-07-28  8:07       ` Tvrtko Ursulin
2023-07-28  8:18         ` Andi Shyti
2023-07-27 12:16   ` Andi Shyti
2023-08-01 14:32   ` Andi Shyti
2023-07-26 15:53 ` [Intel-gfx] [PATCH 3/3] drm/i915/gt: Apply workaround 22016122933 correctly Jonathan Cavitt
2023-07-27 12:20   ` Andi Shyti [this message]
2023-07-26 16:37 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for series starting with [1/3] drm/i915/gt: Simplify shmem_create_from_object map_type selection Patchwork
2023-07-26 16:37 ` [Intel-gfx] ✗ Fi.CI.SPARSE: " Patchwork
2023-07-26 16:51 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2023-07-26 20:30 ` [Intel-gfx] ✗ Fi.CI.IGT: failure " Patchwork
2023-07-27 11:27 ` [Intel-gfx] [PATCH 1/3] " Tvrtko Ursulin
2023-07-27 12:23 ` Andi Shyti
2023-08-01 12:17 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for series starting with [1/3] drm/i915/gt: Simplify shmem_create_from_object map_type selection (rev2) Patchwork
2023-08-01 12:17 ` [Intel-gfx] ✗ Fi.CI.SPARSE: " Patchwork
2023-08-01 12:31 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2023-08-01 15:38 ` [Intel-gfx] ✗ Fi.CI.IGT: failure " Patchwork
  -- strict thread matches above, loose matches on Subject: below --
2023-08-01 15:32 [Intel-gfx] [PATCH 0/3] drm/i915: Fix Wa_22016122933 implementation Jonathan Cavitt
2023-08-01 15:32 ` [Intel-gfx] [PATCH 3/3] drm/i915/gt: Apply workaround 22016122933 correctly Jonathan Cavitt

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=ZMJhAMoG1RHE6Hnq@ashyti-mobl2.lan \
    --to=andi.shyti@linux.intel.com \
    --cc=chris.p.wilson@linux.intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=jonathan.cavitt@intel.com \
    --cc=matthew.d.roper@intel.com \
    --cc=nirmoy.das@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