All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] generic/448: don't disable extent zeroing if extent_max_zeroout_kb isn't supported
@ 2017-07-18  8:27 Xiao Yang
  2017-07-18 13:18 ` Eryu Guan
  0 siblings, 1 reply; 12+ messages in thread
From: Xiao Yang @ 2017-07-18  8:27 UTC (permalink / raw)
  To: fstests; +Cc: Xiao Yang

On some old kernel(e.g. v3.5), this case fails because it can not create
extent_max_zeroout_kb file, as below:
  Silence is golden
 +./tests/generic/448: line 54: /sys/fs/ext4/sda5/extent_max_zeroout_kb: No such file or directory
  seek sanity check failed!

The extent_max_zeroout_kb file is introduced by:
  67a5da564f97('ext4: make the zero-out chunk size tunable')

We should only disable extent zeroing when extent_max_zeroout_kb is supported.

Signed-off-by: Xiao Yang <yangx.jy@cn.fujitsu.com>
---
 tests/generic/448 | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tests/generic/448 b/tests/generic/448
index 87b99d7..3e92742 100755
--- a/tests/generic/448
+++ b/tests/generic/448
@@ -51,7 +51,8 @@ _require_test_program "seek_sanity_test"
 # Disable extent zeroing for ext4 as that change where holes are created
 if [ "$FSTYP" = "ext4" ]; then
 	DEV=`_short_dev $TEST_DEV`
-	echo 0 >/sys/fs/ext4/$DEV/extent_max_zeroout_kb
+	[ -f /sys/fs/ext4/$DEV/extent_max_zeroout_kb ] \
+	&& echo 0 >/sys/fs/ext4/$DEV/extent_max_zeroout_kb
 fi
 
 $here/src/seek_sanity_test -s 18 -e 18 $BASE_TEST_FILE > $seqres.full 2>&1 ||
-- 
1.8.3.1




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

end of thread, other threads:[~2017-07-24 10:44 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-07-18  8:27 [PATCH] generic/448: don't disable extent zeroing if extent_max_zeroout_kb isn't supported Xiao Yang
2017-07-18 13:18 ` Eryu Guan
2017-07-19  2:35   ` Xiao Yang
2017-07-19  9:56     ` Eryu Guan
2017-07-19 10:38       ` Xiao Yang
2017-07-21  7:07         ` Eryu Guan
2017-07-24  9:49           ` [PATCH] common/rc: factor out _ext4_disable_extent_zeroout() helper Xiao Yang
2017-07-24 10:04             ` Eryu Guan
2017-07-24 10:33               ` Xiao Yang
2017-07-24 10:44               ` [PATCH v2] " Xiao Yang
2017-07-19  3:06   ` [PATCH] common/rc: update _require_seek_data_hole() Xiao Yang
2017-07-24  7:13   ` [PATCH] generic/448: don't disable extent zeroing if extent_max_zeroout_kb isn't supported Xiao Yang

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.