summaryrefslogtreecommitdiffstats
path: root/scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_port.py
diff options
context:
space:
mode:
authorimarom <imarom@cisco.com>2016-10-31 11:58:27 +0200
committerimarom <imarom@cisco.com>2016-11-02 15:08:35 +0200
commit0337db2b07c2c054ee5c5ea49cab6cfce5d5a897 (patch)
treeea29f13937170a989697356ed9f777dc4db4670f /scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_port.py
parent02ab06b1cf8886be0a6fde5360497b4fa968d3a3 (diff)
draft: RX software feature
Signed-off-by: imarom <imarom@cisco.com>
Diffstat (limited to 'scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_port.py')
-rw-r--r--scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_port.py27
1 files changed, 27 insertions, 0 deletions
diff --git a/scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_port.py b/scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_port.py
index cec3761f..bf0251b8 100644
--- a/scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_port.py
+++ b/scripts/automation/trex_control_plane/stl/trex_stl_lib/trex_stl_port.py
@@ -487,6 +487,21 @@ class Port(object):
return self.ok()
+ @writeable
+ def set_rx_filter_mode (self, filter_mode):
+ assert(filter_mode in ["hw", "all"])
+
+ params = {"handler": self.handler,
+ "port_id": self.port_id,
+ "type": "filter_mode",
+ "filter_type": filter_mode}
+
+ rc = self.transmit("set_rx_feature", params)
+ if rc.bad():
+ return self.err(rc.err())
+
+ return self.ok()
+
@owned
def pause (self):
@@ -583,6 +598,18 @@ class Port(object):
return self.ok()
+ @owned
+ def get_rx_sw_pkts (self):
+ params = {"handler": self.handler,
+ "port_id": self.port_id}
+
+ rc = self.transmit("get_rx_sw_pkts", params)
+ if rc.bad():
+ return self.err(rc.err())
+
+ return self.ok()
+
+
@writeable
def push_remote (self, pcap_filename, ipg_usec, speedup, count, duration, is_dual, slave_handler):