[LTP] [PATCH v1 11/11] syscalls/quotactl09: Test error when quota info hidden in filesystem
xuyang2018.jy@fujitsu.com
xuyang2018.jy@fujitsu.com
Wed Oct 27 05:26:08 CEST 2021
Hi Cyril
> Hi!
> Generally looks good, same minor comments as for the rest of the
> patchset apply here as well:
>
> - for the description comment
> - no need to include "lapi/quotactl.h"
> - there are some trailing whitespaces (have you run make check before submitting?)
Sorry, I forgot to run.
> - does geteuid() in setup return anything else than 0?
>
> Also I wonder if we should include the fmtv0 in the variant list, but as
> far as I can tell it only matters for the tests that attempt to set the
> limits, right?
>
> I guess that we can define the test variants as:
>
> static struct quotactl_variant {
> int use_fd;
> int32_t fmt_id;
> const char *fmt_name;
> } variants[] = {
> {.use_fd = 0, .fmt_id = QFMT_VFS_V1, .fmt_name = "fmtv1"},
> {.use_fd = 1, .fmt_id = QFMT_VFS_V1, .fmt_name = "fmtv1"},
> {.use_fd = 0, .fmt_id = QFMT_VFS_V0, .fmt_name = "fmtv0"},
> {.use_fd = 1, .fmt_id = QFMT_VFS_V0, .fmt_name = "fmtv0"},
> };
>
> And then set .variants = 2 for all the tests that does not touch the
> limits and for these tests that manipulate the limits set .variants = 4
At the begining, I also have same idea. But quota info hidden in
filesystem doesn't use quotacheck cmd and also doesn't use vfsv0
foramt. Also quotactl_fd is also hidden in filesystem, so it only use
QFMT_VFS_V1 format.
I perfer to make this patchset by the following idea
1)if quota info is visable, then test vfsv1 and vfsv0 two variants
2)if quota info is hidden in filesystem, then it only support vfsv1,
so test use_fd and not_use_fd variants.
Best Regards
Yang Xu
>
More information about the ltp
mailing list