From: Miao Xie Date: Thu, 24 Jul 2014 03:37:13 +0000 (+0800) Subject: Btrfs: Fix wrong device size when we are resizing the device X-Git-Tag: omap-fixes-against-v3.17-rc3~41^2~12 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7df69d3e94d6de537fd1afb574c760d8dc83ab60;p=pandora-kernel.git Btrfs: Fix wrong device size when we are resizing the device total_bytes of device is just a in-memory variant which is used to record the size of the device, and it might be changed before we resize a device, if the resize operation fails, it will be fallbacked. But some code used it to update on-disk metadata of the device, it would cause the problem that on-disk metadata of the devices was not consistent. We should use the other variant named disk_total_bytes to update the on-disk metadata of device, because that variant is updated only when the resize operation is successful. Fix it. Signed-off-by: Miao Xie Signed-off-by: Chris Mason --- Reading git-diff-tree failed