From: Maarten Lankhorst Date: Wed, 28 Nov 2012 11:25:42 +0000 (+0000) Subject: drm/ttm: cope with reserved buffers on swap list in ttm_bo_swapout, v2 X-Git-Tag: v3.8-rc1~82^2~7 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2b7b3ad2fb8f904ae9ba7ca71323bc11c0978d91;p=pandora-kernel.git drm/ttm: cope with reserved buffers on swap list in ttm_bo_swapout, v2 Replace the while loop with a simple for each loop, and only run the delayed destroy cleanup if we can reserve the buffer first. No race occurs, since lru lock is never dropped any more. An empty list and a list full of unreservable buffers both cause -EBUSY to be returned, which is identical to the previous situation. Signed-off-by: Maarten Lankhorst Reviewed-by: Thomas Hellstrom Signed-off-by: Dave Airlie --- Reading git-diff-tree failed