summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGoffredo Baroncelli <kreijack@libero.it>2014-02-13 20:19:44 +0100
committerChris Mason <clm@fb.com>2014-03-21 06:23:22 -0700
commit4701f523907753a54270a657d40f16f06b3c23c4 (patch)
treee22ccd492db66fc1c7b1d0571f46078f5b5ba089
parent002d5e14304aae3c4df45b36f99cdeec51a87b4c (diff)
btrfs-progs: Allow use of get_device_info()
Allow the use of get_device_info() for different units. Signed-off-by: Goffredo Baroncelli <kreijack@inwind.it> Signed-off-by: David Sterba <dsterba@suse.cz> Signed-off-by: Chris Mason <clm@fb.com>
-rw-r--r--utils.c2
-rw-r--r--utils.h2
2 files changed, 3 insertions, 1 deletions
diff --git a/utils.c b/utils.c
index 398678f1..cbbe4655 100644
--- a/utils.c
+++ b/utils.c
@@ -1641,7 +1641,7 @@ void close_file_or_dir(int fd, DIR *dirstream)
close(fd);
}
-static int get_device_info(int fd, u64 devid,
+int get_device_info(int fd, u64 devid,
struct btrfs_ioctl_dev_info_args *di_args)
{
int ret;
diff --git a/utils.h b/utils.h
index 888ebe89..3c62066a 100644
--- a/utils.h
+++ b/utils.h
@@ -98,5 +98,7 @@ int lookup_ino_rootid(int fd, u64 *rootid);
int btrfs_scan_lblkid(int update_kernel);
int get_btrfs_mount(const char *dev, char *mp, size_t mp_size);
int find_mount_root(const char *path, char **mount_root);
+int get_device_info(int fd, u64 devid,
+ struct btrfs_ioctl_dev_info_args *di_args);
#endif