public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] xfstests: 091,240,268 fix for xfs on 4k sector hard drive
@ 2013-07-24 18:32 Dwight Engen
  2013-07-24 23:57 ` [PATCH] xfstests: 091, 240, 268 " Dave Chinner
  0 siblings, 1 reply; 10+ messages in thread
From: Dwight Engen @ 2013-07-24 18:32 UTC (permalink / raw)
  To: xfs

Tests 091,240, and 268 are failing on my 4k sector hard disk. The dio writes
from fsx and aiodio_sparse2 are failing on xfs with EINVAL which is returned
from the check at the top of xfs_file_dio_aio_write().

The fix is to use blockdev -getpbsz to get the physical sector size instead
of the logical sector size. This makes 091 and 268 work. 240 will not run
on a 4k drive since fs block size == device block size. Tested against
xfs,ext4, and btrfs.

Signed-off-by: Dwight Engen <dwight.engen@oracle.com>
---
 tests/generic/091 | 2 +-
 tests/generic/240 | 2 +-
 tests/generic/263 | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/tests/generic/091 b/tests/generic/091
index cee012d..8a11505 100755
--- a/tests/generic/091
+++ b/tests/generic/091
@@ -54,7 +54,7 @@ run_fsx()
 }
 
 psize=`$here/src/feature -s`
-bsize=`blockdev --getss $TEST_DEV`
+bsize=`blockdev --getpbsz $TEST_DEV`
 kernel=`uname -r  | sed -e 's/\(2\..\).*/\1/'`
 
 # 2.4 Linux kernels support bsize aligned direct I/O only
diff --git a/tests/generic/240 b/tests/generic/240
index e692318..ac8560d 100755
--- a/tests/generic/240
+++ b/tests/generic/240
@@ -60,7 +60,7 @@ rm -f $seqres.full
 
 rm -f $TEST_DIR/aiodio_sparse
 
-logical_block_size=`blockdev --getss $TEST_DEV`
+logical_block_size=`blockdev --getpbsz $TEST_DEV`
 fs_block_size=`stat -f $TEST_DIR | grep "Block size:" | awk '{print $3}'`
 
 if [ $fs_block_size -le $logical_block_size ]; then
diff --git a/tests/generic/263 b/tests/generic/263
index 377b199..9795bc2 100755
--- a/tests/generic/263
+++ b/tests/generic/263
@@ -54,7 +54,7 @@ run_fsx()
 }
 
 psize=`$here/src/feature -s`
-bsize=`blockdev --getss $TEST_DEV`
+bsize=`blockdev --getpbsz $TEST_DEV`
 
 run_fsx -N 10000  -o 8192   -l 500000 -r PSIZE -t BSIZE -w BSIZE -Z
 run_fsx -N 10000  -o 128000 -l 500000 -r PSIZE -t BSIZE -w BSIZE -Z
-- 
1.8.1.4

_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs

^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2013-08-19 19:54 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-07-24 18:32 [PATCH] xfstests: 091,240,268 fix for xfs on 4k sector hard drive Dwight Engen
2013-07-24 23:57 ` [PATCH] xfstests: 091, 240, 268 " Dave Chinner
2013-07-25  4:36   ` Stan Hoeppner
2013-07-25 14:27     ` Dwight Engen
2013-07-25 15:23       ` Eric Sandeen
2013-07-25 18:43         ` Dwight Engen
2013-07-25 19:07           ` Eric Sandeen
2013-08-15 18:20     ` Ric Wheeler
2013-08-15 23:30       ` Stan Hoeppner
2013-08-19 19:54         ` Stan Hoeppner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox