Re: [PATCH] btrfs: replace: Reset on-disk dev stats value after replace

2018-08-01 Thread David Sterba
On Tue, Jul 31, 2018 at 04:20:21PM +0900, Misono Tomohiro wrote: > on-disk devs stats value is updated in btrfs_run_dev_stats(), > which is called during commit transaction, if device->dev_stats_ccnt > is not zero. > > Since current replace operation does not touch dev_stats_ccnt, > on-disk dev st

[PATCH] btrfs: replace: Reset on-disk dev stats value after replace

2018-07-31 Thread Misono Tomohiro
on-disk devs stats value is updated in btrfs_run_dev_stats(), which is called during commit transaction, if device->dev_stats_ccnt is not zero. Since current replace operation does not touch dev_stats_ccnt, on-disk dev stats value is not updated. Therefore "btrfs device stats" may return old devic