]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
btrfs: merge btrfs_find_device and find_device
authorAnand Jain <anand.jain@oracle.com>
Tue, 10 Dec 2019 00:48:00 +0000 (01:48 +0100)
committerMarcelo Henrique Cerri <marcelo.cerri@canonical.com>
Fri, 17 Jan 2020 17:23:10 +0000 (14:23 -0300)
commit34857e155fbbd5a8df8325e7869c78df08bb7c75
tree194742710aceae58ffc9f2937a9c273e23964932
parent2f05c56ffe9a69b139ee9be265b834e61edcbcb7
btrfs: merge btrfs_find_device and find_device

CVE-2019-18885

Both btrfs_find_device() and find_device() does the same thing except
that the latter does not take the seed device onto account in the device
scanning context. We can merge them.

Signed-off-by: Anand Jain <anand.jain@oracle.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
(backported from commit 09ba3bc9dd150457c506e4661380a6183af651c1)
[ Connor Kuehl: 'metadata_uuid' does not exist yet, so use the
  previously used 'fsid' data member in 'struct btrfs_fs_devices' ]
Signed-off-by: Connor Kuehl <connor.kuehl@canonical.com>
Acked-by: Marcelo Henrique Cerri <marcelo.cerri@canonical.com>
Acked-by: Stefan Bader <stefan.bader@canonical.com>
Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
fs/btrfs/dev-replace.c
fs/btrfs/ioctl.c
fs/btrfs/scrub.c
fs/btrfs/volumes.c
fs/btrfs/volumes.h