[LTP] [RFC PATCH 0/5] CGroups

Li Wang liwang@redhat.com
Mon Jan 4 11:00:31 CET 2021


Richard Palethorpe <rpalethorpe@suse.de> wrote:


> >> I have done a direct conversion of the test cases to the new API, but
> >> I am not sure that it makes sense to call tst_cgroup_move_current
> >> within the run method of a test because after the first iteration it
> >>
> >
> > Hmm, I feel that is a rare scenario in our real test. Mostly we
> > just need to set it once in a process.
>
> I suppose we can just move it into setup then?
>

For tests that only need a one-time CGroup setting we can, but for
multiple requirements of the same controller in many processes it
seems not working.



> > That's true, but it is mainly caused by different versions of
> > CGroup. We could NOT unify the unsupported behavior, so
> > maybe the wiser choice is to let _CPUSET test skipping(TCONF)
> > directly on CGroup_V2?
>
> Yes. I wonder if tst_cgroup_move_current should return a value to
> indicate it was a NOP? Or maybe it should throw an error when called on
> CGroup_V2 and it would have been a NOP?
>

That sound like we have to handle the returned value/error additionally?
If so, I'd prefer to encapsulate that in CGroup-lib.

-- 
Regards,
Li Wang
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linux.it/pipermail/ltp/attachments/20210104/624a097e/attachment.htm>


More information about the ltp mailing list