public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
* [LTP] [PATCH] lib/tst_mkfs: append -f option when creating btrfs
@ 2014-02-25  4:31 Eryu Guan
  2014-02-25  5:18 ` Wanlong Gao
  0 siblings, 1 reply; 2+ messages in thread
From: Eryu Guan @ 2014-02-25  4:31 UTC (permalink / raw)
  To: ltp-list

mkfs.btrfs needs -f option to force the mkfs process too.

Signed-off-by: Eryu Guan <eguan@redhat.com>
---
 lib/tst_mkfs.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/lib/tst_mkfs.c b/lib/tst_mkfs.c
index bacf976..cee04dd 100644
--- a/lib/tst_mkfs.c
+++ b/lib/tst_mkfs.c
@@ -31,12 +31,12 @@ void tst_mkfs(void (cleanup_fn)(void), const char *dev,
 	int pos = 3;
 
 	/*
-	 * The mkfs.xfs aborts if it finds a filesystem superblock
-	 * on the device, which is the case here as we reuse one
-	 * device for all tests.
+	 * mkfs.xfs and mkfs.btrfs aborts if it finds a filesystem
+	 * superblock on the device, which is the case here as we
+	 * reuse one device for all tests.
 	 */
-	if (!strcmp(fs_type, "xfs")) {
-		tst_resm(TINFO, "Appending '-f' force flag to mkfs.xfs");
+	if (!strcmp(fs_type, "xfs") || !strcmp(fs_type, "btrfs")) {
+		tst_resm(TINFO, "Appending '-f' flag to mkfs.%s", fs_type);
 		argv[pos++] = "-f";
 	}
 
-- 
1.8.5.3


------------------------------------------------------------------------------
Flow-based real-time traffic analytics software. Cisco certified tool.
Monitor traffic, SLAs, QoS, Medianet, WAAS etc. with NetFlow Analyzer
Customize your own dashboards, set traffic alerts and generate reports.
Network behavioral analysis & security monitoring. All-in-one tool.
http://pubads.g.doubleclick.net/gampad/clk?id=126839071&iu=/4140/ostg.clktrk
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [LTP] [PATCH] lib/tst_mkfs: append -f option when creating btrfs
  2014-02-25  4:31 [LTP] [PATCH] lib/tst_mkfs: append -f option when creating btrfs Eryu Guan
@ 2014-02-25  5:18 ` Wanlong Gao
  0 siblings, 0 replies; 2+ messages in thread
From: Wanlong Gao @ 2014-02-25  5:18 UTC (permalink / raw)
  To: Eryu Guan; +Cc: ltp-list

On 02/25/2014 12:31 PM, Eryu Guan wrote:
> mkfs.btrfs needs -f option to force the mkfs process too.
> 
> Signed-off-by: Eryu Guan <eguan@redhat.com>
> ---
>  lib/tst_mkfs.c | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)

Good catch, applied, thank you.

Wanlong Gao


------------------------------------------------------------------------------
Flow-based real-time traffic analytics software. Cisco certified tool.
Monitor traffic, SLAs, QoS, Medianet, WAAS etc. with NetFlow Analyzer
Customize your own dashboards, set traffic alerts and generate reports.
Network behavioral analysis & security monitoring. All-in-one tool.
http://pubads.g.doubleclick.net/gampad/clk?id=126839071&iu=/4140/ostg.clktrk
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-02-25  5:58 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-02-25  4:31 [LTP] [PATCH] lib/tst_mkfs: append -f option when creating btrfs Eryu Guan
2014-02-25  5:18 ` Wanlong Gao

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox