[LTP] [PATCH v2] move_mount03: check allow to mount beneath top mount
Wei Gao
wegao@suse.com
Thu Dec 28 03:53:31 CET 2023
Hi Petr
Very strange I have not found this email in my mutt, so I have to reply it in my outlook, sorry for inconvenience.
Regards
Gao Wei
I suppose there was no v1, right?
[GW] V1: https://patchwork.ozlabs.org/project/ltp/patch/20230913101542.18550-1-wegao@suse.com/
NOTE: you can speed up the review process, if you check list of common errors before sending patch to ML https://github.com/linux-test-project/ltp/wiki/Maintainer-Patch-Review-Checklist#how-to-find-clear-errors
[GW]: patch v2 send with following check: make check, m32, run with -i3
I see false positive from checkpatch.pl, it would be interesting to check if it can be fixed.
[GW]: v1 has no this issue, I wrongly remove some change from v1.
> +static void run(void)
> +{
> + int fda, fdb;
> +
> + SAFE_MKDIR(DIRA, 0777);
> + SAFE_MKDIR(DIRB, 0777);
> + SAFE_MOUNT("none", DIRA, "tmpfs", 0, 0);
> + SAFE_MOUNT("none", DIRB, "tmpfs", 0, 0);
> + SAFE_TOUCH(DIRA "/A", 0, NULL);
> + SAFE_TOUCH(DIRB "/B", 0, NULL);
Maybe whole code in above could be in setup() function, it can be created only once even we run test more times with -iN, right? Setup function is for test speedup (imagine somebody run test with -i10000, why to create files all the time?
[GW]: MKDIR should put into setup otherwise issue will happen, but mount & touch should keep within run function since move_mount will change mount point later and we need rebuild mount env again when it rerun.
More information about the ltp
mailing list