Skip to content

Commit

Permalink
expr: New module for Boolean expressions on fields, for use in OVN.
Browse files Browse the repository at this point in the history
Known weaknesses:

    * String fields can't be converted to flows yet.  A subsequent commit
      will fix this.

    * Flows aren't optimal in some situations likely to be common.
      I don't think either of those is a reason not to commit this;
      this is a solid base to build on.

Signed-off-by: Ben Pfaff <[email protected]>
Acked-by: Russell Bryant <[email protected]>
  • Loading branch information
blp committed Apr 15, 2015
1 parent 35c1f79 commit e0840f1
Show file tree
Hide file tree
Showing 7 changed files with 4,403 additions and 128 deletions.
25 changes: 0 additions & 25 deletions ovn/TODO
Original file line number Diff line number Diff line change
Expand Up @@ -4,31 +4,6 @@
the same syntax and I imagine the same code ought to be useful in
ovn-nbd for ACL match expressions.

** Definition of data structures to represent a match expression as a
syntax tree.

** Definition of data structures to represent variables (fields).

Fields need names and prerequisites. Most fields are numeric and
thus need widths. We need also need a way to represent nominal
fields (currently just logical port names). It might be
appropriate to associate fields directly with OXM/NXM code points;
we have to decide whether we want OVN to use the OVS flow structure
or work with OXM more directly.

Probably should be defined so that the data structure is also
useful for references to fields in action parsing.

** Parsing into syntax tree.

** Semantic checking against variable definitions.

** Applying prerequisites.

** Simplification into conjunction-of-disjunctions (CoD) form.

** Transformation from CoD form into OXM matches.

* ovn-controller

** Flow table handling in ovn-controller.
Expand Down
6 changes: 5 additions & 1 deletion ovn/lib/automake.mk
Original file line number Diff line number Diff line change
@@ -1,2 +1,6 @@
lib_LTLIBRARIES += ovn/lib/libovn.la
ovn_lib_libovn_la_SOURCES = ovn/lib/lex.c ovn/lib/lex.h
ovn_lib_libovn_la_SOURCES = \
ovn/lib/expr.c \
ovn/lib/expr.h \
ovn/lib/lex.c \
ovn/lib/lex.h
Loading

0 comments on commit e0840f1

Please sign in to comment.