search for: btrfs_rm_devic

Displaying 13 results from an estimated 13 matches for "btrfs_rm_devic".

Did you mean: btrfs_rm_device
2013 Mar 02
1
[PATCH] btrfs: return EPERM in btrfs_rm_device()
Currently there are error paths in btrfs_rm_device() where EINVAL is returned telling the user they passed an invalid argument even though they passed a valid device. Change to return EPERM instead as the operation is not permitted. Signed-off-by: Jerry Snitselaar <jerry.snitselaar@oracle.com> --- fs/btrfs/volumes.c | 8 ++++---- 1 file ch...
2011 Apr 20
4
[PATCH 1/5] Btrfs: fix bh leak on __btrfs_open_devices path
''bh'' is forgot to release if no error is detected Signed-off-by: Xiao Guangrong <xiaoguangrong@cn.fujitsu.com> --- fs/btrfs/volumes.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c index 8b9fb8c..69fc902 100644 --- a/fs/btrfs/volumes.c +++ b/fs/btrfs/volumes.c @@ -631,6 +631,7 @@ static int
2008 Jun 30
0
[PATCH] Null terminate strings passed in from userspace
...@@ ret = -EFAULT; goto out; } + vol_args->name[BTRFS_PATH_NAME_MAX] = ''\0''; ret = btrfs_init_new_device(root, vol_args->name); out: @@ -501,6 +497,7 @@ ret = -EFAULT; goto out; } + vol_args->name[BTRFS_PATH_NAME_MAX] = ''\0''; ret = btrfs_rm_device(root, vol_args->name); out: -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
2011 Oct 28
0
[PATCH] Btrfs: don't try to touch sb->s_bdev
...Signed-off-by: Ilya Dryomov <idryomov@gmail.com> --- fs/btrfs/volumes.c | 2 -- 1 files changed, 0 insertions(+), 2 deletions(-) diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c index f2a4cc7..afd6a1e 100644 --- a/fs/btrfs/volumes.c +++ b/fs/btrfs/volumes.c @@ -1376,8 +1376,6 @@ int btrfs_rm_device(struct btrfs_root *root, char *device_path) next_device = list_entry(root->fs_info->fs_devices->devices.next, struct btrfs_device, dev_list); - if (device->bdev == root->fs_info->sb->s_bdev) - root->fs_info->sb->s_bdev = next_device->bdev; if (device-&...
2012 Nov 14
0
fs/btrfs/volumes.c:1505:1: warning: label 'error_close' defined but not used
...kernel/git/josef/btrfs-next.git master head: 0cb8658e96f1ba2ff2d730224cb31e231edd318d commit: 7017ac470ed5b029bc683883714a7f4a4ed34c33 Btrfs: move some common code into a subfunction date: 2 days ago config: make ARCH=x86_64 allyesconfig All warnings: fs/btrfs/volumes.c: In function ''btrfs_rm_device'': fs/btrfs/volumes.c:1505:1: warning: label ''error_close'' defined but not used [-Wunused-label] vim +1505 +/error_close fs/btrfs/volumes.c 2b82032c Yan Zheng 2008-11-17 1489 * at this point, the device is zero sized. We want to 2b82032c Yan Zheng 2008-11...
2012 Jul 07
0
block rsv returned -28
...180774] [<ffffffffa03465ac>] btrfs_relocate_block_group+0x13f/0x267 [btrfs] [ 1105.181471] [<ffffffffa032b849>] btrfs_relocate_chunk.isra.51+0x4b/0x2ce [btrfs] [ 1105.182037] [<ffffffffa032e532>] btrfs_shrink_device+0x1fa/0x34d [btrfs] [ 1105.182623] [<ffffffffa033011f>] btrfs_rm_device+0x1f4/0x4a6 [btrfs] [ 1105.183206] [<ffffffffa0331ad2>] btrfs_ioctl_rm_dev+0x95/0xbe [btrfs] [ 1105.183797] [<ffffffffa0335632>] btrfs_ioctl+0x3b4/0x6d6 [btrfs] [ 1105.184369] [<ffffffff8110f9af>] do_vfs_ioctl+0x240/0x254 [ 1105.184390] [<ffffffff8110fa0e>] sys_ioctl+0x...
2009 Jan 19
4
[Patch] Btrfs: use BTRFS_VOL_NAME_MAX for struct btrfs_ioctl_vol_args
..., vol_args->name); out: @@ -713,7 +713,7 @@ static long btrfs_ioctl_rm_dev(struct btrfs_root *root, void __user *arg) ret = -EFAULT; goto out; } - vol_args->name[BTRFS_PATH_NAME_MAX] = ''\0''; + vol_args->name[BTRFS_VOL_NAME_MAX] = ''\0''; ret = btrfs_rm_device(root, vol_args->name); out: diff --git a/fs/btrfs/ioctl.h b/fs/btrfs/ioctl.h index b320b10..f5d182a 100644 --- a/fs/btrfs/ioctl.h +++ b/fs/btrfs/ioctl.h @@ -22,12 +22,10 @@ #define BTRFS_IOCTL_MAGIC 0x94 #define BTRFS_VOL_NAME_MAX 255 -#define BTRFS_PATH_NAME_MAX 4087 -/* this should b...
2009 Aug 05
3
RAID[56] with arbitrary numbers of "parity" stripes.
...map_lookup *map) { - if (map->type & BTRFS_BLOCK_GROUP_RAID5) - return 1; - else if (map->type & BTRFS_BLOCK_GROUP_RAID6) - return 2; - else - return 0; + return map->type >> 56; } static inline int nr_data_stripes(struct map_lookup *map) @@ -1176,19 +1171,16 @@ int btrfs_rm_device(struct btrfs_root *root, char *device_path) goto out; } - if ((all_avail & BTRFS_BLOCK_GROUP_RAID5) && - root->fs_info->fs_devices->rw_devices <= 2) { - printk(KERN_ERR "btrfs: unable to go below two " - "devices on raid5\n"); - ret...
2011 Aug 08
7
“bio too big” regression and silent data corruption in 3.0
tl;dr version: 3.0 produces “bio too big” dmesg entries and silently corrupts data in “meta-raid1/data-single” configurations on disks with different max_hw_sectors, where 2.6.38 worked fine. tl;dr side-issue: on-line removal of partitions holding “single” data attempts to create raid0 (rather than single) block groups. If it can''t get enough room for raid0 over all remaining disks, it
2011 Aug 26
0
[PATCH] Btrfs: make some functions return void
...root, u8 *fsid) diff --git a/fs/btrfs/volumes.h b/fs/btrfs/volumes.h index 6d866db..f019e54 100644 --- a/fs/btrfs/volumes.h +++ b/fs/btrfs/volumes.h @@ -202,7 +202,7 @@ int btrfs_add_device(struct btrfs_trans_handle *trans, struct btrfs_root *root, struct btrfs_device *device); int btrfs_rm_device(struct btrfs_root *root, char *device_path); -int btrfs_cleanup_fs_uuids(void); +void btrfs_cleanup_fs_uuids(void); int btrfs_num_copies(struct btrfs_mapping_tree *map_tree, u64 logical, u64 len); int btrfs_grow_device(struct btrfs_trans_handle *trans, struct btrfs_device *device, u64 n...
2011 Aug 23
40
[PATCH 00/21] [RFC] Btrfs: restriper
Hello, This patch series adds an initial implementation of restriper (it''s a clever name for relocation framework that allows to do selective profile changing and selective balancing with some goodies like pausing/resuming and reporting progress to the user. Profile changing is global (per-FS) so far, per-subvolume profiles require some discussion and can be implemented in future.
2011 Mar 08
6
[PATCH v1 0/6] btrfs: scrub
This series adds an initial implementation for scrub. It works quite straightforward. The usermode issues an ioctl for each device in the fs. For each device, it enumerates the allocated device chunks. For each chunk, the contained extents are enumerated and the data checksums fetched. The extents are read sequentially and the checksums verified. If an error occurs (checksum or EIO), a good copy
2011 Oct 04
68
[patch 00/65] Error handling patchset v3
Hi all - Here''s my current error handling patchset, against 3.1-rc8. Almost all of this patchset is preparing for actual error handling. Before we start in on that work, I''m trying to reduce the surface we need to worry about. It turns out that there is a ton of code that returns an error code but never actually reports an error. The patchset has grown to 65 patches. 46 of them