lightnvm: pblk: simplify meta. memory allocation

smeta size will always be suitable for a kmalloc allocation. Simplify
the code and leave the vmalloc fallback only for emeta, where the pblk
configuration has an impact.

Signed-off-by: Javier González <javier@cnexlabs.com>
Signed-off-by: Matias Bjørling <matias@cnexlabs.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
Javier González
2017-06-26 11:57:21 +02:00
committed by Jens Axboe
parent f9c101523d
commit f680f19aa6
4 changed files with 8 additions and 8 deletions

View File

@@ -665,7 +665,8 @@ next_rq:
}
reinit_completion(&wait);
bio_put(bio);
if (likely(pblk->l_mg.emeta_alloc_type == PBLK_VMALLOC_META))
bio_put(bio);
if (rqd.error) {
if (dir == WRITE)