diff options
author | Tetsuo Handa <[email protected]> | 2014-08-03 20:02:03 +0900 |
---|---|---|
committer | Dave Airlie <[email protected]> | 2014-08-05 10:54:10 +1000 |
commit | 71336e011d1d2312bcbcaa8fcec7365024f3a95d (patch) | |
tree | 3e4a416ed2730c64b5fbb4975776d6f0b7041903 /tools/perf/scripts/python/sctop.py | |
parent | 22e71691fd54c637800d10816bbeba9cf132d218 (diff) |
drm/ttm: Fix possible stack overflow by recursive shrinker calls.
While ttm_dma_pool_shrink_scan() tries to take mutex before doing GFP_KERNEL
allocation, ttm_pool_shrink_scan() does not do it. This can result in stack
overflow if kmalloc() in ttm_page_pool_free() triggered recursion due to
memory pressure.
shrink_slab()
=> ttm_pool_shrink_scan()
=> ttm_page_pool_free()
=> kmalloc(GFP_KERNEL)
=> shrink_slab()
=> ttm_pool_shrink_scan()
=> ttm_page_pool_free()
=> kmalloc(GFP_KERNEL)
Change ttm_pool_shrink_scan() to do like ttm_dma_pool_shrink_scan() does.
Signed-off-by: Tetsuo Handa <[email protected]>
Cc: stable <[email protected]> [2.6.35+]
Signed-off-by: Dave Airlie <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/sctop.py')
0 files changed, 0 insertions, 0 deletions