public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Peng Haitao <penght@cn.fujitsu.com>
To: hch@infradead.org
Cc: linux-xfs@oss.sgi.com
Subject: [PATCH] xfstests/071 FAIL with pwrite64: Invalid argument
Date: Tue, 06 Dec 2011 11:42:14 +0800	[thread overview]
Message-ID: <4EDD8F16.4050402@cn.fujitsu.com> (raw)


When offset + length is overflow of xfs_io builtin pread and pwrite in linux,
the error message should be "Invalid argument".

Signed-off-by: Peng Haitao <penght@cn.fujitsu.com>
---
 071           |    3 +
 071.out       |  107 ----------------------------------------------------
 071.out.irix  |  107 ++++++++++++++++++++++++++++++++++++++++++++++++++++
 071.out.linux |  117 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 4 files changed, 227 insertions(+), 107 deletions(-)
 delete mode 100644 071.out
 create mode 100644 071.out.irix
 create mode 100644 071.out.linux

diff --git a/071 b/071
index be9b11b..0693bd7 100755
--- a/071
+++ b/071
@@ -91,6 +91,9 @@ _scratch_mkfs_xfs | _filter_mkfs 2>$tmp.mkfs
 echo
 _scratch_mount
 
+# link correct .out file
+_link_out_file $seq.out
+
 # Okay... filesize limit depends on blocksize, bits per long and
 # also if large block device patch is enabled (can't dynamically
 # check that, so use env var USE_LBD_PATCH to override default).
diff --git a/071.out b/071.out
deleted file mode 100644
index 2ea0ef0..0000000
--- a/071.out
+++ /dev/null
@@ -1,107 +0,0 @@
-QA output created by 071
-meta-data=DDEV isize=XXX agcount=N, agsize=XXX blks
-data     = bsize=XXX blocks=XXX, imaxpct=PCT
-         = sunit=XXX swidth=XXX, unwritten=X
-naming   =VERN bsize=XXX
-log      =LDEV bsize=XXX blocks=XXX
-realtime =RDEV extsz=XXX blocks=XXX, rtextents=XXX
-
-Writing 512 bytes, offset is +0 (direct=false)
-wrote 512/512 bytes at offset <OFFSET>
-Reading 512 bytes (direct=false)
-read 512/512 bytes at offset <OFFSET>
-
-Writing 512 bytes, offset is minus 1 byte (direct=false)
-wrote 512/512 bytes at offset <OFFSET>
-Reading 512 bytes (direct=false)
-read 512/512 bytes at offset <OFFSET>
-
-Writing 512 bytes, offset is minus 1FSB (direct=false)
-wrote 512/512 bytes at offset <OFFSET>
-Reading 512 bytes (direct=false)
-read 512/512 bytes at offset <OFFSET>
-
-Writing 1 bytes, offset is minus 1FSB (direct=false)
-wrote 512/512 bytes at offset <OFFSET>
-Reading 1 bytes (direct=false)
-read 1/1 bytes at offset <OFFSET>
-
-Writing 1FSB bytes, offset is +0 (direct=true)
-wrote 512/512 bytes at offset <OFFSET>
-Reading 1FSB bytes (direct=true)
-read 512/1FSB bytes at offset <OFFSET>
-
-Writing 1FSB bytes, offset is minus 1FSB (direct=true)
-wrote 512/512 bytes at offset <OFFSET>
-Reading 1FSB bytes (direct=true)
-read 513/1FSB bytes at offset <OFFSET>
-
-=== Iterating, 2 remains
-
-
-Writing 512 bytes, offset is +0 (direct=false)
-pwrite64: File too large
-Reading 512 bytes (direct=false)
-read 0/512 bytes at offset <OFFSET>
-
-Writing 512 bytes, offset is minus 1 byte (direct=false)
-pwrite64: File too large
-Reading 512 bytes (direct=false)
-read 0/512 bytes at offset <OFFSET>
-
-Writing 512 bytes, offset is minus 1FSB (direct=false)
-wrote 512/512 bytes at offset <OFFSET>
-Reading 512 bytes (direct=false)
-read 512/512 bytes at offset <OFFSET>
-
-Writing 1 bytes, offset is minus 1FSB (direct=false)
-wrote 512/512 bytes at offset <OFFSET>
-Reading 1 bytes (direct=false)
-read 1/1 bytes at offset <OFFSET>
-
-Writing 1FSB bytes, offset is +0 (direct=true)
-pwrite64: File too large
-Reading 1FSB bytes (direct=true)
-read 0/1FSB bytes at offset <OFFSET>
-
-Writing 1FSB bytes, offset is minus 1FSB (direct=true)
-pwrite64: File too large
-Reading 1FSB bytes (direct=true)
-read 0/1FSB bytes at offset <OFFSET>
-
-=== Iterating, 1 remains
-
-
-Writing 512 bytes, offset is +0 (direct=false)
-pwrite64: File too large
-Reading 512 bytes (direct=false)
-read 0/512 bytes at offset <OFFSET>
-
-Writing 512 bytes, offset is minus 1 byte (direct=false)
-pwrite64: File too large
-Reading 512 bytes (direct=false)
-read 0/512 bytes at offset <OFFSET>
-
-Writing 512 bytes, offset is minus 1FSB (direct=false)
-pwrite64: File too large
-Reading 512 bytes (direct=false)
-read 0/512 bytes at offset <OFFSET>
-
-Writing 1 bytes, offset is minus 1FSB (direct=false)
-pwrite64: File too large
-Reading 1 bytes (direct=false)
-read 0/1 bytes at offset <OFFSET>
-
-Writing 1FSB bytes, offset is +0 (direct=true)
-pwrite64: File too large
-Reading 1FSB bytes (direct=true)
-read 0/1FSB bytes at offset <OFFSET>
-
-Writing 1FSB bytes, offset is minus 1FSB (direct=true)
-pwrite64: File too large
-Reading 1FSB bytes (direct=true)
-read 0/1FSB bytes at offset <OFFSET>
-
-=== Iterating, 0 remains
-
-
diff --git a/071.out.irix b/071.out.irix
new file mode 100644
index 0000000..2ea0ef0
--- /dev/null
+++ b/071.out.irix
@@ -0,0 +1,107 @@
+QA output created by 071
+meta-data=DDEV isize=XXX agcount=N, agsize=XXX blks
+data     = bsize=XXX blocks=XXX, imaxpct=PCT
+         = sunit=XXX swidth=XXX, unwritten=X
+naming   =VERN bsize=XXX
+log      =LDEV bsize=XXX blocks=XXX
+realtime =RDEV extsz=XXX blocks=XXX, rtextents=XXX
+
+Writing 512 bytes, offset is +0 (direct=false)
+wrote 512/512 bytes at offset <OFFSET>
+Reading 512 bytes (direct=false)
+read 512/512 bytes at offset <OFFSET>
+
+Writing 512 bytes, offset is minus 1 byte (direct=false)
+wrote 512/512 bytes at offset <OFFSET>
+Reading 512 bytes (direct=false)
+read 512/512 bytes at offset <OFFSET>
+
+Writing 512 bytes, offset is minus 1FSB (direct=false)
+wrote 512/512 bytes at offset <OFFSET>
+Reading 512 bytes (direct=false)
+read 512/512 bytes at offset <OFFSET>
+
+Writing 1 bytes, offset is minus 1FSB (direct=false)
+wrote 512/512 bytes at offset <OFFSET>
+Reading 1 bytes (direct=false)
+read 1/1 bytes at offset <OFFSET>
+
+Writing 1FSB bytes, offset is +0 (direct=true)
+wrote 512/512 bytes at offset <OFFSET>
+Reading 1FSB bytes (direct=true)
+read 512/1FSB bytes at offset <OFFSET>
+
+Writing 1FSB bytes, offset is minus 1FSB (direct=true)
+wrote 512/512 bytes at offset <OFFSET>
+Reading 1FSB bytes (direct=true)
+read 513/1FSB bytes at offset <OFFSET>
+
+=== Iterating, 2 remains
+
+
+Writing 512 bytes, offset is +0 (direct=false)
+pwrite64: File too large
+Reading 512 bytes (direct=false)
+read 0/512 bytes at offset <OFFSET>
+
+Writing 512 bytes, offset is minus 1 byte (direct=false)
+pwrite64: File too large
+Reading 512 bytes (direct=false)
+read 0/512 bytes at offset <OFFSET>
+
+Writing 512 bytes, offset is minus 1FSB (direct=false)
+wrote 512/512 bytes at offset <OFFSET>
+Reading 512 bytes (direct=false)
+read 512/512 bytes at offset <OFFSET>
+
+Writing 1 bytes, offset is minus 1FSB (direct=false)
+wrote 512/512 bytes at offset <OFFSET>
+Reading 1 bytes (direct=false)
+read 1/1 bytes at offset <OFFSET>
+
+Writing 1FSB bytes, offset is +0 (direct=true)
+pwrite64: File too large
+Reading 1FSB bytes (direct=true)
+read 0/1FSB bytes at offset <OFFSET>
+
+Writing 1FSB bytes, offset is minus 1FSB (direct=true)
+pwrite64: File too large
+Reading 1FSB bytes (direct=true)
+read 0/1FSB bytes at offset <OFFSET>
+
+=== Iterating, 1 remains
+
+
+Writing 512 bytes, offset is +0 (direct=false)
+pwrite64: File too large
+Reading 512 bytes (direct=false)
+read 0/512 bytes at offset <OFFSET>
+
+Writing 512 bytes, offset is minus 1 byte (direct=false)
+pwrite64: File too large
+Reading 512 bytes (direct=false)
+read 0/512 bytes at offset <OFFSET>
+
+Writing 512 bytes, offset is minus 1FSB (direct=false)
+pwrite64: File too large
+Reading 512 bytes (direct=false)
+read 0/512 bytes at offset <OFFSET>
+
+Writing 1 bytes, offset is minus 1FSB (direct=false)
+pwrite64: File too large
+Reading 1 bytes (direct=false)
+read 0/1 bytes at offset <OFFSET>
+
+Writing 1FSB bytes, offset is +0 (direct=true)
+pwrite64: File too large
+Reading 1FSB bytes (direct=true)
+read 0/1FSB bytes at offset <OFFSET>
+
+Writing 1FSB bytes, offset is minus 1FSB (direct=true)
+pwrite64: File too large
+Reading 1FSB bytes (direct=true)
+read 0/1FSB bytes at offset <OFFSET>
+
+=== Iterating, 0 remains
+
+
diff --git a/071.out.linux b/071.out.linux
new file mode 100644
index 0000000..56a7b47
--- /dev/null
+++ b/071.out.linux
@@ -0,0 +1,117 @@
+QA output created by 071
+meta-data=DDEV isize=XXX agcount=N, agsize=XXX blks
+data     = bsize=XXX blocks=XXX, imaxpct=PCT
+         = sunit=XXX swidth=XXX, unwritten=X
+naming   =VERN bsize=XXX
+log      =LDEV bsize=XXX blocks=XXX
+realtime =RDEV extsz=XXX blocks=XXX, rtextents=XXX
+
+Writing 512 bytes, offset is +0 (direct=false)
+wrote 512/512 bytes at offset <OFFSET>
+Reading 512 bytes (direct=false)
+read 512/512 bytes at offset <OFFSET>
+
+Writing 512 bytes, offset is minus 1 byte (direct=false)
+wrote 512/512 bytes at offset <OFFSET>
+Reading 512 bytes (direct=false)
+read 512/512 bytes at offset <OFFSET>
+
+Writing 512 bytes, offset is minus 1FSB (direct=false)
+wrote 512/512 bytes at offset <OFFSET>
+Reading 512 bytes (direct=false)
+read 512/512 bytes at offset <OFFSET>
+
+Writing 1 bytes, offset is minus 1FSB (direct=false)
+wrote 512/512 bytes at offset <OFFSET>
+Reading 1 bytes (direct=false)
+read 1/1 bytes at offset <OFFSET>
+
+Writing 1FSB bytes, offset is +0 (direct=true)
+wrote 512/512 bytes at offset <OFFSET>
+Reading 1FSB bytes (direct=true)
+read 512/1FSB bytes at offset <OFFSET>
+
+Writing 1FSB bytes, offset is minus 1FSB (direct=true)
+wrote 512/512 bytes at offset <OFFSET>
+Reading 1FSB bytes (direct=true)
+read 513/1FSB bytes at offset <OFFSET>
+
+=== Iterating, 2 remains
+
+
+Writing 512 bytes, offset is +0 (direct=false)
+pwrite64: Invalid argument
+Reading 512 bytes (direct=false)
+pread64: Invalid argument
+pread64: Invalid argument
+
+Writing 512 bytes, offset is minus 1 byte (direct=false)
+pwrite64: Invalid argument
+Reading 512 bytes (direct=false)
+pread64: Invalid argument
+pread64: Invalid argument
+
+Writing 512 bytes, offset is minus 1FSB (direct=false)
+wrote 512/512 bytes at offset <OFFSET>
+Reading 512 bytes (direct=false)
+read 512/512 bytes at offset <OFFSET>
+
+Writing 1 bytes, offset is minus 1FSB (direct=false)
+wrote 512/512 bytes at offset <OFFSET>
+Reading 1 bytes (direct=false)
+read 1/1 bytes at offset <OFFSET>
+
+Writing 1FSB bytes, offset is +0 (direct=true)
+pwrite64: Invalid argument
+Reading 1FSB bytes (direct=true)
+pread64: Invalid argument
+pread64: Invalid argument
+
+Writing 1FSB bytes, offset is minus 1FSB (direct=true)
+pwrite64: Invalid argument
+Reading 1FSB bytes (direct=true)
+pread64: Invalid argument
+pread64: Invalid argument
+
+=== Iterating, 1 remains
+
+
+Writing 512 bytes, offset is +0 (direct=false)
+pwrite64: Invalid argument
+Reading 512 bytes (direct=false)
+pread64: Invalid argument
+pread64: Invalid argument
+
+Writing 512 bytes, offset is minus 1 byte (direct=false)
+pwrite64: Invalid argument
+Reading 512 bytes (direct=false)
+pread64: Invalid argument
+pread64: Invalid argument
+
+Writing 512 bytes, offset is minus 1FSB (direct=false)
+pwrite64: Invalid argument
+Reading 512 bytes (direct=false)
+pread64: Invalid argument
+pread64: Invalid argument
+
+Writing 1 bytes, offset is minus 1FSB (direct=false)
+pwrite64: Invalid argument
+Reading 1 bytes (direct=false)
+pread64: Invalid argument
+pread64: Invalid argument
+
+Writing 1FSB bytes, offset is +0 (direct=true)
+pwrite64: Invalid argument
+Reading 1FSB bytes (direct=true)
+pread64: Invalid argument
+pread64: Invalid argument
+
+Writing 1FSB bytes, offset is minus 1FSB (direct=true)
+pwrite64: Invalid argument
+Reading 1FSB bytes (direct=true)
+pread64: Invalid argument
+pread64: Invalid argument
+
+=== Iterating, 0 remains
+
+
-- 
1.7.1

-- 
Best Regards,
Peng Haitao

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

             reply	other threads:[~2011-12-06  3:41 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-06  3:42 Peng Haitao [this message]
2011-12-06 11:05 ` [PATCH] xfstests/071 FAIL with pwrite64: Invalid argument Dave Chinner
2011-12-06 11:23   ` Christoph Hellwig
2011-12-07  8:17   ` Peng Haitao
2011-12-07 10:07     ` Dave Chinner
2011-12-08  2:25       ` Peng Haitao
2012-01-04 16:53         ` Christoph Hellwig
2012-01-06  3:53           ` Peng Haitao
2012-03-15  2:25           ` [PATCH v2] " Peng Haitao
2012-03-31 20:13             ` [PATCH v2] 071: make this test work as expected on Linux Christoph Hellwig

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4EDD8F16.4050402@cn.fujitsu.com \
    --to=penght@cn.fujitsu.com \
    --cc=hch@infradead.org \
    --cc=linux-xfs@oss.sgi.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox