[ovs-dev] [PATCH v9] ovs-ofctl:Implementation of eviction on the basis of Importance

Ben Pfaff blp at nicira.com
Fri Jun 5 17:02:20 UTC 2015


On Fri, May 29, 2015 at 04:00:27PM +0530, saloni.jain12 at gmail.com wrote:
> From: Saloni Jain <saloni.jain at tcs.com>
> 
> This commit enables the eviction mechanism on the basis of importance as
> per the openflow specification 1.4.
> 
> "ovs-ofctl -O OpenFlow14 mod-table <switch> <table> evict"
> Enable eviction on <table> of <switch>. Eviction adds a mechanism
> enabling the switch to automatically eliminate entries of lower
> importance to make space for newer entries.If want to enable eviction
> on all tables, user can set the <table> as 'ALL'.
> 
> "ovs-ofctl -O OpenFlow14 mod-table <switch> <table> noevict"
> Disable eviction on <table> of <switch>.
> 
> "ovs-ofctl -O OpenFlow14 dump-tables-desc <switch>"
> This command provides a way to list the current configuration
> (eviction for importance) of the tables on a <switch>, which is set
> using the mod-table command.
> 
> Signed-off-by: Saloni Jain <saloni.jain at tcs.com>

This adds abstracted OFPUTIL_TABLE_CONFIG_* but it doesn't do any
translation between them and OFPTC14_*.

This adds a weird CLEAR_EVICTION_BIT definition.  Use an
OFPUTIL_TABLE_CONFIG_* constant.

This leaves in the following comment that is now obsolete:
        /* We do not understand any properties yet, so we do not bother
         * parsing them. */

It appears to me that all of the OFPUTIL_TABLE_CONFIG modes are mutually
exclusive.  Why are they individual bits?  Alternatively, there is a bit
for "NO_EVICTION" and one for "EVICTION"; why both?

Why does this expression contain parentheses?
        return UINT32_MAX - (rule->importance);



More information about the dev mailing list