common.attr: get block size of test fs not root fs
authorEryu Guan <eguan@redhat.com>
Wed, 4 Jul 2012 03:11:10 +0000 (22:11 -0500)
committerEric Sandeen <sandeen@sandeen.net>
Wed, 4 Jul 2012 03:11:10 +0000 (22:11 -0500)
commit187e92903f3b8d59658b8ed7d1aa847ae6365f3c
treebb8328c24a7526c9cf3b8b3a23e2d513d91f9034
parent98758371f55ebc37c96c21923933d7f9d8cf017e
common.attr: get block size of test fs not root fs

stat -f $TEST_DEV shows block size of the fs where $TEST_DEV
resides, usually it is the root fs. This will fail 020 on non-4096 block
size ext2/3/4, also 4096 block size ext2/3/4 on ppc64.

Instead, stat -f $TEST_DIR will show block size of the fs to be tested.

Tested and passed on ext2/3/4, xfs, btrfs with all supported block size.

Cc: Eric Sandeen <esandeen@redhat.com>
Signed-off-by: Eryu Guan <eguan@redhat.com>
Signed-off-by: Eric Sandeen <sandeen@redhat.com>
common.attr