]> www.infradead.org Git - users/hch/xfstests-dev.git/commitdiff
common: move _filter_xfs_dmesg() to common/filter
authorIlya Dryomov <idryomov@gmail.com>
Thu, 12 Oct 2017 14:54:02 +0000 (16:54 +0200)
committerEryu Guan <eguan@redhat.com>
Thu, 12 Oct 2017 16:02:18 +0000 (00:02 +0800)
Move this XFS-specific _filter_xfs_dmesg() to common/filter so all
tests could use it. It will be renamed & made more generic and used
by more tests in later patches.

[eguan: add commit log]

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Reviewed-by: Eryu Guan <eguan@redhat.com>
Signed-off-by: Eryu Guan <eguan@redhat.com>
common/filter
common/xfs

index 39ea140cb60fabc36f22299893282023ab435f81..441ee1a6e490d708076db3e24f5f3eda417e2889 100644 (file)
@@ -448,5 +448,28 @@ _filter_filefrag()
              $flags, "\n"'
 }
 
+# xfs generates WARNINGs on purpose when applications mix buffered/mmap IO with
+# direct IO on the same file. This is a helper for _check_dmesg() to filter out
+# such warnings.
+_filter_xfs_dmesg()
+{
+       local warn1="WARNING:.*fs/xfs/xfs_file\.c:.*xfs_file_dio_aio_write.*"
+       local warn2="WARNING:.*fs/xfs/xfs_file\.c:.*xfs_file_dio_aio_read.*"
+       local warn3="WARNING:.*fs/xfs/xfs_file\.c:.*xfs_file_read_iter.*"
+       local warn4="WARNING:.*fs/xfs/xfs_file\.c:.*xfs_file_aio_read.*"
+       local warn5="WARNING:.*fs/iomap\.c:.*iomap_dio_rw.*"
+       local warn6="WARNING:.*fs/xfs/xfs_aops\.c:.*__xfs_get_blocks.*"
+       local warn7="WARNING:.*fs/iomap\.c:.*iomap_dio_actor.*"
+       local warn8="WARNING:.*fs/iomap\.c:.*iomap_dio_complete.*"
+       sed -e "s#$warn1#Intentional warnings in xfs_file_dio_aio_write#" \
+           -e "s#$warn2#Intentional warnings in xfs_file_dio_aio_read#" \
+           -e "s#$warn3#Intentional warnings in xfs_file_read_iter#" \
+           -e "s#$warn4#Intentional warnings in xfs_file_aio_read#" \
+           -e "s#$warn5#Intentional warnings in iomap_dio_rw#" \
+           -e "s#$warn6#Intentional warnings in __xfs_get_blocks#" \
+           -e "s#$warn7#Intentional warnings in iomap_dio_actor#" \
+           -e "s#$warn8#Intentional warnings in iomap_dio_complete#"
+}
+
 # make sure this script returns success
 /bin/true
index 93eb50394984cb09d31151d80b10de7fc54f878d..d4fef941d3213f255673645e8c3588b44031ba60 100644 (file)
@@ -599,25 +599,3 @@ _require_no_xfs_debug()
                _notrun "Require XFS built without CONFIG_XFS_DEBUG"
        fi
 }
-# xfs generates WARNINGs on purpose when applications mix buffered/mmap IO with
-# direct IO on the same file. This is a helper for _check_dmesg() to filter out
-# such warnings.
-_filter_xfs_dmesg()
-{
-       local warn1="WARNING:.*fs/xfs/xfs_file\.c:.*xfs_file_dio_aio_write.*"
-       local warn2="WARNING:.*fs/xfs/xfs_file\.c:.*xfs_file_dio_aio_read.*"
-       local warn3="WARNING:.*fs/xfs/xfs_file\.c:.*xfs_file_read_iter.*"
-       local warn4="WARNING:.*fs/xfs/xfs_file\.c:.*xfs_file_aio_read.*"
-       local warn5="WARNING:.*fs/iomap\.c:.*iomap_dio_rw.*"
-       local warn6="WARNING:.*fs/xfs/xfs_aops\.c:.*__xfs_get_blocks.*"
-       local warn7="WARNING:.*fs/iomap\.c:.*iomap_dio_actor.*"
-       local warn8="WARNING:.*fs/iomap\.c:.*iomap_dio_complete.*"
-       sed -e "s#$warn1#Intentional warnings in xfs_file_dio_aio_write#" \
-           -e "s#$warn2#Intentional warnings in xfs_file_dio_aio_read#" \
-           -e "s#$warn3#Intentional warnings in xfs_file_read_iter#" \
-           -e "s#$warn4#Intentional warnings in xfs_file_aio_read#" \
-           -e "s#$warn5#Intentional warnings in iomap_dio_rw#" \
-           -e "s#$warn6#Intentional warnings in __xfs_get_blocks#" \
-           -e "s#$warn7#Intentional warnings in iomap_dio_actor#" \
-           -e "s#$warn8#Intentional warnings in iomap_dio_complete#"
-}