From: Jani Nikula Date: Wed, 17 Jan 2024 12:20:43 +0000 (+0200) Subject: drm/xe: make gpuvm_ops const X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=480ea9e306c7fdbfb24b0af046c28c10b98a74ab;p=linux.git drm/xe: make gpuvm_ops const Place the function pointers in rodata. Reviewed-by: Thomas Hellström Link: https://patchwork.freedesktop.org/patch/msgid/20240117122044.1544174-4-jani.nikula@intel.com Signed-off-by: Jani Nikula --- diff --git a/drivers/gpu/drm/xe/xe_vm.c b/drivers/gpu/drm/xe/xe_vm.c index a7e7a0b240991..7ea0f151d223c 100644 --- a/drivers/gpu/drm/xe/xe_vm.c +++ b/drivers/gpu/drm/xe/xe_vm.c @@ -1054,7 +1054,7 @@ static struct drm_gpuva_op *xe_vm_op_alloc(void) static void xe_vm_free(struct drm_gpuvm *gpuvm); -static struct drm_gpuvm_ops gpuvm_ops = { +static const struct drm_gpuvm_ops gpuvm_ops = { .op_alloc = xe_vm_op_alloc, .vm_bo_validate = xe_gpuvm_validate, .vm_free = xe_vm_free,