gt->pages = NULL;
}
-int psb_gtt_pin(struct gtt_range *gt)
+int psb_gem_pin(struct gtt_range *gt)
{
int ret = 0;
struct drm_device *dev = gt->gem.dev;
return ret;
}
-void psb_gtt_unpin(struct gtt_range *gt)
+void psb_gem_unpin(struct gtt_range *gt)
{
struct drm_device *dev = gt->gem.dev;
struct drm_psb_private *dev_priv = to_drm_psb_private(dev);
{
/* Undo the mmap pin if we are destroying the object */
if (gt->mmapping) {
- psb_gtt_unpin(gt);
+ psb_gem_unpin(gt);
gt->mmapping = 0;
}
WARN_ON(gt->in_gart && !gt->stolen);
/* For now the mmap pins the object and it stays pinned. As things
stand that will do us no harm */
if (r->mmapping == 0) {
- err = psb_gtt_pin(r);
+ err = psb_gem_pin(r);
if (err < 0) {
dev_err(dev->dev, "gma500: pin failed: %d\n", err);
ret = vmf_error(err);
struct gtt_range *
psb_gem_create(struct drm_device *dev, u64 size, const char *name, bool stolen, u32 align);
-int psb_gtt_pin(struct gtt_range *gt);
-void psb_gtt_unpin(struct gtt_range *gt);
+int psb_gem_pin(struct gtt_range *gt);
+void psb_gem_unpin(struct gtt_range *gt);
#endif
/* We are displaying this buffer, make sure it is actually loaded
into the GTT */
- ret = psb_gtt_pin(gtt);
+ ret = psb_gem_pin(gtt);
if (ret < 0)
goto gma_pipe_set_base_exit;
start = gtt->offset;
gma_pipe_cleaner:
/* If there was a previous display we can now unpin it */
if (old_fb)
- psb_gtt_unpin(to_gtt_range(old_fb->obj[0]));
+ psb_gem_unpin(to_gtt_range(old_fb->obj[0]));
gma_pipe_set_base_exit:
gma_power_end(dev);
/* Unpin the old GEM object */
if (gma_crtc->cursor_obj) {
gt = to_gtt_range(gma_crtc->cursor_obj);
- psb_gtt_unpin(gt);
+ psb_gem_unpin(gt);
drm_gem_object_put(gma_crtc->cursor_obj);
gma_crtc->cursor_obj = NULL;
}
gt = to_gtt_range(obj);
/* Pin the memory into the GTT */
- ret = psb_gtt_pin(gt);
+ ret = psb_gem_pin(gt);
if (ret) {
dev_err(dev->dev, "Can not pin down handle 0x%x\n", handle);
goto unref_cursor;
/* unpin the old bo */
if (gma_crtc->cursor_obj) {
gt = to_gtt_range(gma_crtc->cursor_obj);
- psb_gtt_unpin(gt);
+ psb_gem_unpin(gt);
drm_gem_object_put(gma_crtc->cursor_obj);
}
if (crtc->primary->fb) {
gt = to_gtt_range(crtc->primary->fb->obj[0]);
- psb_gtt_unpin(gt);
+ psb_gem_unpin(gt);
}
}