diff options
author | David Sterba <dsterba@suse.cz> | 2013-03-20 09:21:10 -0400 |
---|---|---|
committer | Josef Bacik <jbacik@fusionio.com> | 2013-05-06 15:54:23 -0400 |
commit | 5e2a4b25da232a2f4ce264a4b2ae113d0b2a799c (patch) | |
tree | 3addd74042de37f9a29c36f345a65069b431b14a /fs/btrfs | |
parent | c2cf52eb71aeb902682e0c1fa29e4e9e4a7f4ffc (diff) |
btrfs: deprecate subvolrootid mount option
This mount option was a workaround when subvol= assumed path relative
to the default subvolume, not the toplevel one. This was fixed long time
ago and subvolrootid has no effect.
Signed-off-by: David Sterba <dsterba@suse.cz>
Signed-off-by: Josef Bacik <jbacik@fusionio.com>
Diffstat (limited to 'fs/btrfs')
-rw-r--r-- | fs/btrfs/super.c | 17 |
1 files changed, 4 insertions, 13 deletions
diff --git a/fs/btrfs/super.c b/fs/btrfs/super.c index 3fd4f2c3d529..3c404b8e83bb 100644 --- a/fs/btrfs/super.c +++ b/fs/btrfs/super.c | |||
@@ -643,7 +643,7 @@ out: | |||
643 | */ | 643 | */ |
644 | static int btrfs_parse_early_options(const char *options, fmode_t flags, | 644 | static int btrfs_parse_early_options(const char *options, fmode_t flags, |
645 | void *holder, char **subvol_name, u64 *subvol_objectid, | 645 | void *holder, char **subvol_name, u64 *subvol_objectid, |
646 | u64 *subvol_rootid, struct btrfs_fs_devices **fs_devices) | 646 | struct btrfs_fs_devices **fs_devices) |
647 | { | 647 | { |
648 | substring_t args[MAX_OPT_ARGS]; | 648 | substring_t args[MAX_OPT_ARGS]; |
649 | char *device_name, *opts, *orig, *p; | 649 | char *device_name, *opts, *orig, *p; |
@@ -686,16 +686,8 @@ static int btrfs_parse_early_options(const char *options, fmode_t flags, | |||
686 | } | 686 | } |
687 | break; | 687 | break; |
688 | case Opt_subvolrootid: | 688 | case Opt_subvolrootid: |
689 | intarg = 0; | 689 | printk(KERN_WARNING |
690 | error = match_int(&args[0], &intarg); | 690 | "btrfs: 'subvolrootid' mount option is deprecated and has no effect\n"); |
691 | if (!error) { | ||
692 | /* we want the original fs_tree */ | ||
693 | if (!intarg) | ||
694 | *subvol_rootid = | ||
695 | BTRFS_FS_TREE_OBJECTID; | ||
696 | else | ||
697 | *subvol_rootid = intarg; | ||
698 | } | ||
699 | break; | 691 | break; |
700 | case Opt_device: | 692 | case Opt_device: |
701 | device_name = match_strdup(&args[0]); | 693 | device_name = match_strdup(&args[0]); |
@@ -1073,7 +1065,6 @@ static struct dentry *btrfs_mount(struct file_system_type *fs_type, int flags, | |||
1073 | fmode_t mode = FMODE_READ; | 1065 | fmode_t mode = FMODE_READ; |
1074 | char *subvol_name = NULL; | 1066 | char *subvol_name = NULL; |
1075 | u64 subvol_objectid = 0; | 1067 | u64 subvol_objectid = 0; |
1076 | u64 subvol_rootid = 0; | ||
1077 | int error = 0; | 1068 | int error = 0; |
1078 | 1069 | ||
1079 | if (!(flags & MS_RDONLY)) | 1070 | if (!(flags & MS_RDONLY)) |
@@ -1081,7 +1072,7 @@ static struct dentry *btrfs_mount(struct file_system_type *fs_type, int flags, | |||
1081 | 1072 | ||
1082 | error = btrfs_parse_early_options(data, mode, fs_type, | 1073 | error = btrfs_parse_early_options(data, mode, fs_type, |
1083 | &subvol_name, &subvol_objectid, | 1074 | &subvol_name, &subvol_objectid, |
1084 | &subvol_rootid, &fs_devices); | 1075 | &fs_devices); |
1085 | if (error) { | 1076 | if (error) { |
1086 | kfree(subvol_name); | 1077 | kfree(subvol_name); |
1087 | return ERR_PTR(error); | 1078 | return ERR_PTR(error); |