ACK/cmnt: [X/Z/A][PATCH 0/5] fix memory-hotplug test

Kleber Souza kleber.souza at canonical.com
Tue Aug 15 14:27:37 UTC 2017


On 08/15/17 13:58, Po-Hsu Lin (Sam) wrote:
> BugLink: https://bugs.launchpad.net/bugs/1710868
> 
> SRU Justification:
> 
> Impact:
> The memory-hotplug test in the kernel tree needs to be fixed:
> 1. The test will pass even the memory blocks are failed to be offlined.
> 2. It's using a random number generator to decide if each memory block
> needs to be offlined, which is not ideal for testing as the block it
> tries to unplug might be different between two runs.
> 3. The "-r" flag, percent-of-memory-to-offline, does not match what is
> says. It's being used as the percentage to get a memory block offlined
> instead.
> 
> Fix:
> Apply the following patch from upstream can fix these issues:
> 593f9278 - selftests: typo correction for memory-hotplug test
> a34b28c9 - selftests: check hot-pluggagble memory for memory-hotplug test
> 72441ea5 - selftests: check percentage range for memory-hotplug test
> 02d8f075 - selftests: add missing test name in memory-hotplug test
> 5ff0c60b - selftests: fix memory-hotplug test
> 
> Testcase:
> Run the script directly, it will fail when all memory blocks are busy.
> And it will try to unplug memory blocks in a fixed order.
> 
> Regression Potential:
> Negligible, it's just affecting this specific test case among those
> testing tools.
> 
> On Thu, Aug 10, 2017 at 2:32 PM, Po-Hsu Lin <po-hsu.lin at canonical.com> wrote:
>> The memory-hotplug test in the kernel selftest directory has a flag which is
>> called "percent-of-memory-to-offline". However it is using a random number
>> to decide if each memory block needs to be offlined (with 10% chance).
>> This might cause all memory blocks being skipped, or throw an error if the
>> block is busy. Also, it does not match with the meaning of the flag.
>>
>> This patch set will fix the test by offlining a certain amount of memory blocks
>> and it will try to offline them one-by-one instead of doing this randomly to
>> avoid the block is busy issue and make it more reproducible.
>>
>> Skipping Trusty as the ubuntu_kernel_selftests test suite was blacklisted on it.
>>
>> Po-Hsu Lin (5):
>>   selftests: typo correction for memory-hotplug test
>>   selftests: check hot-pluggagble memory for memory-hotplug test
>>   selftests: check percentage range for memory-hotplug test
>>   selftests: add missing test name in memory-hotplug test
>>   selftests: fix memory-hotplug test
>>
>>  .../selftests/memory-hotplug/mem-on-off-test.sh    | 86 +++++++++++++++++-----
>>  1 file changed, 67 insertions(+), 19 deletions(-)
>>
>> --
>> 2.7.4
>>
> 

Given the SRU justification, and that the patches are upstream, limited
to the selftests and will improve our test coverage.

Just a note for the person applying the patches: the BugLink needs to be
added to all patches in the series before applying them.

Acked-by: Kleber Sacilotto de Souza <kleber.souza at canonical.com>




More information about the kernel-team mailing list