aboutsummaryrefslogtreecommitdiffstats
path: root/src/vpp-api
diff options
context:
space:
mode:
authorMohsin Kazmi <sykazmi@cisco.com>2018-04-03 14:23:30 +0200
committerNeale Ranns <nranns@cisco.com>2018-04-05 09:46:04 +0000
commit1e583111ebeb0333435cfad8af10ebe0e9842d4d (patch)
tree97af38e826d0cb1ef77488985f4f3800b896d5a7 /src/vpp-api
parent16aa7f83c74017a35bbeb47d09d8cc3e731ae6b1 (diff)
VOM: Add sub_interface in specific routing table
Change-Id: I3700fc1d140e30da783e41762670618f0298c7db Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Diffstat (limited to 'src/vpp-api')
-rw-r--r--src/vpp-api/vom/sub_interface.cpp13
-rw-r--r--src/vpp-api/vom/sub_interface.hpp6
2 files changed, 19 insertions, 0 deletions
diff --git a/src/vpp-api/vom/sub_interface.cpp b/src/vpp-api/vom/sub_interface.cpp
index 94baa3d2ecc..42f75791968 100644
--- a/src/vpp-api/vom/sub_interface.cpp
+++ b/src/vpp-api/vom/sub_interface.cpp
@@ -29,6 +29,19 @@ sub_interface::sub_interface(const interface& parent,
{
}
+/**
+ * Construct a new object matching the desried state
+ */
+sub_interface::sub_interface(const interface& parent,
+ admin_state_t state,
+ const route_domain& rd,
+ vlan_id_t vlan)
+ : interface(mk_name(parent, vlan), parent.type(), state, rd)
+ , m_parent(parent.singular())
+ , m_vlan(vlan)
+{
+}
+
sub_interface::~sub_interface()
{
sweep();
diff --git a/src/vpp-api/vom/sub_interface.hpp b/src/vpp-api/vom/sub_interface.hpp
index 41786e42ef3..506133c900d 100644
--- a/src/vpp-api/vom/sub_interface.hpp
+++ b/src/vpp-api/vom/sub_interface.hpp
@@ -34,6 +34,12 @@ public:
* Construct a new object matching the desried state
*/
sub_interface(const interface& parent, admin_state_t state, vlan_id_t vlan);
+
+ sub_interface(const interface& parent,
+ admin_state_t state,
+ const route_domain& rd,
+ vlan_id_t vlan);
+
/**
* Destructor
*/