Commit 5b7aa160 authored by Alan Cox's avatar Alan Cox Committed by Greg Kroah-Hartman

gma500: trim some of the debug

Signed-off-by: default avatarAlan Cox <alan@linux.intel.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 3cc76c1c
...@@ -727,16 +727,12 @@ static void psb_user_framebuffer_destroy(struct drm_framebuffer *fb) ...@@ -727,16 +727,12 @@ static void psb_user_framebuffer_destroy(struct drm_framebuffer *fb)
/* Should never get stolen memory for a user fb */ /* Should never get stolen memory for a user fb */
WARN_ON(r->stolen); WARN_ON(r->stolen);
pr_err("user framebuffer destroy %p, fbdev %p\n",
psbfb, psbfb->fbdev);
/* Check if we are erroneously live */ /* Check if we are erroneously live */
list_for_each_entry(crtc, &dev->mode_config.crtc_list, head) list_for_each_entry(crtc, &dev->mode_config.crtc_list, head)
if (crtc->fb == fb) if (crtc->fb == fb)
reset = 1; reset = 1;
if (reset)
pr_err("DRM: gma500, forcing reset\n");
if (reset) if (reset)
/* /*
* Now force a sane response before we permit the DRM crc layer to * Now force a sane response before we permit the DRM crc layer to
......
...@@ -51,7 +51,6 @@ void psb_gem_free_object(struct drm_gem_object *obj) ...@@ -51,7 +51,6 @@ void psb_gem_free_object(struct drm_gem_object *obj)
} }
drm_gem_object_release(obj); drm_gem_object_release(obj);
/* This must occur last as it frees up the memory of the GEM object */ /* This must occur last as it frees up the memory of the GEM object */
pr_err("GEM destroyed %p, %p\n", gtt, obj);
psb_gtt_free_range(obj->dev, gtt); psb_gtt_free_range(obj->dev, gtt);
} }
...@@ -177,8 +176,6 @@ static int psb_gem_create(struct drm_file *file, ...@@ -177,8 +176,6 @@ static int psb_gem_create(struct drm_file *file,
size = roundup(size, PAGE_SIZE); size = roundup(size, PAGE_SIZE);
dev_err(dev->dev, "GEM creating %lld\n", size);
/* Allocate our object - for now a direct gtt range which is not /* Allocate our object - for now a direct gtt range which is not
stolen memory backed */ stolen memory backed */
r = psb_gtt_alloc_range(dev, size, "gem", 0); r = psb_gtt_alloc_range(dev, size, "gem", 0);
...@@ -206,8 +203,6 @@ static int psb_gem_create(struct drm_file *file, ...@@ -206,8 +203,6 @@ static int psb_gem_create(struct drm_file *file,
/* We have the initial and handle reference but need only one now */ /* We have the initial and handle reference but need only one now */
drm_gem_object_unreference(&r->gem); drm_gem_object_unreference(&r->gem);
*handlep = handle; *handlep = handle;
dev_err(dev->dev, "GEM handle %x for %p OK\n",
handle, &r->gem);
return 0; return 0;
} }
...@@ -283,12 +278,9 @@ int psb_gem_fault(struct vm_area_struct *vma, struct vm_fault *vmf) ...@@ -283,12 +278,9 @@ int psb_gem_fault(struct vm_area_struct *vma, struct vm_fault *vmf)
something from beneath our feet */ something from beneath our feet */
mutex_lock(&dev->struct_mutex); mutex_lock(&dev->struct_mutex);
dev_err(dev->dev, "Fault on GTT %p\n", r);
/* For now the mmap pins the object and it stays pinned. As things /* For now the mmap pins the object and it stays pinned. As things
stand that will do us no harm */ stand that will do us no harm */
if (r->mmapping == 0) { if (r->mmapping == 0) {
dev_err(dev->dev, "Need to pin %p\n", r);
ret = psb_gtt_pin(r); ret = psb_gtt_pin(r);
if (ret < 0) { if (ret < 0) {
DRM_ERROR("gma500: pin failed: %d\n", ret); DRM_ERROR("gma500: pin failed: %d\n", ret);
...@@ -302,13 +294,10 @@ int psb_gem_fault(struct vm_area_struct *vma, struct vm_fault *vmf) ...@@ -302,13 +294,10 @@ int psb_gem_fault(struct vm_area_struct *vma, struct vm_fault *vmf)
page_offset = ((unsigned long) vmf->virtual_address - vma->vm_start) page_offset = ((unsigned long) vmf->virtual_address - vma->vm_start)
>> PAGE_SHIFT; >> PAGE_SHIFT;
dev_err(dev->dev, "Page offset %p %d\n", r, (int)page_offset);
/* CPU view of the page, don't go via the GART for CPU writes */ /* CPU view of the page, don't go via the GART for CPU writes */
pfn = page_to_phys(r->pages[page_offset]) >> PAGE_SHIFT; pfn = page_to_phys(r->pages[page_offset]) >> PAGE_SHIFT;
ret = vm_insert_pfn(vma, (unsigned long)vmf->virtual_address, pfn); ret = vm_insert_pfn(vma, (unsigned long)vmf->virtual_address, pfn);
dev_err(dev->dev, "PFN %ld for VA %p = %d\n", pfn, vmf->virtual_address, ret);
fail: fail:
mutex_unlock(&dev->struct_mutex); mutex_unlock(&dev->struct_mutex);
switch (ret) { switch (ret) {
......
...@@ -314,7 +314,6 @@ struct gtt_range *psb_gtt_alloc_range(struct drm_device *dev, int len, ...@@ -314,7 +314,6 @@ struct gtt_range *psb_gtt_alloc_range(struct drm_device *dev, int len,
len, start, end, PAGE_SIZE, NULL, NULL); len, start, end, PAGE_SIZE, NULL, NULL);
if (ret == 0) { if (ret == 0) {
gt->offset = gt->resource.start - r->start; gt->offset = gt->resource.start - r->start;
dev_err(dev->dev, "GTT new %p, %d\n", gt, gt->stolen);
return gt; return gt;
} }
kfree(gt); kfree(gt);
...@@ -341,7 +340,6 @@ static void psb_gtt_destroy(struct kref *kref) ...@@ -341,7 +340,6 @@ static void psb_gtt_destroy(struct kref *kref)
} }
WARN_ON(gt->in_gart && !gt->stolen); WARN_ON(gt->in_gart && !gt->stolen);
release_resource(&gt->resource); release_resource(&gt->resource);
pr_err("GTT destroyed %p, %d\n", gt, gt->stolen);
kfree(gt); kfree(gt);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment