xbar.cc (13892:0182a0601f66) | xbar.cc (14192:595a4358b844) |
---|---|
1/* 2 * Copyright (c) 2011-2015, 2018 ARM Limited 3 * All rights reserved 4 * 5 * The license below extends only to copyright in the software and shall 6 * not be construed as granting a license to any other intellectual 7 * property including but not limited to intellectual property relating 8 * to a hardware implementation of the functionality of the software --- 330 unchanged lines hidden (view full) --- 339 name()); 340} 341 342/** Function called by the port when the crossbar is receiving a range change.*/ 343void 344BaseXBar::recvRangeChange(PortID master_port_id) 345{ 346 DPRINTF(AddrRanges, "Received range change from slave port %s\n", | 1/* 2 * Copyright (c) 2011-2015, 2018 ARM Limited 3 * All rights reserved 4 * 5 * The license below extends only to copyright in the software and shall 6 * not be construed as granting a license to any other intellectual 7 * property including but not limited to intellectual property relating 8 * to a hardware implementation of the functionality of the software --- 330 unchanged lines hidden (view full) --- 339 name()); 340} 341 342/** Function called by the port when the crossbar is receiving a range change.*/ 343void 344BaseXBar::recvRangeChange(PortID master_port_id) 345{ 346 DPRINTF(AddrRanges, "Received range change from slave port %s\n", |
347 masterPorts[master_port_id]->getSlavePort().name()); | 347 masterPorts[master_port_id]->getPeer()); |
348 349 // remember that we got a range from this master port and thus the 350 // connected slave module 351 gotAddrRanges[master_port_id] = true; 352 353 // update the global flag 354 if (!gotAllAddrRanges) { 355 // take a logical AND of all the ports and see if we got --- 44 unchanged lines hidden (view full) --- 400 DPRINTF(AddrRanges, "Adding range %s for id %d\n", 401 r.to_string(), master_port_id); 402 if (portMap.insert(r, master_port_id) == portMap.end()) { 403 PortID conflict_id = portMap.intersects(r)->second; 404 fatal("%s has two ports responding within range " 405 "%s:\n\t%s\n\t%s\n", 406 name(), 407 r.to_string(), | 348 349 // remember that we got a range from this master port and thus the 350 // connected slave module 351 gotAddrRanges[master_port_id] = true; 352 353 // update the global flag 354 if (!gotAllAddrRanges) { 355 // take a logical AND of all the ports and see if we got --- 44 unchanged lines hidden (view full) --- 400 DPRINTF(AddrRanges, "Adding range %s for id %d\n", 401 r.to_string(), master_port_id); 402 if (portMap.insert(r, master_port_id) == portMap.end()) { 403 PortID conflict_id = portMap.intersects(r)->second; 404 fatal("%s has two ports responding within range " 405 "%s:\n\t%s\n\t%s\n", 406 name(), 407 r.to_string(), |
408 masterPorts[master_port_id]->getSlavePort().name(), 409 masterPorts[conflict_id]->getSlavePort().name()); | 408 masterPorts[master_port_id]->getPeer(), 409 masterPorts[conflict_id]->getPeer()); |
410 } 411 } 412 } 413 414 // if we have received ranges from all our neighbouring slave 415 // modules, go ahead and tell our connected master modules in 416 // turn, this effectively assumes a tree structure of the system 417 if (gotAllAddrRanges) { --- 134 unchanged lines hidden (view full) --- 552 553 // both the packet count and total size are two-dimensional 554 // vectors, indexed by slave port id and master port id, thus the 555 // neighbouring master and slave, they do not differentiate what 556 // came from the master and was forwarded to the slave (requests 557 // and snoop responses) and what came from the slave and was 558 // forwarded to the master (responses and snoop requests) 559 for (int i = 0; i < slavePorts.size(); i++) { | 410 } 411 } 412 } 413 414 // if we have received ranges from all our neighbouring slave 415 // modules, go ahead and tell our connected master modules in 416 // turn, this effectively assumes a tree structure of the system 417 if (gotAllAddrRanges) { --- 134 unchanged lines hidden (view full) --- 552 553 // both the packet count and total size are two-dimensional 554 // vectors, indexed by slave port id and master port id, thus the 555 // neighbouring master and slave, they do not differentiate what 556 // came from the master and was forwarded to the slave (requests 557 // and snoop responses) and what came from the slave and was 558 // forwarded to the master (responses and snoop requests) 559 for (int i = 0; i < slavePorts.size(); i++) { |
560 pktCount.subname(i, slavePorts[i]->getMasterPort().name()); 561 pktSize.subname(i, slavePorts[i]->getMasterPort().name()); | 560 pktCount.subname(i, slavePorts[i]->getPeer().name()); 561 pktSize.subname(i, slavePorts[i]->getPeer().name()); |
562 for (int j = 0; j < masterPorts.size(); j++) { | 562 for (int j = 0; j < masterPorts.size(); j++) { |
563 pktCount.ysubname(j, masterPorts[j]->getSlavePort().name()); 564 pktSize.ysubname(j, masterPorts[j]->getSlavePort().name()); | 563 pktCount.ysubname(j, masterPorts[j]->getPeer().name()); 564 pktSize.ysubname(j, masterPorts[j]->getPeer().name()); |
565 } 566 } 567} 568 569template <typename SrcType, typename DstType> 570DrainState 571BaseXBar::Layer<SrcType, DstType>::drain() 572{ --- 38 unchanged lines hidden --- | 565 } 566 } 567} 568 569template <typename SrcType, typename DstType> 570DrainState 571BaseXBar::Layer<SrcType, DstType>::drain() 572{ --- 38 unchanged lines hidden --- |