diff options
Diffstat (limited to 'mm/frame_vector.c')
-rw-r--r-- | mm/frame_vector.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/mm/frame_vector.c b/mm/frame_vector.c index db77dcb38afd..72ebec18629c 100644 --- a/mm/frame_vector.c +++ b/mm/frame_vector.c | |||
@@ -200,10 +200,7 @@ struct frame_vector *frame_vector_create(unsigned int nr_frames) | |||
200 | * Avoid higher order allocations, use vmalloc instead. It should | 200 | * Avoid higher order allocations, use vmalloc instead. It should |
201 | * be rare anyway. | 201 | * be rare anyway. |
202 | */ | 202 | */ |
203 | if (size <= PAGE_SIZE) | 203 | vec = kvmalloc(size, GFP_KERNEL); |
204 | vec = kmalloc(size, GFP_KERNEL); | ||
205 | else | ||
206 | vec = vmalloc(size); | ||
207 | if (!vec) | 204 | if (!vec) |
208 | return NULL; | 205 | return NULL; |
209 | vec->nr_allocated = nr_frames; | 206 | vec->nr_allocated = nr_frames; |