[ovs-dev] [PATCH] tunnel: Support all combinations of flow-based and specific tunnel matches.

Pritesh Kothari (pritkoth) pritkoth at cisco.com
Tue Feb 11 23:25:33 UTC 2014

On Feb 11, 2014, at 3:20 PM, Ben Pfaff <blp at nicira.com> wrote:

> On Tue, Feb 11, 2014 at 06:48:33PM +0000, Pritesh Kothari (pritkoth) wrote:
>> On Feb 11, 2014, at 8:05 AM, Ben Pfaff <blp at nicira.com> wrote:
>>> On Tue, Feb 11, 2014 at 12:00:46AM +0000, Pritesh Kothari (pritkoth) wrote:
>>>> any insight into this would be greatly appreciated, alternatively i was thinking
>>>> of adding the code shown below, outside the outer most for loop in tnl_find
>>>> to add the 8 matches mentioned above, but then tnl_match_map can?t exactly
>>>> differentiate these cases from original 12 above, so not sure about it.
>>>>   for (in_key_flow = 0; in_key_flow < 2; in_key_flow++) {
>>>>       for (in_nsp_flow = 0; in_nsp_flow < 2; in_nsp_flow++) {
>>>>           for (in_nsi_flow = 0; ip_nsi_flow < 2; ip_nsi_flow++) {
>>> We probably don't want so many nested loops--48 tests is wasteful.  I'd
>>> suggest instead maintaining a uint64_t with a 1-bit in each position
>>> where there is any match, and then iterating through the 1-bits with
>>> bitwise functions.
>> sounds good to me, will do this and post a patch for this in rfc for
>> nsh soon.
> OK.  Is a new patch series almost ready then?  It seems like it's been a
> long time since the last update.

actually it is almost ready, i was working on a kernel module which
could go upstream as well replace the compat stuff in the earlier patch sets.


More information about the dev mailing list