diff mbox series

[v3] syscalls/preadv2/preadv203: set mount_device flag

Message ID 20190605053312.17369-1-jencce.kernel@gmail.com
State Accepted
Headers show
Series [v3] syscalls/preadv2/preadv203: set mount_device flag | expand

Commit Message

Murphy Zhou June 5, 2019, 5:33 a.m. UTC
Now the tests are running in MOUNTPOINT without it mounted. Fails on
NFS, cifs, tmpfs:

    preadv203.c does not set mount_device, which makes BROK:
      preadv203.c:122: BROK: preadv2() failed: EOPNOTSUPP

Signed-off-by: Murphy Zhou <jencce.kernel@gmail.com>
---
v3:
  improve commit message
v2:
  set mount_device in preadv203.c, rather than in the library

 testcases/kernel/syscalls/preadv2/preadv203.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Xiao Yang June 5, 2019, 5:55 a.m. UTC | #1
Hi Murphy,

Pushed. Thanks for your patch. :-)

Best Regards,
Xiao Yang
On 2019/06/05 13:33, Murphy Zhou wrote:
> Now the tests are running in MOUNTPOINT without it mounted. Fails on
> NFS, cifs, tmpfs:
>
>     preadv203.c does not set mount_device, which makes BROK:
>       preadv203.c:122: BROK: preadv2() failed: EOPNOTSUPP
>
> Signed-off-by: Murphy Zhou <jencce.kernel@gmail.com>
> ---
> v3:
>   improve commit message
> v2:
>   set mount_device in preadv203.c, rather than in the library
>
>  testcases/kernel/syscalls/preadv2/preadv203.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/testcases/kernel/syscalls/preadv2/preadv203.c b/testcases/kernel/syscalls/preadv2/preadv203.c
> index 810d1e8db..e4f68a51b 100644
> --- a/testcases/kernel/syscalls/preadv2/preadv203.c
> +++ b/testcases/kernel/syscalls/preadv2/preadv203.c
> @@ -261,6 +261,7 @@ static struct tst_test test = {
>  	.cleanup = cleanup,
>  	.test_all = verify_preadv2,
>  	.mntpoint = MNTPOINT,
> +	.mount_device = 1,
>  	.all_filesystems = 1,
>  	.needs_tmpdir = 1,
>  	.needs_root = 1,
Cyril Hrubis June 5, 2019, 2:06 p.m. UTC | #2
Hi!
> diff --git a/testcases/kernel/syscalls/preadv2/preadv203.c b/testcases/kernel/syscalls/preadv2/preadv203.c
> index 810d1e8db..e4f68a51b 100644
> --- a/testcases/kernel/syscalls/preadv2/preadv203.c
> +++ b/testcases/kernel/syscalls/preadv2/preadv203.c
> @@ -261,6 +261,7 @@ static struct tst_test test = {
>  	.cleanup = cleanup,
>  	.test_all = verify_preadv2,
>  	.mntpoint = MNTPOINT,
> +	.mount_device = 1,
>  	.all_filesystems = 1,
>  	.needs_tmpdir = 1,
>  	.needs_root = 1,

What a silly mistake of mine, thanks for fixing that.

Unfortunately it seems that this breaks the test on a subset of
filesystems. For me it fails when files are written in the test setup,
guess that writing 1000 files with 66 blocks of size 4123 is about 236MB
is too much for the default 256MB loop device.

I will look into that and send a patch later on.
diff mbox series

Patch

diff --git a/testcases/kernel/syscalls/preadv2/preadv203.c b/testcases/kernel/syscalls/preadv2/preadv203.c
index 810d1e8db..e4f68a51b 100644
--- a/testcases/kernel/syscalls/preadv2/preadv203.c
+++ b/testcases/kernel/syscalls/preadv2/preadv203.c
@@ -261,6 +261,7 @@  static struct tst_test test = {
 	.cleanup = cleanup,
 	.test_all = verify_preadv2,
 	.mntpoint = MNTPOINT,
+	.mount_device = 1,
 	.all_filesystems = 1,
 	.needs_tmpdir = 1,
 	.needs_root = 1,