[lkml]   [2018]   [Nov]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH v5] selftests: membarrier: re-organize test
>> Why do we need to add new routines for these conditions. Why can't handle these strings in array. For example you can define an array of strings for passed unexpectedly etc. and the pass the string to appropriate ksft_* interface instead of adding of these routines. Also it is hard to review the code this way.

I was able to fit all the logic in the 80 char limit and, still, give a
notion what was being called on each condition (instead of using an
array number or equivalent). Considering this is not the core code, and
the this has been already accepted and reviewed in LTP project, would
you mind accepting it so both can be maintained together ? It is much
better than the existing one, anyway...

Note: I have removed the part where we test for older return codes,
since kselftest is not focusing in those (but LTP does).

>> I do like the direction though. Also please run and cc everybody it suggests.

Done in v5.

Thanks a lot.

>> thanks,
>> -- Shuah

> This commit re-organizes membarrier test, solving issues when testing
> LTS kernels. Now, the code:
> - always run the same amount of tests (even on older kernels).
> - allows each test to succeed, fail or be skipped independently.
> - allows testing features even when explicitly unsupported (force=1).
> - checks false positive/negative by checking ret code and errno.
> - can be extended easily: to expand an array with commands.
> Note: like this, the test is pretty close to the LTP membarrier basic
> tests, and both can be maintained together.
> Link:
> Link:
> Signed-off-by: Rafael David Tinoco <>
> ---
Rafael D. Tinoco
Linaro Kernel Validation

 \ /
  Last update: 2018-11-18 21:45    [W:0.078 / U:51.052 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site