On Tue, Jan 08, 2019 at 02:08:18PM +0800, Qu Wenruo wrote:
> [BUG]
> Linux v5.0-rc1 will fail fstests/btrfs/163 with the following kernel
> message:
> 
>   BTRFS error (device dm-6): dev extent devid 1 physical offset 13631488 len 
> 8388608 is beyond device boundary 0
>   BTRFS error (device dm-6): failed to verify dev extents against chunks: -117
>   BTRFS error (device dm-6): open_ctree failed
> 
> [CAUSE]
> Commit cf90d884b347 ("btrfs: Introduce mount time chunk <-> dev extent
> mapping check") introduced strict check on dev extents.
> 
> We use btrfs_find_device() with dev uuid and fs uuid set to NULL, and
> only dependent on @devid to find the real device.
> 
> For seed devices, we call clone_fs_devices() in open_seed_devices() to
> allow us search seed devices directly.
> 
> However clone_fs_devices() just populates devices with devid and dev
> uuid, without populating other essential members, like disk_total_bytes.

That's quite fragile but works as a quick fix, queued for 5.0-rc,
thanks.

Reply via email to