[ovs-dev] [PATCH v2 4/6] dpif: Meter framework.

Ben Pfaff blp at nicira.com
Wed Aug 13 16:25:47 UTC 2014

On Mon, Aug 11, 2014 at 02:37:45PM -0700, Jarno Rajahalme wrote:
> Add DPIF-level infrastructure for meters.  Allow meter_set to modify
> the meter configuration (e.g. set the burst size if unspecified).
> Signed-off-by: Jarno Rajahalme <jrajahalme at nicira.com>

The dpif_meter_del() convention of using stats->n_bands for both input
and output is one that I've found awkward in other contexts.  It's
easy for a careless caller to forget to initialize stats->n_bands, for
example.  I would consider passing in the maximum number of bands as a
separate parameter, because that interface is harder for the caller to
get wrong.

Other than that I'm happy with this, as long as Jesse and Pravin are
satisfied interfacewise.

More information about the dev mailing list