>> -                       /** The number of packets that the pool must provide
>> -                           that are packet length 'len' bytes or smaller.
>> -                           The maximum value is defined by pool capability
>> -                           pkt.max_num. */
>> +                       /** The exact number of 'len' byte packets that the 
>> pool
>> +                           must provide. The maximum value is defined by 
>> pool
>> +                           capability pkt.max_num. Pool is empty after
>> +                           allocating all the 'len' byte packets. Pool 
>> capacity
>> +                           for other packet lengths may vary. See
>> +                           odp_pool_info_t for details. */
>>                        uint32_t num;
> 
> This documentation says that the pool must be empty after allocating
> "num" packets of size "len" but in reality it is possible that
> implementation might do some round-off on the pool allocation for
> better optimisation and hence there could be some minor additional
> packets which might be available in the pool.

This same issue is also in the old spec version ("The number of packets
that the pool must provide that are packet length 'len' bytes or smaller"),
just not as clearly defined. We'll start updating the patch tomorrow and
take this problem into consideration (as well as other issues presented in
the earlier conversations).

>> 
>> +               /** Maximum number of packets of any length */
>> +               uint32_t max_num;
>> +
>> +               /** Maximum number of minimum length packets */
>> +               uint32_t num_min_len;
> 
> What is the difference between "num_min_len" and "max_num" both might
> be the same since the maximum of any length packet will usually be the
> number of packets of minimum length?

In most cases max_num == num_min_len. However, in sub-pool implementations
this may not be always true.

-Matias

Reply via email to