X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=lib%2Fofp-util.h;h=77162bf29cfc0ff001fbf75e9f995902b544f485;hb=305b76debf72120672a8ba81d3356b6dccb1da9a;hp=c8bf11e17e81738b8ab1d8b376ded06dd0a0ce6e;hpb=4f13da568d49b4910cedf45e6c54c43ea318dd18;p=sliver-openvswitch.git diff --git a/lib/ofp-util.h b/lib/ofp-util.h index c8bf11e17..77162bf29 100644 --- a/lib/ofp-util.h +++ b/lib/ofp-util.h @@ -17,7 +17,6 @@ #ifndef OFP_UTIL_H #define OFP_UTIL_H 1 -#include #include #include #include @@ -507,6 +506,19 @@ enum ofperr ofputil_decode_port_mod(const struct ofp_header *, struct ofpbuf *ofputil_encode_port_mod(const struct ofputil_port_mod *, enum ofputil_protocol); +/* Abstract ofp_role_request and reply. */ +struct ofputil_role_request { + bool request_current_role_only; /* no role change */ + bool have_generation_id; + enum nx_role role; + uint64_t generation_id; +}; + +enum ofperr ofputil_decode_role_message(const struct ofp_header *, + struct ofputil_role_request *); +struct ofpbuf *ofputil_encode_role_reply(const struct ofp_header *, + enum nx_role current_role); + /* Abstract table stats. * * For now we use ofp12_table_stats as a superset of the other protocol