[ovs-dev] [PATCH 4/6] ofproto: Use OF1.4+ "importance" as part of eviction criteria.

Ben Pfaff blp at nicira.com
Fri Jul 3 00:46:07 UTC 2015


On Thu, Jul 02, 2015 at 06:19:00AM -0700, Jarno Rajahalme wrote:
> > On Jun 24, 2015, at 10:57 AM, Ben Pfaff <blp at nicira.com> wrote:
> > static bool choose_rule_to_evict(struct oftable *table, struct rule **rulep)
> >     OVS_REQUIRES(ofproto_mutex);
> > -static uint32_t rule_eviction_priority(struct ofproto *ofproto, struct rule *)
> > +static uint64_t rule_eviction_priority(struct ofproto *ofproto, struct rule *)
> >     OVS_REQUIRES(ofproto_mutex);;
> 
> Could you remove the extra semicolon here?

Thanks, fixed.

> > +AT_CHECK([head -n 1 stderr | ofctl_strip], [0],
> > +  [OFPT_ERROR: OFPFMFC_TABLE_FULL
> > +])
> > +# Now set the eviction on timeout basis.
> > +AT_CHECK(
> > +  [ovs-vsctl \
> > +     -- --id=@t0 create Flow_Table flow-limit=4 overflow-policy=evict \
> > +     -- set bridge br0 flow_tables:0=@t0 \
> > +   | ${PERL} $srcdir/uuidfilt.pl],
> > +  [0], [<0>
> > +])
> > +#Now add a new flow
> > +AT_CHECK([ovs-ofctl -O Openflow14 add-flow br0 importance=37,hard_timeout=507,priority=11,in_port=6,actions=drop])
> 
> Importance 37 is higher than the existing ones, so this would still evict based on importance rather than timeout?

I don't understand this comment, can you explain further?

> Assuming this is fixed:
> 
> Acked-by: Jarno Rajahalme <jrajahalme at nicira.com>

Thanks for the review!



More information about the dev mailing list