Btrfs: fail on mismatched subvol and subvolid mount options
authorOmar Sandoval <osandov@osandov.com>
Mon, 18 May 2015 09:16:29 +0000 (02:16 -0700)
committerChris Mason <clm@fb.com>
Wed, 3 Jun 2015 11:03:00 +0000 (04:03 -0700)
commitbb289b7be62db84b9630ce00367444c810cada2c
treead1ce1c258642737a303b345464007284ce98073
parentfa3306595071ae03e181c2336d0dcd8f5e3cf9b0
Btrfs: fail on mismatched subvol and subvolid mount options

There's nothing to stop a user from passing both subvol= and subvolid=
to mount, but if they don't refer to the same subvolume, someone is
going to be surprised at some point. Error out on this case, but allow
users to pass in both if they do match (which they could, for example,
get out of /proc/mounts).

Reviewed-by: David Sterba <dsterba@suse.cz>
Signed-off-by: Omar Sandoval <osandov@osandov.com>
Signed-off-by: Chris Mason <clm@fb.com>
fs/btrfs/super.c