On 06/24/14 at 12:40am, Thomas Graf wrote:
> On 06/23/14 at 12:37pm, Alex Wang wrote:
> > +/* Returns the number of cpu cores. */
> > +uint32_t
> > +ovs_numa_get_n_cores(void)
> > +{
> > +    return hmap_count(&all_cpu_cores);
> > +}
> > +
> > +/* Searches through all cores for an unpinned core.  Returns the core_id
> > + * if found and set the 'core->pinned' to true.  Otherwise, returns -1. */
> > +int
> > +ovs_numa_get_unpinned_core_any(void)
> 
> How about defining this as uint32_t to be consistent ...

On second thought, seeing how DPDK uses plain int everywhere I
suggest to standardize on that and use INT_MAX. I'd still suggest
to use a define instead of a hardcoded (-1) though.
_______________________________________________
dev mailing list
dev@openvswitch.org
http://openvswitch.org/mailman/listinfo/dev

Reply via email to