1 From 985b823b919273fe1327d56d2196b4f92e5d0fae Mon Sep 17 00:00:00 2001
2 From: Linus Torvalds <torvalds@linux-foundation.org>
3 Date: Fri, 2 Jul 2010 10:04:42 +1000
4 Subject: drm/i915: fix hibernation since i915 self-reclaim fixes
6 From: Linus Torvalds <torvalds@linux-foundation.org>
8 commit 985b823b919273fe1327d56d2196b4f92e5d0fae upstream.
10 Since commit 4bdadb9785696439c6e2b3efe34aa76df1149c83 ("drm/i915:
11 Selectively enable self-reclaim"), we've been passing GFP_MOVABLE to the
12 i915 page allocator where we weren't before due to some over-eager
13 removal of the page mapping gfp_flags games the code used to play.
15 This caused hibernate on Intel hardware to result in a lot of memory
16 corruptions on resume. See for example
18 http://bugzilla.kernel.org/show_bug.cgi?id=13811
20 Reported-by: Evengi Golov (in bugzilla)
21 Signed-off-by: Dave Airlie <airlied@redhat.com>
22 Tested-by: M. Vefa Bicakci <bicave@superonline.com>
23 Cc: Chris Wilson <chris@chris-wilson.co.uk>
24 Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
25 Cc: Hugh Dickins <hugh.dickins@tiscali.co.uk>
26 Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
27 Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
30 drivers/gpu/drm/i915/i915_gem.c | 2 +-
31 1 file changed, 1 insertion(+), 1 deletion(-)
33 --- a/drivers/gpu/drm/i915/i915_gem.c
34 +++ b/drivers/gpu/drm/i915/i915_gem.c
35 @@ -2312,7 +2312,7 @@ i915_gem_object_get_pages(struct drm_gem
36 mapping = inode->i_mapping;
37 for (i = 0; i < page_count; i++) {
38 page = read_cache_page_gfp(mapping, i,
39 - mapping_gfp_mask (mapping) |