summaryrefslogtreecommitdiff
path: root/configs/topologies
diff options
context:
space:
mode:
authorNilay Vaish <nilay@cs.wisc.edu>2014-02-23 19:16:15 -0600
committerNilay Vaish <nilay@cs.wisc.edu>2014-02-23 19:16:15 -0600
commit6aafd5cb3fdaf43aeaf71ea47046dfc909eeeb62 (patch)
treebd8c3eb1f1ef22a11782a08065a24658e79e99df /configs/topologies
parent7572ab71b56b01e3ee7742dd385af81b49bd753d (diff)
downloadgem5-6aafd5cb3fdaf43aeaf71ea47046dfc909eeeb62.tar.xz
config: topologies: slight code refactor
Diffstat (limited to 'configs/topologies')
-rw-r--r--configs/topologies/Cluster.py16
1 files changed, 12 insertions, 4 deletions
diff --git a/configs/topologies/Cluster.py b/configs/topologies/Cluster.py
index 5f41edd0a..b146d8675 100644
--- a/configs/topologies/Cluster.py
+++ b/configs/topologies/Cluster.py
@@ -86,10 +86,15 @@ class Cluster(BaseTopology):
node.makeTopology(options, network, IntLink, ExtLink, Router)
# connect this cluster to the router
- link = IntLink(link_id=self.num_int_links(), node_a=self.router, node_b=node.router)
+ link = IntLink(link_id=self.num_int_links(), node_a=self.router,
+ node_b=node.router)
+
if node.extBW:
link.bandwidth_factor = node.extBW
- elif self.intBW: # if there is an interanl b/w for this node and no ext b/w to override
+
+ # if there is an interanl b/w for this node
+ # and no ext b/w to override
+ elif self.intBW:
link.bandwidth_factor = self.intBW
if node.extLatency:
@@ -99,8 +104,11 @@ class Cluster(BaseTopology):
network.int_links.append(link)
else:
- # node is just a controller connect it to the router via a ext_link
- link = ExtLink(link_id=self.num_ext_links(), ext_node=node, int_node=self.router)
+ # node is just a controller,
+ # connect it to the router via a ext_link
+ link = ExtLink(link_id=self.num_ext_links(), ext_node=node,
+ int_node=self.router)
+
if self.intBW:
link.bandwidth_factor = self.intBW
if self.intLatency: