]> git.baikalelectronics.ru Git - kernel.git/commit
Btrfs: free btrfs_device in place
authorLiu Bo <bo.li.liu@oracle.com>
Tue, 24 Oct 2017 05:02:54 +0000 (23:02 -0600)
committerDavid Sterba <dsterba@suse.com>
Mon, 22 Jan 2018 15:08:10 +0000 (16:08 +0100)
commitf0b6dcbb46a59bb8f28a228f0c553515e5b10c21
treeb8dfd6d916f24932ea15fd6c91dc7e17c119847b
parent11bd921ee3cb2c9c65dd41735d3f9042fb2ebc8e
Btrfs: free btrfs_device in place

It's pointless to defer it to a kthread helper as we're not under a
special context.

For reference, commit 63af5e604229 ("Btrfs: using rcu lock in the reader
side of devices list") introduced RCU freeing for device structures.

Originally the blkdev_put was called from free_device and rcu_barrier had
to be called. This is no longer required, bdev and our device structures
are now freed separately.

Signed-off-by: Liu Bo <bo.li.liu@oracle.com>
Reviewed-by: Anand Jain <anand.jain@oracle.com>
Reviewed-by: David Sterba <dsterba@suse.com>
[ enhance changelog ]
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/volumes.c
fs/btrfs/volumes.h