diff options
author | Anand Jain <anand.jain@oracle.com> | 2014-10-15 08:46:54 +0800 |
---|---|---|
committer | David Sterba <dsterba@suse.cz> | 2014-10-16 12:08:59 +0200 |
commit | bdac35cea24d11d3bcb6682038f907ba05484525 (patch) | |
tree | 66e41f8711c8fd3f6e55071ee9e18137c7e10b41 /utils.c | |
parent | 38cfeef1033e254c0a1446fe6f4bbe6f30e1f5db (diff) |
btrfs-progs: open RW to register device using btrfs-control
We are passing device path to be registered with in kernel,
so we need to open with RW
Signed-off-by: Anand Jain <anand.jain@oracle.com>
Signed-off-by: David Sterba <dsterba@suse.cz>
Diffstat (limited to 'utils.c')
-rw-r--r-- | utils.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -1246,7 +1246,7 @@ void btrfs_register_one_device(char *fname) int ret; int e; - fd = open("/dev/btrfs-control", O_RDONLY); + fd = open("/dev/btrfs-control", O_RDWR); if (fd < 0) { fprintf(stderr, "failed to open /dev/btrfs-control " "skipping device registration: %s\n", |