* [PATCH] btrfs/315: update 315.out to adapt mount cmd @ 2024-09-18 17:07 An Long 2024-09-18 17:53 ` Filipe Manana 2024-09-19 12:01 ` Zorro Lang 0 siblings, 2 replies; 6+ messages in thread From: An Long @ 2024-09-18 17:07 UTC (permalink / raw) To: fstests; +Cc: An Long Mount error info changed since util-linux v2.40 (91ea38e libmount: report failed syscall name). So add "mount" before "system call failed". Signed-off-by: An Long <lan@suse.com> --- tests/btrfs/315.out | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/btrfs/315.out b/tests/btrfs/315.out index 3ea7a35a..a19ae8d5 100644 --- a/tests/btrfs/315.out +++ b/tests/btrfs/315.out @@ -1,7 +1,7 @@ QA output created by 315 ---- seed_device_must_fail ---- mount: SCRATCH_MNT: WARNING: source write-protected, mounted read- only. -mount: TEST_DIR/315/tempfsid_mnt: system call failed: File exists. +mount: TEST_DIR/315/tempfsid_mnt: mount system call failed: File exists. ---- device_add_must_fail ---- wrote 9000/9000 bytes at offset 0 XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) -- 2.43.0 ^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] btrfs/315: update 315.out to adapt mount cmd 2024-09-18 17:07 [PATCH] btrfs/315: update 315.out to adapt mount cmd An Long @ 2024-09-18 17:53 ` Filipe Manana 2024-09-19 12:01 ` Zorro Lang 1 sibling, 0 replies; 6+ messages in thread From: Filipe Manana @ 2024-09-18 17:53 UTC (permalink / raw) To: An Long; +Cc: fstests, linux-btrfs On Wed, Sep 18, 2024 at 6:08 PM An Long <lan@suse.com> wrote: > > Mount error info changed since util-linux v2.40 > (91ea38e libmount: report failed syscall name). > So add "mount" before "system call failed". > > Signed-off-by: An Long <lan@suse.com> > --- > tests/btrfs/315.out | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/tests/btrfs/315.out b/tests/btrfs/315.out > index 3ea7a35a..a19ae8d5 100644 > --- a/tests/btrfs/315.out > +++ b/tests/btrfs/315.out > @@ -1,7 +1,7 @@ > QA output created by 315 > ---- seed_device_must_fail ---- > mount: SCRATCH_MNT: WARNING: source write-protected, mounted read- > only. > -mount: TEST_DIR/315/tempfsid_mnt: system call failed: File exists. > +mount: TEST_DIR/315/tempfsid_mnt: mount system call failed: File So this makes the test pass with util-linux v2.40+, but makes it fail with older versions. The expectation that everyone is soon upgrading to v2.40 is unrealistic and some distros, especially enterprise ones, may take a long time to upgrade. What we do in fstests is to create a filter function that converts the output, so that the test runs with any version of util-linux (or any other package). Check common/filter, namely the _filter_error_mount() function. Also, when modifying btrfs tests, please also CC linux-btrfs@vger.kernel.org. Thanks. > exists. > ---- device_add_must_fail ---- > wrote 9000/9000 bytes at offset 0 > XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) > -- > 2.43.0 > > ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] btrfs/315: update 315.out to adapt mount cmd 2024-09-18 17:07 [PATCH] btrfs/315: update 315.out to adapt mount cmd An Long 2024-09-18 17:53 ` Filipe Manana @ 2024-09-19 12:01 ` Zorro Lang 2024-09-20 10:12 ` Filipe Manana 1 sibling, 1 reply; 6+ messages in thread From: Zorro Lang @ 2024-09-19 12:01 UTC (permalink / raw) To: An Long; +Cc: fstests On Thu, Sep 19, 2024 at 01:07:53AM +0800, An Long wrote: > Mount error info changed since util-linux v2.40 > (91ea38e libmount: report failed syscall name). > So add "mount" before "system call failed". > > Signed-off-by: An Long <lan@suse.com> > --- > tests/btrfs/315.out | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/tests/btrfs/315.out b/tests/btrfs/315.out > index 3ea7a35a..a19ae8d5 100644 > --- a/tests/btrfs/315.out > +++ b/tests/btrfs/315.out > @@ -1,7 +1,7 @@ > QA output created by 315 > ---- seed_device_must_fail ---- > mount: SCRATCH_MNT: WARNING: source write-protected, mounted read- > only. > -mount: TEST_DIR/315/tempfsid_mnt: system call failed: File exists. > +mount: TEST_DIR/315/tempfsid_mnt: mount system call failed: File This change will bring failure to downstream distro. Please refer to _filter_error_mount (or other filters you like), add new filter to it to help this test passed on old and new util-linux. Thanks, Zorro > exists. > ---- device_add_must_fail ---- > wrote 9000/9000 bytes at offset 0 > XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) > -- > 2.43.0 > > ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] btrfs/315: update 315.out to adapt mount cmd 2024-09-19 12:01 ` Zorro Lang @ 2024-09-20 10:12 ` Filipe Manana 2024-09-20 14:28 ` Zorro Lang 0 siblings, 1 reply; 6+ messages in thread From: Filipe Manana @ 2024-09-20 10:12 UTC (permalink / raw) To: Zorro Lang; +Cc: An Long, fstests On Thu, Sep 19, 2024 at 1:02 PM Zorro Lang <zlang@redhat.com> wrote: > > On Thu, Sep 19, 2024 at 01:07:53AM +0800, An Long wrote: > > Mount error info changed since util-linux v2.40 > > (91ea38e libmount: report failed syscall name). > > So add "mount" before "system call failed". > > > > Signed-off-by: An Long <lan@suse.com> > > --- > > tests/btrfs/315.out | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/tests/btrfs/315.out b/tests/btrfs/315.out > > index 3ea7a35a..a19ae8d5 100644 > > --- a/tests/btrfs/315.out > > +++ b/tests/btrfs/315.out > > @@ -1,7 +1,7 @@ > > QA output created by 315 > > ---- seed_device_must_fail ---- > > mount: SCRATCH_MNT: WARNING: source write-protected, mounted read- > > only. > > -mount: TEST_DIR/315/tempfsid_mnt: system call failed: File exists. > > +mount: TEST_DIR/315/tempfsid_mnt: mount system call failed: File > > This change will bring failure to downstream distro. Please refer to > _filter_error_mount (or other filters you like), add new filter to > it to help this test passed on old and new util-linux. Isn't that what I said in my previous reply [1]? [1] https://lore.kernel.org/fstests/CAL3q7H7fzCQE0qjZEgeAJ2jvBsJxbYN-S=XpWFu5KDoaXgqsZQ@mail.gmail.com/ > > Thanks, > Zorro > > > > exists. > > ---- device_add_must_fail ---- > > wrote 9000/9000 bytes at offset 0 > > XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) > > -- > > 2.43.0 > > > > > > ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] btrfs/315: update 315.out to adapt mount cmd 2024-09-20 10:12 ` Filipe Manana @ 2024-09-20 14:28 ` Zorro Lang 2024-09-23 4:45 ` An Long 0 siblings, 1 reply; 6+ messages in thread From: Zorro Lang @ 2024-09-20 14:28 UTC (permalink / raw) To: Filipe Manana; +Cc: An Long, fstests On Fri, Sep 20, 2024 at 11:12:12AM +0100, Filipe Manana wrote: > On Thu, Sep 19, 2024 at 1:02 PM Zorro Lang <zlang@redhat.com> wrote: > > > > On Thu, Sep 19, 2024 at 01:07:53AM +0800, An Long wrote: > > > Mount error info changed since util-linux v2.40 > > > (91ea38e libmount: report failed syscall name). > > > So add "mount" before "system call failed". > > > > > > Signed-off-by: An Long <lan@suse.com> > > > --- > > > tests/btrfs/315.out | 2 +- > > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > > > diff --git a/tests/btrfs/315.out b/tests/btrfs/315.out > > > index 3ea7a35a..a19ae8d5 100644 > > > --- a/tests/btrfs/315.out > > > +++ b/tests/btrfs/315.out > > > @@ -1,7 +1,7 @@ > > > QA output created by 315 > > > ---- seed_device_must_fail ---- > > > mount: SCRATCH_MNT: WARNING: source write-protected, mounted read- > > > only. > > > -mount: TEST_DIR/315/tempfsid_mnt: system call failed: File exists. > > > +mount: TEST_DIR/315/tempfsid_mnt: mount system call failed: File > > > > This change will bring failure to downstream distro. Please refer to > > _filter_error_mount (or other filters you like), add new filter to > > it to help this test passed on old and new util-linux. > > Isn't that what I said in my previous reply [1]? > > [1] https://lore.kernel.org/fstests/CAL3q7H7fzCQE0qjZEgeAJ2jvBsJxbYN-S=XpWFu5KDoaXgqsZQ@mail.gmail.com/ Oh, sorry I replied directly due to I thought my old change when I saw this patch. commit e937e23d202173d112cfe7621d8b860f691ce42d Author: Zorro Lang <zlang@kernel.org> Date: Fri May 27 20:11:15 2022 +0800 common/filter: filter out extra mount error output Sure, you're right, thanks for reviewing :) Thanks, Zorro > > > > > Thanks, > > Zorro > > > > > > > exists. > > > ---- device_add_must_fail ---- > > > wrote 9000/9000 bytes at offset 0 > > > XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) > > > -- > > > 2.43.0 > > > > > > > > > > > ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] btrfs/315: update 315.out to adapt mount cmd 2024-09-20 14:28 ` Zorro Lang @ 2024-09-23 4:45 ` An Long 0 siblings, 0 replies; 6+ messages in thread From: An Long @ 2024-09-23 4:45 UTC (permalink / raw) To: Zorro Lang, Filipe Manana; +Cc: fstests, linux-btrfs On Fri, 2024-09-20 at 22:28 +0800, Zorro Lang wrote: > On Fri, Sep 20, 2024 at 11:12:12AM +0100, Filipe Manana wrote: > > On Thu, Sep 19, 2024 at 1:02 PM Zorro Lang <zlang@redhat.com> > > wrote: > > > > > > On Thu, Sep 19, 2024 at 01:07:53AM +0800, An Long wrote: > > > > Mount error info changed since util-linux v2.40 > > > > (91ea38e libmount: report failed syscall name). > > > > So add "mount" before "system call failed". > > > > > > > > Signed-off-by: An Long <lan@suse.com> > > > > --- > > > > tests/btrfs/315.out | 2 +- > > > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > > > > > diff --git a/tests/btrfs/315.out b/tests/btrfs/315.out > > > > index 3ea7a35a..a19ae8d5 100644 > > > > --- a/tests/btrfs/315.out > > > > +++ b/tests/btrfs/315.out > > > > @@ -1,7 +1,7 @@ > > > > QA output created by 315 > > > > ---- seed_device_must_fail ---- > > > > mount: SCRATCH_MNT: WARNING: source write-protected, mounted > > > > read- > > > > only. > > > > -mount: TEST_DIR/315/tempfsid_mnt: system call failed: File > > > > exists. > > > > +mount: TEST_DIR/315/tempfsid_mnt: mount system call failed: > > > > File > > > > > > This change will bring failure to downstream distro. Please refer > > > to > > > _filter_error_mount (or other filters you like), add new filter > > > to > > > it to help this test passed on old and new util-linux. > > > > Isn't that what I said in my previous reply [1]? > > > > [1] > > https://lore.kernel.org/fstests/CAL3q7H7fzCQE0qjZEgeAJ2jvBsJxbYN-S=XpWFu5KDoaXgqsZQ@mail.gmail.com/ > > Oh, sorry I replied directly due to I thought my old change when > I saw this patch. > > commit e937e23d202173d112cfe7621d8b860f691ce42d > Author: Zorro Lang <zlang@kernel.org> > Date: Fri May 27 20:11:15 2022 +0800 > > common/filter: filter out extra mount error output > > Sure, you're right, thanks for reviewing :) > > Thanks, > Zorro > > > > > > > > > Thanks, > > > Zorro > > > > > > > > > > exists. > > > > ---- device_add_must_fail ---- > > > > wrote 9000/9000 bytes at offset 0 > > > > XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) > > > > -- > > > > 2.43.0 > > > > > > > > > > > > > > > > > Mount error info changed since util-linux v2.40 (91ea38e libmount: report failed syscall name). So update _filter_mount_error() to match it. Signed-off-by: An Long <lan@suse.com> --- tests/btrfs/315 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/btrfs/315 b/tests/btrfs/315 index 5852afad..da5d0ce4 100755 --- a/tests/btrfs/315 +++ b/tests/btrfs/315 @@ -39,7 +39,8 @@ _filter_mount_error() # mount: <mnt-point>: fsconfig system call failed: File exists. # dmesg(1) may have more information after failed mount system call. - grep -v dmesg | _filter_test_dir | sed -e "s/mount(2)\|fsconfig//g" + grep -v dmesg | _filter_test_dir | sed -e "s/mount(2)\|fsconfig//g" | \ + sed -E "s/mount( system call failed:)/\1/" } seed_device_must_fail() -- 2.43.0 ^ permalink raw reply related [flat|nested] 6+ messages in thread
end of thread, other threads:[~2024-09-23 4:46 UTC | newest] Thread overview: 6+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2024-09-18 17:07 [PATCH] btrfs/315: update 315.out to adapt mount cmd An Long 2024-09-18 17:53 ` Filipe Manana 2024-09-19 12:01 ` Zorro Lang 2024-09-20 10:12 ` Filipe Manana 2024-09-20 14:28 ` Zorro Lang 2024-09-23 4:45 ` An Long
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox