linux/drivers/gpu/drm/ttm
Konrad Rzeszutek Wilk 2c05114d23 drm/ttm/dma: Fix accounting error when calling ttm_mem_global_free_page and don't try to free freed pages.
The code to figure out how many pages to shrink the pool
ends up capping the 'count' at _manager->options.max_size - which is OK.
Except that the 'count' is also used when accounting for how many pages
are recycled - which we end up with the invalid values. This fixes
it by using a different value for the amount of pages to shrink.

On top of that we would free the cached page pool - which is nonsense
as they are deleted from the pool - so there are no free pages in that
pool..

Also we also missed the opportunity to batch the amount of pages
to free (similar to how ttm_page_alloc.c does it). This reintroduces
the code that was lost during rebasing.

Reviewed-by: Jerome Glisse <jglisse@redhat.com>
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2012-01-06 09:30:15 +00:00
..
Makefile drm/ttm: provide dma aware ttm page pool code V9 2011-12-06 10:39:33 +00:00
ttm_agp_backend.c drm/ttm: merge ttm_backend and ttm_tt V5 2011-12-06 10:39:17 +00:00
ttm_bo.c Merge tag 'v3.2-rc6' of /home/airlied/devel/kernel/linux-2.6 into drm-core-next 2011-12-20 14:43:53 +00:00
ttm_bo_manager.c
ttm_bo_util.c drm/ttm: simplify memory accounting for ttm user v2 2011-12-06 10:40:11 +00:00
ttm_bo_vm.c drm/ttm: introduce callback for ttm_tt populate & unpopulate V4 2011-12-06 10:39:24 +00:00
ttm_execbuf_util.c Revert "drm/ttm: add a way to bo_wait for either the last read or last write" 2011-10-27 18:28:37 +02:00
ttm_lock.c atomic: use <linux/atomic.h> 2011-07-26 16:49:47 -07:00
ttm_memory.c drm/ttm: provide dma aware ttm page pool code V9 2011-12-06 10:39:33 +00:00
ttm_module.c
ttm_object.c atomic: use <linux/atomic.h> 2011-07-26 16:49:47 -07:00
ttm_page_alloc.c drm/ttm: isolate dma data from ttm_tt V4 2011-12-06 10:40:02 +00:00
ttm_page_alloc_dma.c drm/ttm/dma: Fix accounting error when calling ttm_mem_global_free_page and don't try to free freed pages. 2012-01-06 09:30:15 +00:00
ttm_tt.c drm/ttm: isolate dma data from ttm_tt V4 2011-12-06 10:40:02 +00:00