diff options
Diffstat (limited to 'drivers/md/dm-crypt.c')
-rw-r--r-- | drivers/md/dm-crypt.c | 17 |
1 files changed, 1 insertions, 16 deletions
diff --git a/drivers/md/dm-crypt.c b/drivers/md/dm-crypt.c index e7a650f9ca07..d88b8eda3903 100644 --- a/drivers/md/dm-crypt.c +++ b/drivers/md/dm-crypt.c | |||
@@ -94,20 +94,6 @@ struct crypt_config { | |||
94 | static kmem_cache_t *_crypt_io_pool; | 94 | static kmem_cache_t *_crypt_io_pool; |
95 | 95 | ||
96 | /* | 96 | /* |
97 | * Mempool alloc and free functions for the page | ||
98 | */ | ||
99 | static void *mempool_alloc_page(gfp_t gfp_mask, void *data) | ||
100 | { | ||
101 | return alloc_page(gfp_mask); | ||
102 | } | ||
103 | |||
104 | static void mempool_free_page(void *page, void *data) | ||
105 | { | ||
106 | __free_page(page); | ||
107 | } | ||
108 | |||
109 | |||
110 | /* | ||
111 | * Different IV generation algorithms: | 97 | * Different IV generation algorithms: |
112 | * | 98 | * |
113 | * plain: the initial vector is the 32-bit low-endian version of the sector | 99 | * plain: the initial vector is the 32-bit low-endian version of the sector |
@@ -637,8 +623,7 @@ static int crypt_ctr(struct dm_target *ti, unsigned int argc, char **argv) | |||
637 | goto bad3; | 623 | goto bad3; |
638 | } | 624 | } |
639 | 625 | ||
640 | cc->page_pool = mempool_create(MIN_POOL_PAGES, mempool_alloc_page, | 626 | cc->page_pool = mempool_create_page_pool(MIN_POOL_PAGES, 0); |
641 | mempool_free_page, NULL); | ||
642 | if (!cc->page_pool) { | 627 | if (!cc->page_pool) { |
643 | ti->error = PFX "Cannot allocate page mempool"; | 628 | ti->error = PFX "Cannot allocate page mempool"; |
644 | goto bad4; | 629 | goto bad4; |