Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Matt Roper <matthew.d.roper@intel.com>
To: <fei.yang@intel.com>
Cc: intel-xe@lists.freedesktop.org
Subject: Re: [PATCH 1/1] drm/xe: correct the assertion for number of PTEs
Date: Fri, 26 Jan 2024 18:39:59 -0800	[thread overview]
Message-ID: <20240127023959.GI7083@mdroper-desk1.amr.corp.intel.com> (raw)
In-Reply-To: <20240125065245.1204731-2-fei.yang@intel.com>

On Wed, Jan 24, 2024 at 10:52:45PM -0800, fei.yang@intel.com wrote:
> From: Fei Yang <fei.yang@intel.com>
> 
> While one MI_STORE_DATA_IMM can take no more than 0x1fe qwords,
> the size of the pgtable can be 512 entries.
> 
> Fixes: 43d48379c939 ("drm/xe: correct the calculation of remaining size")
> Cc: Matt Roper <matthew.d.roper@intel.com>
> Signed-off-by: Fei Yang <fei.yang@intel.com>

Reviewed-by: Matt Roper <matthew.d.roper@intel.com>

and applied to drm-xe-next.  Thanks for the patch.


Matt

> ---
>  drivers/gpu/drm/xe/xe_migrate.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/xe/xe_migrate.c b/drivers/gpu/drm/xe/xe_migrate.c
> index 7abf15546ced..9ab004871f9a 100644
> --- a/drivers/gpu/drm/xe/xe_migrate.c
> +++ b/drivers/gpu/drm/xe/xe_migrate.c
> @@ -71,6 +71,7 @@ struct xe_migrate {
>  #define NUM_KERNEL_PDE 17
>  #define NUM_PT_SLOTS 32
>  #define LEVEL0_PAGE_TABLE_ENCODE_SIZE SZ_2M
> +#define MAX_NUM_PTE 512
>  
>  /*
>   * Although MI_STORE_DATA_IMM's "length" field is 10-bits, 0x3FE is the largest
> @@ -1107,7 +1108,7 @@ static void write_pgtable(struct xe_tile *tile, struct xe_bb *bb, u64 ppgtt_ofs,
>  	 * This shouldn't be possible in practice.. might change when 16K
>  	 * pages are used. Hence the assert.
>  	 */
> -	xe_tile_assert(tile, update->qwords <= MAX_PTE_PER_SDI);
> +	xe_tile_assert(tile, update->qwords < MAX_NUM_PTE);
>  	if (!ppgtt_ofs)
>  		ppgtt_ofs = xe_migrate_vram_ofs(tile_to_xe(tile),
>  						xe_bo_addr(update->pt_bo, 0,
> -- 
> 2.25.1
> 

-- 
Matt Roper
Graphics Software Engineer
Linux GPU Platform Enablement
Intel Corporation

  parent reply	other threads:[~2024-01-27  2:40 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-25  6:52 [PATCH 0/1] drm/xe: correct the assertion for number of PTEs fei.yang
2024-01-25  6:52 ` [PATCH 1/1] " fei.yang
2024-01-25 15:17   ` Souza, Jose
2024-01-27  2:39   ` Matt Roper [this message]
2024-01-25  8:06 ` ✓ CI.Patch_applied: success for " Patchwork
2024-01-25  8:06 ` ✗ CI.checkpatch: warning " Patchwork
2024-01-25  8:07 ` ✓ CI.KUnit: success " Patchwork
2024-01-25  8:14 ` ✓ CI.Build: " Patchwork
2024-01-25  8:15 ` ✓ CI.Hooks: " Patchwork
2024-01-25  8:16 ` ✓ CI.checksparse: " Patchwork
2024-01-25  8:39 ` ✓ CI.BAT: " 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=20240127023959.GI7083@mdroper-desk1.amr.corp.intel.com \
    --to=matthew.d.roper@intel.com \
    --cc=fei.yang@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