FS/XFS testing framework
 help / color / mirror / Atom feed
From: Dave Chinner <david@fromorbit.com>
To: Theodore Ts'o <tytso@mit.edu>
Cc: Dmitry Monakhov <dmonakhov@openvz.org>, fstests@vger.kernel.org
Subject: Re: [PATCH 2/6] common: _scratch_mkfs_sized should inherent default block size from test_dev
Date: Sat, 23 Aug 2014 10:31:33 +1000	[thread overview]
Message-ID: <20140823003133.GS26465@dastard> (raw)
In-Reply-To: <20140822163712.GP11085@thunk.org>

On Fri, Aug 22, 2014 at 12:37:12PM -0400, Theodore Ts'o wrote:
> On Fri, Aug 22, 2014 at 07:48:07PM +0400, Dmitry Monakhov wrote:
> > No, This will not works. Looks like you have missed the point.
> > helper has following signature:
> > _scratch_mkfs_sized <size in bytes> [optional blocksize]
> > But mke2fs accept filesystem size accounted in fs-blocks, so in order
> > to convert size in blocks to number of blocks we have to figure out blocksize.
> 
> Ah, sorry.  I didn't understand what problem you were trying to solve.
> 
> But mke2fs does accept the filesystem size accounted in kilobytes (and
> megabytes, gigabytes, etc.).  So you could just take the size in
> bytes, divide by 1024, and then append 'k', i.e:
> 
>        mke2fs $MKFS_OPTS $DEVICE $(expr $bytes / 1024)k

Not according to the man page:

	blocks-count is the number of blocks on the device.

Perhaps the documentation needs to be updated to match reality?

Cheers,

Dave.
-- 
Dave Chinner
david@fromorbit.com

  reply	other threads:[~2014-08-23  0:32 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-16 13:13 [PATCH 1/6] common: add _mkfs_dev helper Dmitry Monakhov
2014-08-16 13:13 ` [PATCH 2/6] common: _scratch_mkfs_sized should inherent default block size from test_dev Dmitry Monakhov
2014-08-20 23:14   ` Dave Chinner
2014-08-21  7:36     ` Dmitry Monakhov
2014-08-21  9:23       ` Dave Chinner
2014-08-21 14:01         ` Theodore Ts'o
2014-08-21 20:44           ` Dave Chinner
2014-08-22 13:24         ` Dmitry Monakhov
2014-08-22 15:09           ` Theodore Ts'o
2014-08-22 15:48             ` Dmitry Monakhov
2014-08-22 16:37               ` Theodore Ts'o
2014-08-23  0:31                 ` Dave Chinner [this message]
2014-08-16 13:13 ` [PATCH 3/6] src/e4compact cleanup Dmitry Monakhov
2014-08-16 13:13 ` [PATCH 4/6] src/e4compact: handle various block_size correctly Dmitry Monakhov
2014-08-16 13:13 ` [PATCH 5/6] src/e4compact: add sparse file optimization Dmitry Monakhov
2014-08-16 13:13 ` [PATCH 6/6] ext4/308: add new defrag compact test case Dmitry Monakhov
2014-09-08 12:21   ` Dave Chinner

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=20140823003133.GS26465@dastard \
    --to=david@fromorbit.com \
    --cc=dmonakhov@openvz.org \
    --cc=fstests@vger.kernel.org \
    --cc=tytso@mit.edu \
    /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