]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/commit - drivers/lightnvm/rrpc.c
lightnvm: remove _unlocked variant of [get/put]_blk
authorMatias Bjørling <m@bjorling.me>
Thu, 7 Jul 2016 07:54:19 +0000 (09:54 +0200)
committerJens Axboe <axboe@fb.com>
Thu, 7 Jul 2016 14:51:52 +0000 (08:51 -0600)
commit41285fad511a2c3746bee7ccb3b2f21b70305c14
tree960420e74ab3069dff06c171f31041c3883f0b0b
parent8c39eddbf2842861f6c7412bd498c9d880b1c9e8
lightnvm: remove _unlocked variant of [get/put]_blk

The [get/put]_blk API enables targets to get ownership of blocks at
runtime. This information is currently not recorded on disk, and the
information is therefore lost on power failure. To restore the
metadata, the [get/put]_blk must persist its metadata. In that case,
we need to control the outer lock, so that we can disable them while
updating the on-disk metadata. Fortunately, the _unlocked versions can
be removed, which allows us to move the lock into the [get/put]_blk
functions.

Signed-off-by: Matias Bjørling <m@bjorling.me>
Signed-off-by: Jens Axboe <axboe@fb.com>
drivers/lightnvm/core.c
drivers/lightnvm/gennvm.c
drivers/lightnvm/rrpc.c
include/linux/lightnvm.h