X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=extras%2Fvom%2Fvom%2Finterface.hpp;h=a46b114833e4436119e91da645de8156f3d38e45;hb=33b81da;hp=f6708b301760f7e23c499e780a20da45a65e9779;hpb=164e5f8c63652028ecb9c3570e1ea8618b163071;p=vpp.git diff --git a/extras/vom/vom/interface.hpp b/extras/vom/vom/interface.hpp index f6708b30176..a46b114833e 100644 --- a/extras/vom/vom/interface.hpp +++ b/extras/vom/vom/interface.hpp @@ -99,6 +99,11 @@ public: */ const static type_t TAP; + /** + * TAPv2 interface type + */ + const static type_t TAPV2; + /** * vhost-user interface type */ @@ -109,6 +114,16 @@ public: */ const static type_t BOND; + /** + * pipe-parent type + */ + const static type_t PIPE; + + /** + * pipe-end type + */ + const static type_t PIPE_END; + /** * Convert VPP's name of the interface to a type */ @@ -266,11 +281,11 @@ public: * A base class for interface Create commands */ template - class create_cmd : public rpc_cmd, HW::item, MSG> + class create_cmd : public rpc_cmd, MSG> { public: create_cmd(HW::item& item, const std::string& name) - : rpc_cmd, HW::item, MSG>(item) + : rpc_cmd, MSG>(item) , m_name(name) { } @@ -293,7 +308,7 @@ public: */ void succeeded() { - rpc_cmd, HW::item, MSG>::succeeded(); + rpc_cmd, MSG>::succeeded(); interface::add(m_name, this->item()); } @@ -316,9 +331,7 @@ public: handle = sw_if_index; } - HW::item res(handle, rc); - - this->fulfill(res); + this->fulfill(HW::item(handle, rc)); return (VAPI_OK); } @@ -334,17 +347,17 @@ public: * Base class for intterface Delete commands */ template - class delete_cmd : public rpc_cmd, HW::item, MSG> + class delete_cmd : public rpc_cmd, MSG> { public: delete_cmd(HW::item& item, const std::string& name) - : rpc_cmd, HW::item, MSG>(item) + : rpc_cmd, MSG>(item) , m_name(name) { } delete_cmd(HW::item& item) - : rpc_cmd, HW::item, MSG>(item) + : rpc_cmd, MSG>(item) , m_name() { } @@ -466,6 +479,7 @@ protected: */ void set(const handle_t& handle); friend class interface_factory; + friend class pipe; /** * The SW interface handle VPP has asigned to the interface