Go to the documentation of this file.
28 #ifndef __SIM_SIGNAL_HH__
29 #define __SIM_SIGNAL_HH__
39 template <
typename State>
42 template <
typename State>
58 set(
const State &new_state)
81 "incompatible pin %s",
name(), peer.
name());
92 template <
typename State>
93 class SignalSourcePort :
public Port
105 set(
const State &new_state)
108 sink->set(new_state);
118 "incompatible pin %s",
name(), peer.
name());
131 #endif //__SIM_SIGNAL_HH__
int16_t PortID
Port index/ID type, and a symbolic name for an invalid port id.
void bind(Port &peer) override
const State & state() const
const std::string name() const
Return port name (for DPRINTF).
void onChange(OnChangeFunc func)
void set(const State &new_state)
std::function< void(const bool &new_val)> OnChangeFunc
void unbind() override
Dettach from a peer port.
const PortID InvalidPortID
void set(const State &new_state)
virtual void bind(Port &peer)
Attach to a peer port.
SignalSinkPort< State > * sink
const std::string & name()
const State & state() const
virtual void unbind()
Dettach from a peer port.
SignalSourcePort(const std::string &_name, PortID _id=InvalidPortID)
Ports are used to interface objects to each other.
SignalSinkPort(const std::string &_name, PortID _id=InvalidPortID)
#define fatal_if(cond,...)
Conditional fatal macro that checks the supplied condition and only causes a fatal error if the condi...
void bind(Port &peer) override
Attach to a peer port.
Reference material can be found at the JEDEC website: UFS standard http://www.jedec....
SignalSourcePort< State > * _source
Generated on Sun Jul 30 2023 01:57:00 for gem5 by doxygen 1.8.17