]> git.baikalelectronics.ru Git - kernel.git/commit
drm/ttm: Allocate the page pool manager in the heap.
authorFrancisco Jerez <currojerez@riseup.net>
Sun, 4 Jul 2010 02:03:07 +0000 (04:03 +0200)
committerDave Airlie <airlied@redhat.com>
Wed, 7 Jul 2010 02:14:11 +0000 (12:14 +1000)
commit9f332355d5922dff0d05e4d010e085963c075cc8
tree3030a0ee387f3187a5a30f8f4cc745788c7d69e7
parent628cd9c6cb6d7610608503516a4d56139a5bedd1
drm/ttm: Allocate the page pool manager in the heap.

Repeated ttm_page_alloc_init/fini fails noisily because the pool
manager kobj isn't zeroed out between uses (we could do just that but
statically allocated kobjects are generally considered a bad thing).
Move it to kzalloc'ed memory.

Note that this patch drops the refcounting behavior of the pool
allocator init/fini functions: it would have led to a race condition
in its current form, and anyway it was never exploited.

This fixes a regression with reloading kms modules at runtime, since
page allocator was introduced.

Signed-off-by: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Dave Airlie <airlied@redhat.com>
drivers/gpu/drm/ttm/ttm_page_alloc.c
include/drm/ttm/ttm_page_alloc.h