On Fri, Mar 31, 2017 at 01:42:02PM -0700, Andy Zhou wrote:
> Currently, meters are stored in a fixed pointer array. It is not
> very efficient since the controller, at least in theory, can
> pick any meter id (up to the limits to uint32_t), not necessarily
> within the lower end of a region, or in close range to each other.
> In particular, OFPM_SLOWPATH and OFPM_CONTROLLER meters are specified
> at the high region.
> 
> Switching to use imap, so that ofproto layer does not restrict
> the number of meters that controller can add, nor does it care
> about the value of meter_id. Only datapth actually limits the
> number of meters ofproto layer can support.
> 
> Signed-off-by: Andy Zhou <az...@ovn.org>

Instead of using a new integer-to-pointer map data structure, did you
consider adding an hmap_node to struct meter?  That's the first approach
that comes to mind, so I'm curious to know whether it's a poor approach
for some reason.
_______________________________________________
dev mailing list
d...@openvswitch.org
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to