[PATCH] drm/xe: Remove references to CONFIG_DRM_XE_DEVMEM_MIRROR

Cavitt, Jonathan jonathan.cavitt at intel.com
Thu Jul 10 21:19:03 UTC 2025


-----Original Message-----
From: Intel-xe <intel-xe-bounces at lists.freedesktop.org> On Behalf Of Matthew Brost
Sent: Thursday, July 10, 2025 1:54 PM
To: intel-xe at lists.freedesktop.org
Subject: [PATCH] drm/xe: Remove references to CONFIG_DRM_XE_DEVMEM_MIRROR
> 
> The prefetch code was referencing CONFIG_DRM_XE_DEVMEM_MIRROR, which has
> been replaced by CONFIG_DRM_XE_PAGEMAP. As a result, prefetches were
> limited to SRAM. Update the code to use CONFIG_DRM_XE_PAGEMAP instead of
> the deprecated option.
> 
> Fixes: f86ad0ed620c ("drm/gpusvm, drm/pagemap: Move migration functionality to drm_pagemap")
> Signed-off-by: Matthew Brost <matthew.brost at intel.com>

LGTM, though I will admit it's a bit weird this didn't cause the kernel to fail to compile
before, as CONFIG_DRM_XE_DEVMEM_MIRROR doesn't seem to have an official
declaration in the code to be referenced.

Maybe that's because it's "just" a config declaration?

Just thinking aloud.

Reviewed-by: Jonathan Cavitt <jonathan.cavitt at intel.com>
-Jonathan Cavitt

> ---
>  drivers/gpu/drm/xe/xe_vm.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/gpu/drm/xe/xe_vm.c b/drivers/gpu/drm/xe/xe_vm.c
> index e875ea4658a9..2035604121e6 100644
> --- a/drivers/gpu/drm/xe/xe_vm.c
> +++ b/drivers/gpu/drm/xe/xe_vm.c
> @@ -2380,7 +2380,7 @@ vm_bind_ioctl_ops_create(struct xe_vm *vm, struct xe_vma_ops *vops,
>  
>  			ctx.read_only = xe_vma_read_only(vma);
>  			ctx.devmem_possible = IS_DGFX(vm->xe) &&
> -					      IS_ENABLED(CONFIG_DRM_XE_DEVMEM_MIRROR);
> +					      IS_ENABLED(CONFIG_DRM_XE_PAGEMAP);
>  
>  			for_each_tile(tile, vm->xe, id)
>  				tile_mask |= 0x1 << id;
> @@ -2887,7 +2887,7 @@ static int check_ufence(struct xe_vma *vma)
>  
>  static int prefetch_ranges(struct xe_vm *vm, struct xe_vma_op *op)
>  {
> -	bool devmem_possible = IS_DGFX(vm->xe) && IS_ENABLED(CONFIG_DRM_XE_DEVMEM_MIRROR);
> +	bool devmem_possible = IS_DGFX(vm->xe) && IS_ENABLED(CONFIG_DRM_XE_PAGEMAP);
>  	struct xe_vma *vma = gpuva_to_vma(op->base.prefetch.va);
>  	int err = 0;
>  
> -- 
> 2.34.1
> 
> 


More information about the Intel-xe mailing list