linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/6] btrfs: find_device cleanups
@ 2019-01-17 15:32 Anand Jain
  2019-01-17 15:32 ` [PATCH 1/6] btrfs: merge btrfs_find_device_missing_or_by_path() into parent Anand Jain
                   ` (6 more replies)
  0 siblings, 7 replies; 22+ messages in thread
From: Anand Jain @ 2019-01-17 15:32 UTC (permalink / raw)
  To: linux-btrfs

find_device and its helper functions are as below

 btrfs_find_device_by_devspec()
 btrfs_find_device_missing_or_by_path()
 btrfs_find_device_by_path()
 btrfs_find_device()
 find_device()

Its quite confusing and too fragmented.

In this patch-set..
 1/6 and 2/6 -- btrfs_find_device_missing_or_by_path() is collapsed into
 btrfs_find_device_by_devspec() and cleanup the surviving function.

 3/6 -- rename btrfs_find_device_by_path() to find_device_by_superblock().

 4/6 and 5/6 -- collapses find_device() into btrfs_find_device().

 6/6 refactors btrfs_find_device() to return standard error code.

Resulting in..

btrfs_find_device():
 Mainly used to get struct btrfs_device internally for a given devid
 and or uuid and also helper function for btrfs_find_device_by_devspec().

btrfs_find_device_by_devspec() and a helper function find_device_by_superblock():
 Is mainly to retrieve the struct btrfs_device of a userland given device_path.

Anand Jain (6):
  btrfs: merge btrfs_find_device_missing_or_by_path() into parent
  btrfs: cleanup btrfs_find_device_by_devspec()
  btrfs: rename btrfs_find_device_by_path()
  btrfs: refactor btrfs_find_device() take fs_devices as argument
  btrfs: merge btrfs_find_device() and find_device()
  btrfs: refactor btrfs_find_device() return error code

 fs/btrfs/dev-replace.c |  12 ++--
 fs/btrfs/ioctl.c       |   9 +--
 fs/btrfs/scrub.c       |  16 +++--
 fs/btrfs/volumes.c     | 160 +++++++++++++++++++++----------------------------
 fs/btrfs/volumes.h     |   5 +-
 5 files changed, 93 insertions(+), 109 deletions(-)

-- 
1.8.3.1


^ permalink raw reply	[flat|nested] 22+ messages in thread

end of thread, other threads:[~2019-01-28 18:45 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-01-17 15:32 [PATCH 0/6] btrfs: find_device cleanups Anand Jain
2019-01-17 15:32 ` [PATCH 1/6] btrfs: merge btrfs_find_device_missing_or_by_path() into parent Anand Jain
2019-01-17 15:57   ` David Sterba
2019-01-17 15:32 ` [PATCH 2/6] btrfs: cleanup btrfs_find_device_by_devspec() Anand Jain
2019-01-17 15:57   ` David Sterba
2019-01-17 15:32 ` [PATCH 3/6] btrfs: rename btrfs_find_device_by_path() Anand Jain
2019-01-17 15:54   ` David Sterba
2019-01-18  6:13     ` Anand Jain
2019-01-18 17:05       ` David Sterba
2019-01-17 15:32 ` [PATCH 4/6] btrfs: refactor btrfs_find_device() take fs_devices as argument Anand Jain
2019-01-17 15:58   ` David Sterba
2019-01-17 15:32 ` [PATCH 5/6] btrfs: merge btrfs_find_device() and find_device() Anand Jain
2019-01-17 15:51   ` David Sterba
2019-01-19  6:48   ` [PATCH 5/6 v2] " Anand Jain
2019-01-23  5:28     ` Anand Jain
2019-01-28 18:44     ` David Sterba
2019-01-17 15:32 ` [PATCH 6/6] btrfs: refactor btrfs_find_device() return error code Anand Jain
2019-01-17 15:49   ` David Sterba
2019-01-18  6:13     ` Anand Jain
2019-01-18 17:20       ` David Sterba
2019-01-18 17:33 ` [PATCH 0/6] btrfs: find_device cleanups David Sterba
2019-01-19  6:54   ` Anand Jain

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).