Re: [PATCH v2 1/2] Btrfs: add more valid checks for superblock

2016-11-28 Thread Liu Bo
On Fri, Nov 25, 2016 at 05:50:19PM +0100, David Sterba wrote: > On Fri, Jun 03, 2016 at 12:05:14PM -0700, Liu Bo wrote: > > @@ -6648,6 +6648,7 @@ int btrfs_read_chunk_tree(struct btrfs_root *root) > > struct btrfs_key found_key; > > int ret; > > int slot; > > + u64 total_dev = 0; > >

Re: [PATCH v2 1/2] Btrfs: add more valid checks for superblock

2016-11-25 Thread David Sterba
On Fri, Jun 03, 2016 at 12:05:14PM -0700, Liu Bo wrote: > @@ -6648,6 +6648,7 @@ int btrfs_read_chunk_tree(struct btrfs_root *root) > struct btrfs_key found_key; > int ret; > int slot; > + u64 total_dev = 0; > > root = root->fs_info->chunk_root; > > @@ -6689,6

Re: [PATCH v2 1/2] Btrfs: add more valid checks for superblock

2016-06-06 Thread David Sterba
On Fri, Jun 03, 2016 at 12:05:14PM -0700, Liu Bo wrote: > This adds valid checks for super_total_bytes, super_bytes_used and > super_stripesize, super_num_devices. > > Reported-by: Vegard Nossum > Reported-by: Quentin Casasnovas >

[PATCH v2 1/2] Btrfs: add more valid checks for superblock

2016-06-03 Thread Liu Bo
This adds valid checks for super_total_bytes, super_bytes_used and super_stripesize, super_num_devices. Reported-by: Vegard Nossum Reported-by: Quentin Casasnovas Signed-off-by: Liu Bo --- v2: - Check