All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@lst.de>
To: fstests@vger.kernel.org
Cc: "Darrick J. Wong" <darrick.wong@oracle.com>
Subject: xfs/310: relax extent count check
Date: Sun, 3 Sep 2017 17:51:01 +0200	[thread overview]
Message-ID: <20170903155101.GA30258@lst.de> (raw)

If we got over the bmbt length we'll always allocate two extents,
its just that so far getbmap merged them.

Also fix/update some comments.

diff --git a/tests/xfs/310 b/tests/xfs/310
index c78f6f1..f33a15a 100755
--- a/tests/xfs/310
+++ b/tests/xfs/310
@@ -1,7 +1,7 @@
 #! /bin/bash
 # FS QA Test No. 310
 #
-# Create a file with more than 2^21 extents (the max length of a bmbt record).
+# Create a file with more than 2^21 blocks (the max length of a bmbt record).
 #
 #-----------------------------------------------------------------------
 # Copyright (c) 2016, Oracle and/or its affiliates.  All Rights Reserved.
@@ -75,8 +75,9 @@ mkdir $testdir
 blksz="$(_get_block_size $testdir)"
 $XFS_IO_PROG -f -c "falloc 0 $((nr_blks * blksz))" $testdir/file1 >> $seqres.full
 
+# make sure the allocator didn't allocate more than the needed two extents
 echo "Check extent count"
-xfs_bmap -l -p -v $testdir/file1 | grep '^[[:space:]]*1:' -q && xfs_bmap -l -p -v $testdir/file1
+xfs_bmap -l -p -v $testdir/file1 | grep '^[[:space:]]*2:' -q && xfs_bmap -l -p -v $testdir/file1
 inum=$(stat -c '%i' $testdir/file1)
 umount $SCRATCH_MNT
 

             reply	other threads:[~2017-09-03 15:51 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-09-03 15:51 Christoph Hellwig [this message]
2017-09-06  7:34 ` xfs/310: relax extent count check Eryu Guan
2017-09-14  4:09 ` Eryu Guan
2017-09-18 21:10 ` Darrick J. Wong
2017-09-18 23:39   ` Christoph Hellwig
2017-09-19  2:28 ` Darrick J. Wong
2017-09-19  2:56   ` Eryu Guan
2017-09-19  3:05   ` 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=20170903155101.GA30258@lst.de \
    --to=hch@lst.de \
    --cc=darrick.wong@oracle.com \
    --cc=fstests@vger.kernel.org \
    /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 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.