[ovs-dev] [PATCH v4] dpif-netdev: Conditional EMC insert

Ilya Maximets i.maximets at samsung.com
Thu Feb 9 10:30:52 UTC 2017


Hi, Ciara.

> +EMC Insertion Probability
> +-------------------------
> +By default 1 in every 100 flows are inserted into the Exact Match Cache (EMC).
> +It is possible to change this insertion probability by setting the
> +``emc-insert-prob`` option::
> +
> +    $ ovs-vsctl --no-wait set Open_vSwitch . other_config:emc-insert-prob=N
> +
> +where:
> +
> +``N``
> +  is a positive integer between 0 and 4294967295 (maximum unsigned 32bit int).
> +
> +If ``N`` is set to 1, an insertion will be performed for every flow. The lower
> +the value of ``emc-insert-prob`` the higher the probability of insertion,
> +except for the value 0 which will result in no insertions being performed and
> +thus essentially disabling the EMC.

I totally don't understand why 'N' is an integer between 0 and 4294967295.
Why we can't just use 0-100% for that config?

Probability in math is a value between 0 and 1. We can use an integer values
from 0 to 100 in percents. IMHO, that strange configuration kind of misleading
because 'emc-insert-prob' reads as 'emc-insert-probability' but means something
completely different. Also, does all of this values from 0 to 4294967295 are useful?

What do you think?

Best regards, Ilya Maximets.


More information about the dev mailing list