]> git.baikalelectronics.ru Git - kernel.git/commit
drm/ttm: Don't move non-existing data
authorThomas Hellstrom <thellstrom@vmware.com>
Mon, 18 Nov 2013 07:30:38 +0000 (23:30 -0800)
committerThomas Hellstrom <thellstrom@vmware.com>
Wed, 20 Nov 2013 11:43:28 +0000 (03:43 -0800)
commitf6a01f861e7a38309e6b3be8231d8cae3ffabded
treea0ee8aa093f279b1c21af6f8c467767b950ddadd
parent196277957bc534c64c9b3f19e9248de7b52ff433
drm/ttm: Don't move non-existing data

If ttm_bo_move_memcpy was instructed to move a non-populated ttm to
io memory, it would first populate the ttm, then move the data and then
destroy the ttm. That's stupid. However, some drivers might have relied on
this to clear io memory from old stuff. So instead of a NOP, which would
be the most efficient, just clear the destination.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
drivers/gpu/drm/ttm/ttm_bo_util.c