mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-01-10 07:00:48 +00:00
Revert "Btrfs: device_list_add() should not update list when mounted"
This reverts commit b96de000bc8bc9688b3a2abea4332bd57648a49f. This commit is triggering failures to mount by subvolume id in some configurations. The main problem is how many different ways this scanning function is used, both for scanning while mounted and unmounted. A proper cleanup is too big for late rcs. For now, just revert the commit and we'll put a better fix into a later merge window. Signed-off-by: Chris Mason <clm@fb.com>
This commit is contained in:
parent
125c4cf9f3
commit
0f23ae74f5
@ -529,12 +529,12 @@ static noinline int device_list_add(const char *path,
|
||||
*/
|
||||
|
||||
/*
|
||||
* As of now don't allow update to btrfs_fs_device through
|
||||
* the btrfs dev scan cli, after FS has been mounted.
|
||||
* For now, we do allow update to btrfs_fs_device through the
|
||||
* btrfs dev scan cli after FS has been mounted. We're still
|
||||
* tracking a problem where systems fail mount by subvolume id
|
||||
* when we reject replacement on a mounted FS.
|
||||
*/
|
||||
if (fs_devices->opened) {
|
||||
return -EBUSY;
|
||||
} else {
|
||||
if (!fs_devices->opened && found_transid < device->generation) {
|
||||
/*
|
||||
* That is if the FS is _not_ mounted and if you
|
||||
* are here, that means there is more than one
|
||||
@ -542,7 +542,6 @@ static noinline int device_list_add(const char *path,
|
||||
* with larger generation number or the last-in if
|
||||
* generation are equal.
|
||||
*/
|
||||
if (found_transid < device->generation)
|
||||
return -EEXIST;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user