xfs
[Top] [All Lists]

[PATCH 1/4] xfstests: Fix a problem where using bsize was not working as

To: xfs@xxxxxxxxxxx
Subject: [PATCH 1/4] xfstests: Fix a problem where using bsize was not working as expected
From: Chandra Seetharaman <sekharan@xxxxxxxxxx>
Date: Tue, 21 Feb 2012 10:58:39 -0600
Cc: Chandra Seetharaman <sekharan@xxxxxxxxxx>
In-reply-to: <20120221165833.23253.38042.sendpatchset@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>
References: <20120221165833.23253.38042.sendpatchset@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>
>From d60824ddc4a60c7902a53fded6773b3385180cc6 Mon Sep 17 00:00:00 2001
From: Chandra Seetharaman <sekharan@xxxxxxxxxx>
Date: Wed, 8 Feb 2012 10:02:37 -0600
Subject: [PATCH 1/3] Fix a problem wherein the bsize argument setting to mkfs 
fails to be
 included since MKFS_OPTIONS already has bsize.

Signed-off-by: Chandra Seetharaman <sekharan@xxxxxxxxxx>
---
 common.rc |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/common.rc b/common.rc
index cab0b64..61889b0 100644
--- a/common.rc
+++ b/common.rc
@@ -350,7 +350,10 @@ _scratch_mkfs_sized()
 
     case $FSTYP in
     xfs)
-       _scratch_mkfs_xfs -d size=$fssize -b size=$blocksize
+       # replace bsize= in MKFS_OPTIONS if already defined
+       export MKFS_OPTIONS=$(echo $MKFS_OPTIONS | \
+                        sed -e "s/-bsize=[0-9]*/-bsize=$blocksize/")
+       _scratch_mkfs_xfs "-d size=$fssize"
        ;;
     ext2|ext3|ext4|ext4dev)
        /sbin/mkfs.$FSTYP $MKFS_OPTIONS -b $blocksize $SCRATCH_DEV $blocks
-- 
1.7.1

<Prev in Thread] Current Thread [Next in Thread>