diff options
| author | Rikard Falkeborn <[email protected]> | 2021-02-09 23:48:15 +0000 |
|---|---|---|
| committer | Christian König <[email protected]> | 2021-02-25 13:40:24 +0000 |
| commit | fff72bb569ee97a5dafe287e6b9ff4ecdf4f6d6d (patch) | |
| tree | 4c1851f2ae0668822a394fa6bcff33f0192e8bdd /drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | |
| parent | dma-buf: heaps: Fix the name used when exporting dmabufs to be the actual hea... (diff) | |
| download | kernel-fff72bb569ee97a5dafe287e6b9ff4ecdf4f6d6d.tar.gz kernel-fff72bb569ee97a5dafe287e6b9ff4ecdf4f6d6d.zip | |
drm/amdgpu/ttm: constify static vm_operations_struct
The only usage of amdgpu_ttm_vm_ops is to assign its address to the
vm_ops field in the vm_area_struct struct. Make it const to allow the
compiler to put it in read-only memory.
Signed-off-by: Rikard Falkeborn <[email protected]>
Reviewed-by: Christian König <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Signed-off-by: Christian König <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c')
| -rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c index 29cfb0809634..a785acc09f20 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c @@ -2002,7 +2002,7 @@ unlock: return ret; } -static struct vm_operations_struct amdgpu_ttm_vm_ops = { +static const struct vm_operations_struct amdgpu_ttm_vm_ops = { .fault = amdgpu_ttm_fault, .open = ttm_bo_vm_open, .close = ttm_bo_vm_close, |
