block: Fix dev_t minor allocation lifetime
Releases the dev_t minor when all references are closed to prevent another device from acquiring the same major/minor. Since the partition's release may be invoked from call_rcu's soft-irq context, the ext_dev_idr's mutex had to be replaced with a spinlock so as not so sleep. Signed-off-by: NKeith Busch <keith.busch@intel.com> Cc: stable@kernel.org Signed-off-by: NJens Axboe <axboe@fb.com>
Showing
想要评论请 注册 或 登录