diff options
Diffstat (limited to 'mm/swap_state.c')
-rw-r--r-- | mm/swap_state.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/swap_state.c b/mm/swap_state.c index 65b81c92738f..ec42f01a8d02 100644 --- a/mm/swap_state.c +++ b/mm/swap_state.c | |||
@@ -125,6 +125,7 @@ int add_to_swap(struct page * page, gfp_t gfp_mask) | |||
125 | int err; | 125 | int err; |
126 | 126 | ||
127 | BUG_ON(!PageLocked(page)); | 127 | BUG_ON(!PageLocked(page)); |
128 | BUG_ON(!PageUptodate(page)); | ||
128 | 129 | ||
129 | for (;;) { | 130 | for (;;) { |
130 | entry = get_swap_page(); | 131 | entry = get_swap_page(); |
@@ -147,7 +148,6 @@ int add_to_swap(struct page * page, gfp_t gfp_mask) | |||
147 | 148 | ||
148 | switch (err) { | 149 | switch (err) { |
149 | case 0: /* Success */ | 150 | case 0: /* Success */ |
150 | SetPageUptodate(page); | ||
151 | SetPageDirty(page); | 151 | SetPageDirty(page); |
152 | return 1; | 152 | return 1; |
153 | case -EEXIST: | 153 | case -EEXIST: |