All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Kalvala, Haridhar" <haridhar.kalvala@intel.com>
To: Matt Roper <matthew.d.roper@intel.com>
Cc: intel-xe@lists.freedesktop.org
Subject: Re: [Intel-xe] [PATCH] drm/xe/pvc: Don't try to invalidate AuxCCS TLB
Date: Fri, 26 May 2023 09:24:19 +0530	[thread overview]
Message-ID: <cb5c50af-d8d2-2790-e39d-e1f706b3bce6@intel.com> (raw)
In-Reply-To: <20230525150051.GS10045@mdroper-desk1.amr.corp.intel.com>


On 5/25/2023 8:30 PM, Matt Roper wrote:
> On Thu, May 25, 2023 at 06:46:03PM +0530, Kalvala, Haridhar wrote:
>> On 5/25/2023 12:56 AM, Matt Roper wrote:
>>> Generally !has_flatccs implies that a platform has AuxCCS compression
>>> and thus needs to invalidate the AuxCCS TLB.  However PVC is a special
>>> case because it has no compression of either type (FlatCCS or AuxCCS)
>>> so we should avoid writing to non-existent AuxCCS registers.
>> Hi Matt,
>>
>> Looks good to me.
>>
>> Just a query, if their is no compression support, do we need to remove flag
>>
>> ".has_flat_ccs" from PVC description structure.
> You mean from graphics_xehpc?  That already indicates that flat_ccs is
> disabled:
>
>          .has_flat_ccs = 0,
>
> which is correct.  The change here is just to make sure that the driver
> doesn't assume that lack of flatccs implies that we have auxccs instead
> (on PVC we have neither flatccs nor auxccs).
>
>
> Matt
>
>> Regards,
>>
>> Haridhar Kalvala
Reviewed-by: Haridhar Kalvala <haridhar.kalvala@intel.com>
>>> Signed-off-by: Matt Roper <matthew.d.roper@intel.com>
>>> ---
>>>    drivers/gpu/drm/xe/xe_ring_ops.c | 16 ++++++++++++++--
>>>    1 file changed, 14 insertions(+), 2 deletions(-)
>>>
>>> diff --git a/drivers/gpu/drm/xe/xe_ring_ops.c b/drivers/gpu/drm/xe/xe_ring_ops.c
>>> index 74c1b5dfbaee..d2fa0b4c8bcc 100644
>>> --- a/drivers/gpu/drm/xe/xe_ring_ops.c
>>> +++ b/drivers/gpu/drm/xe/xe_ring_ops.c
>>> @@ -190,6 +190,18 @@ static void __emit_job_gen12_copy(struct xe_sched_job *job, struct xe_lrc *lrc,
>>>    	xe_lrc_write_ring(lrc, dw, i * sizeof(*dw));
>>>    }
>>> +static bool has_aux_ccs(struct xe_device *xe)
>>> +{
>>> +	/*
>>> +	 * PVC is a special case that has no compression of either type
>>> +	 * (FlatCCS or AuxCCS).
>>> +	 */
>>> +	if (xe->info.platform == XE_PVC)
>>> +		return false;
>>> +
>>> +	return !xe->info.has_flat_ccs;
>>> +}
>>> +
>>>    static void __emit_job_gen12_video(struct xe_sched_job *job, struct xe_lrc *lrc,
>>>    				   u64 batch_addr, u32 seqno)
>>>    {
>>> @@ -202,7 +214,7 @@ static void __emit_job_gen12_video(struct xe_sched_job *job, struct xe_lrc *lrc,
>>>    	dw[i++] = preparser_disable(true);
>>>    	/* hsdes: 1809175790 */
>>> -	if (!xe->info.has_flat_ccs) {
>>> +	if (has_aux_ccs(xe)) {
>>>    		if (decode)
>>>    			i = emit_aux_table_inv(gt, VD0_AUX_NV, dw, i);
>>>    		else
>>> @@ -248,7 +260,7 @@ static void __emit_job_gen12_render_compute(struct xe_sched_job *job,
>>>    	i = emit_pipe_invalidate(mask_flags, dw, i);
>>>    	/* hsdes: 1809175790 */
>>> -	if (!xe->info.has_flat_ccs)
>>> +	if (has_aux_ccs(xe))
>>>    		i = emit_aux_table_inv(gt, GFX_CCS_AUX_NV, dw, i);
>>>    	dw[i++] = preparser_disable(false);
>> -- 
>> Regards,
>> Haridhar Kalvala
>>
-- 
Regards,
Haridhar Kalvala


      reply	other threads:[~2023-05-26  3:54 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-24 19:26 [Intel-xe] [PATCH] drm/xe/pvc: Don't try to invalidate AuxCCS TLB Matt Roper
2023-05-24 19:53 ` [Intel-xe] ✓ CI.Patch_applied: success for " Patchwork
2023-05-24 19:54 ` [Intel-xe] ✓ CI.KUnit: " Patchwork
2023-05-24 19:58 ` [Intel-xe] ✓ CI.Build: " Patchwork
2023-05-24 20:34 ` [Intel-xe] ○ CI.BAT: info " Patchwork
2023-05-25 13:16 ` [Intel-xe] [PATCH] " Kalvala, Haridhar
2023-05-25 15:00   ` Matt Roper
2023-05-26  3:54     ` Kalvala, Haridhar [this message]

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=cb5c50af-d8d2-2790-e39d-e1f706b3bce6@intel.com \
    --to=haridhar.kalvala@intel.com \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=matthew.d.roper@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.