History

drm/ttm: Fix swapin regression

Commit "drm/ttm: Don't move non-existing data" didn't take the swapped-out corner case into account. This patch corrects that. Fixes blank screen after attempted suspend / hibernate on vmwgfx.

Thomas Hellstrom committed 12 years ago

Commit 2e6d8b41 parent 488574d1 file · +2 −1Browse files

Unified · Split

drivers/gpu/drm/ttm/ttm_bo_util.c+2−1
@@ -353,7 +353,8 @@ int ttm_bo_move_memcpy(struct ttm_buffer_object *bo, · 352 unmodified lines
353 * Don't move nonexistent data. Clear destination instead.353 * Don't move nonexistent data. Clear destination instead.
354 */354 */
355 if (old_iomap == NULL &&355 if (old_iomap == NULL &&
356 (ttm == NULL || ttm->state == tt_unpopulated)) {356 (ttm == NULL || (ttm->state == tt_unpopulated &&
357 !(ttm->page_flags & TTM_PAGE_FLAG_SWAPPED)))) {
357 memset_io(new_iomap, 0, new_mem->num_pages*PAGE_SIZE);358 memset_io(new_iomap, 0, new_mem->num_pages*PAGE_SIZE);
358 goto out2;359 goto out2;
359 }360 }

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t