Re: [LTP] [PATCH v1] tst_cgroup.c: Force tst_cg_scan only scan specific cgroup version if needs_ver exist

Cyril Hrubis
2024-11-08T09:53:30Z

Hi!
> tst_cgroup.c will scan cgroup mount point and check system's cgroup support status, both
> cgroupv1 and cgroupv2, if your case only need check cgroupv1(such as needs_cgroup_ver = TST_CG_V1)
> but your system contain cgroupv2 mount point, then TCONF will happen tell you your system already
> mount cgroupv2, so test case will be skipped.

I do not get what happens here. What is the exact test output that does
not work for you?

We have tst_cg_require() which attempts to mount either v1 or v2 as
described in options. However a controller can be mouted either in v1 or
v2 but not in both, so skipping the scan will not solve anything.