Re: [LTP] [PATCH 1/2] mm/vma01: consider topdown and bottomup allocation

Wanlong Gao
2012-07-09T13:40:57Z

On 07/09/2012 08:27 PM, Caspar Zhang wrote:
> On 07/09/2012 08:06 PM, Wanlong Gao wrote:
>> On 06/25/2012 03:33 PM, Caspar Zhang wrote:
>>> + if (topdown) {
>>> + x = get_end_addr(u);
>>> + printf("child : x = %p\n", x);
>>> + if (x == t + 3*ps)
>>> + exit(1);
>>> + else if (x == t && get_end_addr(x) == t + 3*ps)
>>> + exit(0);
>>> + } else {
>>> + x = get_end_addr(t);
>>> + printf("child : x = %p\n", x);
>>> + if (x == t + 6*ps)
>>> + exit(1);
>>> + else if (x == u && get_end_addr(x) == t + 6*ps)
>>> exit(0);
>>> }
>>
>> Looks good to me.
>>
>> Reviewed-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
>>
>> But why not use tst_resm(TINFO, ) instead?
>
> This is in child process. We'd avoid potential race on libltp between child and parent. (see style-guide.txt)

OK, I see, thank you.

Wanlong Gao

>
> Caspar