[dpdk-dev] [PATCH v3 2/3] malloc: allow reserving biggest element

Burakov, Anatoly anatoly.burakov at intel.com
Mon May 14 10:22:00 CEST 2018


On 10-May-18 2:57 PM, Remy Horton wrote:
> 
> On 03/05/2018 18:18, Anatoly Burakov wrote:
> [..]
>> Signed-off-by: Anatoly Burakov <anatoly.burakov at intel.com>
> 
> [..]
>> +    for (idx = 0; idx < RTE_HEAP_NUM_FREELISTS; idx++) {
>> +        for (elem = LIST_FIRST(&heap->free_head[idx]);
>> +                !!elem; elem = LIST_NEXT(elem, free_list)) {
> 
> Why the double-negation?
> 
> Otherwise, see no issues.
> 
> Acked-by: Remy Horton <remy.horton at intel.com>
> 
> 
> 

Presumably to make it a boolean value, not a pointer. This was written 
before my time, didn't change it :)

-- 
Thanks,
Anatoly


More information about the dev mailing list