Merge branch 'drm-next-4.12' of git://people.freedesktop.org/~agd5f/linux into drm...
[linux-2.6-microblaze.git] / mm / swap_state.c
index 7bfb9bd..539b888 100644 (file)
@@ -523,7 +523,7 @@ int init_swap_address_space(unsigned int type, unsigned long nr_pages)
        unsigned int i, nr;
 
        nr = DIV_ROUND_UP(nr_pages, SWAP_ADDRESS_SPACE_PAGES);
-       spaces = vzalloc(sizeof(struct address_space) * nr);
+       spaces = kvzalloc(sizeof(struct address_space) * nr, GFP_KERNEL);
        if (!spaces)
                return -ENOMEM;
        for (i = 0; i < nr; i++) {