All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] btrfs: Source common/module when requiring module reload
@ 2021-07-23 18:18 Marcos Paulo de Souza
  0 siblings, 0 replies; only message in thread
From: Marcos Paulo de Souza @ 2021-07-23 18:18 UTC (permalink / raw)
  To: linux-btrfs, fstests; +Cc: dsterba, guaneryu, Marcos Paulo de Souza

Tests 163, 219, 225 and 242 require the btrfs module to be reloaded in
the middle of the test. If btrfs is compiled builtin, these tests
should be skipped, since we cannot unload it.

Today, this is what happens:

    QA output created by 242
    +./common/btrfs: line 405: _require_loadable_fs_module: command not found

Sourcing common/module in these tests fixes the issue by skipping the
test:
    btrfs/242       [not run] btrfs: must be a module.
    Ran: btrfs/242
    Not run: btrfs/242

Other tests liker btrfs/124 and btrfs/125 already source the same file
for the same reason, so follow the pattern.

Signed-off-by: Marcos Paulo de Souza <mpdesouza@suse.com>
---
 tests/btrfs/163 | 1 +
 tests/btrfs/219 | 1 +
 tests/btrfs/225 | 1 +
 tests/btrfs/242 | 1 +
 4 files changed, 4 insertions(+)

diff --git a/tests/btrfs/163 b/tests/btrfs/163
index 1dc081f1..76553831 100755
--- a/tests/btrfs/163
+++ b/tests/btrfs/163
@@ -27,6 +27,7 @@ _cleanup()
 # Import common functions.
 . ./common/filter
 . ./common/filter.btrfs
+. ./common/module
 
 # real QA test starts here
 
diff --git a/tests/btrfs/219 b/tests/btrfs/219
index 528175b8..1cd5daae 100755
--- a/tests/btrfs/219
+++ b/tests/btrfs/219
@@ -35,6 +35,7 @@ _cleanup()
 
 # Import common functions.
 . ./common/filter
+. ./common/module
 
 # real QA test starts here
 
diff --git a/tests/btrfs/225 b/tests/btrfs/225
index 408c03d2..ce1818db 100755
--- a/tests/btrfs/225
+++ b/tests/btrfs/225
@@ -25,6 +25,7 @@ _cleanup()
 
 # Import common functions.
 . ./common/filter
+. ./common/module
 
 # real QA test starts here
 
diff --git a/tests/btrfs/242 b/tests/btrfs/242
index 6ce62081..e1c102ae 100755
--- a/tests/btrfs/242
+++ b/tests/btrfs/242
@@ -13,6 +13,7 @@ _begin_fstest auto quick volume trim
 
 # Import common functions.
 . ./common/filter
+. ./common/module
 
 # real QA test starts here
 _supported_fs btrfs
-- 
2.26.2


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2021-07-23 18:17 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-23 18:18 [PATCH] btrfs: Source common/module when requiring module reload Marcos Paulo de Souza

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.