port.hh (13319:94ab5f67a8c3) port.hh (13321:1c59e4a11e6f)
1/*
2 * Copyright 2018 Google, Inc.
3 *
4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are
6 * met: redistributions of source code must retain the above copyright
7 * notice, this list of conditions and the following disclaimer;
8 * redistributions in binary form must reproduce the above copyright

--- 53 unchanged lines hidden (view full) ---

62
63 void finalizePort(StaticSensitivityPort *port);
64 void finalizeFinder(StaticSensitivityFinder *finder);
65 void finalizeReset(Reset *reset);
66
67 void
68 addInterface(::sc_core::sc_interface *iface)
69 {
1/*
2 * Copyright 2018 Google, Inc.
3 *
4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are
6 * met: redistributions of source code must retain the above copyright
7 * notice, this list of conditions and the following disclaimer;
8 * redistributions in binary form must reproduce the above copyright

--- 53 unchanged lines hidden (view full) ---

62
63 void finalizePort(StaticSensitivityPort *port);
64 void finalizeFinder(StaticSensitivityFinder *finder);
65 void finalizeReset(Reset *reset);
66
67 void
68 addInterface(::sc_core::sc_interface *iface)
69 {
70 for (int i = 0; i < _size; i++) {
71 if (getInterface(i) == iface) {
72 std::string msg =
73 csprintf("interface already bound to port: port '%s' (%s)",
74 portBase->name(), portBase->kind());
75 SC_REPORT_ERROR("(E107) bind interface to port failed",
76 msg.c_str());
77 }
78 }
79 _size++;
80 portBase->_gem5AddInterface(iface);
70 portBase->_gem5AddInterface(iface);
71 _size++;
81 }
82
83 void
84 addInterfaces(::sc_core::sc_port_base *pb)
85 {
86 // Only the ports farthest from the interfaces call register_port.
87 pb->_gem5Port->regPortNeeded = false;
88 for (int i = 0; i < pb->size(); i++)

--- 88 unchanged lines hidden ---
72 }
73
74 void
75 addInterfaces(::sc_core::sc_port_base *pb)
76 {
77 // Only the ports farthest from the interfaces call register_port.
78 pb->_gem5Port->regPortNeeded = false;
79 for (int i = 0; i < pb->size(); i++)

--- 88 unchanged lines hidden ---