Skip to content

Commit f72c2db

Browse files
committed
drm/gpuvm: rename struct drm_gpuva_manager to struct drm_gpuvm
Rename struct drm_gpuva_manager to struct drm_gpuvm including corresponding functions. This way the GPUVA manager's structures align very well with the documentation of VM_BIND [1] and VM_BIND locking [2]. It also provides a better foundation for the naming of data structures and functions introduced for implementing a common dma-resv per GPU-VM including tracking of external and evicted objects in subsequent patches. [1] Documentation/gpu/drm-vm-bind-async.rst [2] Documentation/gpu/drm-vm-bind-locking.rst Cc: Thomas Hellström <[email protected]> Cc: Matthew Brost <[email protected]> Acked-by: Dave Airlie <[email protected]> Acked-by: Christian König <[email protected]> Signed-off-by: Danilo Krummrich <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
1 parent 89755ee commit f72c2db

File tree

8 files changed

+309
-310
lines changed

8 files changed

+309
-310
lines changed

drivers/gpu/drm/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ drm-y := \
4545
drm_vblank.o \
4646
drm_vblank_work.o \
4747
drm_vma_manager.o \
48-
drm_gpuva_mgr.o \
48+
drm_gpuvm.o \
4949
drm_writeback.o
5050
drm-$(CONFIG_DRM_LEGACY) += \
5151
drm_agpsupport.o \

drivers/gpu/drm/drm_debugfs.c

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
#include <drm/drm_file.h>
4141
#include <drm/drm_gem.h>
4242
#include <drm/drm_managed.h>
43-
#include <drm/drm_gpuva_mgr.h>
43+
#include <drm/drm_gpuvm.h>
4444

4545
#include "drm_crtc_internal.h"
4646
#include "drm_internal.h"
@@ -189,31 +189,31 @@ static const struct file_operations drm_debugfs_fops = {
189189
/**
190190
* drm_debugfs_gpuva_info - dump the given DRM GPU VA space
191191
* @m: pointer to the &seq_file to write
192-
* @mgr: the &drm_gpuva_manager representing the GPU VA space
192+
* @gpuvm: the &drm_gpuvm representing the GPU VA space
193193
*
194194
* Dumps the GPU VA mappings of a given DRM GPU VA manager.
195195
*
196196
* For each DRM GPU VA space drivers should call this function from their
197197
* &drm_info_list's show callback.
198198
*
199-
* Returns: 0 on success, -ENODEV if the &mgr is not initialized
199+
* Returns: 0 on success, -ENODEV if the &gpuvm is not initialized
200200
*/
201201
int drm_debugfs_gpuva_info(struct seq_file *m,
202-
struct drm_gpuva_manager *mgr)
202+
struct drm_gpuvm *gpuvm)
203203
{
204-
struct drm_gpuva *va, *kva = &mgr->kernel_alloc_node;
204+
struct drm_gpuva *va, *kva = &gpuvm->kernel_alloc_node;
205205

206-
if (!mgr->name)
206+
if (!gpuvm->name)
207207
return -ENODEV;
208208

209209
seq_printf(m, "DRM GPU VA space (%s) [0x%016llx;0x%016llx]\n",
210-
mgr->name, mgr->mm_start, mgr->mm_start + mgr->mm_range);
210+
gpuvm->name, gpuvm->mm_start, gpuvm->mm_start + gpuvm->mm_range);
211211
seq_printf(m, "Kernel reserved node [0x%016llx;0x%016llx]\n",
212212
kva->va.addr, kva->va.addr + kva->va.range);
213213
seq_puts(m, "\n");
214214
seq_puts(m, " VAs | start | range | end | object | object offset\n");
215215
seq_puts(m, "-------------------------------------------------------------------------------------------------------------\n");
216-
drm_gpuva_for_each_va(va, mgr) {
216+
drm_gpuvm_for_each_va(va, gpuvm) {
217217
if (unlikely(va == kva))
218218
continue;
219219

0 commit comments

Comments
 (0)