]> git.baikalelectronics.ru Git - kernel.git/commit
btrfs: create a helper function to read the disk super
authorAnand Jain <anand.jain@oracle.com>
Sat, 13 Feb 2016 02:01:29 +0000 (10:01 +0800)
committerDavid Sterba <dsterba@suse.com>
Thu, 28 Apr 2016 08:59:04 +0000 (10:59 +0200)
commit0ed1999045826ba68f5d6ac9d0a7877001152cf8
tree169d42512bc7185e91bd03ab3ea95f5caf8f9c23
parentd2c7d382593c33c66c89cf7206062c20164b85b1
btrfs: create a helper function to read the disk super

A part of code from btrfs_scan_one_device() is moved to a new function
btrfs_read_disk_super(), so that former function looks cleaner. (In this
process it also moves the code which ensures null terminating label). So
this creates easy opportunity to merge various duplicate codes on read
disk super. Earlier attempt to merge duplicate codes highlighted that
there were some issues for which there are duplicate codes (to read disk
super), however it was not clear what was the issue. So until we figure
that out, its better to keep them in a separate functions.

Signed-off-by: Anand Jain <anand.jain@oracle.com>
[ use GFP_KERNEL, PAGE_CACHE_ removal related fixups ]
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/volumes.c