Commit 7536b0c8 authored by Jialin Li's avatar Jialin Li
Browse files

tofino: add Tofino network to simulator script

parent c17fd5db
...@@ -264,6 +264,13 @@ class SwitchNet(NetSim): ...@@ -264,6 +264,13 @@ class SwitchNet(NetSim):
cmd += ' -s ' + env.nic_eth_path(n) cmd += ' -s ' + env.nic_eth_path(n)
return cmd return cmd
class TofinoNet(NetSim):
def run_cmd(self, env):
cmd = env.repodir + '/sims/tofino/tofino'
cmd += f' -m {self.sync_mode} -S {self.sync_period} -E {self.eth_latency}'
for n in self.nics:
cmd += ' -s ' + env.nic_eth_path(n)
return cmd
class NS3DumbbellNet(NetSim): class NS3DumbbellNet(NetSim):
def run_cmd(self, env): def run_cmd(self, env):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment