diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2017-01-16 18:21:28 +0300 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2017-01-19 13:15:26 +0300 |
commit | 718659a63054261d052cd94f2f9502111ff5173f (patch) | |
tree | 905327dcc07eb6575164567a33b42f73af09b641 /drivers/gpu/drm/i915/i915_drv.h | |
parent | be1e341513ca23b0668b7b0f26fa6e2ffc46ba20 (diff) | |
download | linux-718659a63054261d052cd94f2f9502111ff5173f.tar.xz |
drm/i915: Rename some warts in the VMA API
Whilst writing testcases to exercise the VMA API, some oddities came to
light, such as i915_gem_obj_lookup_or_create(). Joonas suggested
i915_vma_instance() as a neat replacement, so rename them, move them to
i915_vma.c and add some kerneldoc as a sugary bonus.
s/i915_gem_obj_to_vma/i915_vma_lookup/
s/i915_gem_obj_lookup_or_create_vma/i915_vma_instance/
Suggested-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20170116152131.18089-2-chris@chris-wilson.co.uk
Diffstat (limited to 'drivers/gpu/drm/i915/i915_drv.h')
-rw-r--r-- | drivers/gpu/drm/i915/i915_drv.h | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h index b67f419ffba6..566adcc8a0eb 100644 --- a/drivers/gpu/drm/i915/i915_drv.h +++ b/drivers/gpu/drm/i915/i915_drv.h @@ -3374,16 +3374,6 @@ struct drm_gem_object *i915_gem_prime_import(struct drm_device *dev, struct dma_buf *i915_gem_prime_export(struct drm_device *dev, struct drm_gem_object *gem_obj, int flags); -struct i915_vma * -i915_gem_obj_to_vma(struct drm_i915_gem_object *obj, - struct i915_address_space *vm, - const struct i915_ggtt_view *view); - -struct i915_vma * -i915_gem_obj_lookup_or_create_vma(struct drm_i915_gem_object *obj, - struct i915_address_space *vm, - const struct i915_ggtt_view *view); - static inline struct i915_hw_ppgtt * i915_vm_to_ppgtt(struct i915_address_space *vm) { @@ -3394,7 +3384,7 @@ static inline struct i915_vma * i915_gem_object_to_ggtt(struct drm_i915_gem_object *obj, const struct i915_ggtt_view *view) { - return i915_gem_obj_to_vma(obj, &to_i915(obj->base.dev)->ggtt.base, view); + return i915_vma_lookup(obj, &to_i915(obj->base.dev)->ggtt.base, view); } /* i915_gem_fence_reg.c */ |