Go to the documentation of this file.
20 #ifndef __SIMPLE_LT_INITIATOR_EXT_H__
21 #define __SIMPLE_LT_INITIATOR_EXT_H__
24 #include "tlm_utils/simple_initiator_socket.h"
49 unsigned int nrOfTransactions = 0x5,
50 unsigned int baseAddress = 0x0) :
71 trans.set_dmi_allowed(
false);
77 trans.set_data_ptr(
reinterpret_cast<unsigned char*
>(&
mData));
85 trans.set_data_ptr(
reinterpret_cast<unsigned char*
>(&
mData));
102 std::cout <<
name() <<
": Send write request: A = 0x"
103 << std::hex << (
unsigned int)trans.get_address()
104 <<
", D = 0x" <<
mData << std::dec
110 std::cout <<
name() <<
": Send read request: A = 0x"
111 << std::hex << (
unsigned int)trans.get_address()
120 std::cout <<
name() <<
": Received error response @ "
125 std::cout <<
name() <<
": Received ok response";
127 std::cout <<
": D = 0x" << std::hex <<
mData << std::dec;
190 switch (
socket->nb_transport_fw(trans, phase,
t)) {
213 if (
socket->get_direct_mem_ptr(trans,
254 dmiData.set_start_address(1);
255 dmiData.set_end_address(0);
265 std::cout <<
name() <<
": got DMI pointer invalidation"
270 std::cout <<
name() <<
": ignored DMI invalidation for addresses "
271 << std::hex << start_range <<
", "
272 << end_range << std::dec
282 std::cout <<
name() <<
", <<SimpleLTInitiator1>>:" << std::endl
284 unsigned char data[32];
292 unsigned int n =
socket->transport_dbg(trans);
294 std::cout <<
"Mem @" << std::hex <<
mBaseAddress << std::endl;
311 for (
unsigned int i=0;
i<
n;
i+=4)
313 for (
int k=e_start;
k!=e_end;
k+=e_increment)
315 std::cout << std::setw(2) << std::setfill(
'0')
320 std::cout << std::endl;
329 std::cout <<
"OK: debug transaction didn't give data." << std::endl;
331 std::cout << std::dec << std::endl;
sc_core::sc_time get_read_latency() const
void logEndTransaction(transaction_type &trans)
void set_data_length(const unsigned int length)
SC_HAS_PROCESS(SimpleLTInitiator_ext)
void register_nb_transport_bw(MODULE *mod, sync_enum_type(MODULE::*cb)(transaction_type &, phase_type &, sc_core::sc_time &))
const sc_time SC_ZERO_TIME
void invalidate(dmi_type &dmiData)
unsigned int mNrOfTransactions
bool is_dmi_allowed() const
unsigned int mBaseAddress
sc_core::sc_time get_write_latency() const
void invalidate_direct_mem_ptr(sc_dt::uint64 start_range, sc_dt::uint64 end_range)
tlm_utils::simple_initiator_socket< SimpleLTInitiator_ext, 32, my_extended_payload_types > initiator_socket_type
void register_invalidate_direct_mem_ptr(MODULE *mod, void(MODULE::*cb)(sc_dt::uint64, sc_dt::uint64))
tlm_command get_command() const
unsigned int mTransactionCount
sc_dt::uint64 get_end_address() const
sc_dt::uint64 get_start_address() const
initiator_socket_type socket
bool initTransaction(transaction_type &trans)
tlm::tlm_generic_payload transaction_type
unsigned char * get_dmi_ptr() const
tlm::tlm_sync_enum sync_enum_type
bool host_has_little_endianness()
const char * name() const
void set_address(const sc_dt::uint64 address)
T * set_extension(T *ext)
sc_core::sc_event mEndEvent
tlm::tlm_phase phase_type
SimpleLTInitiator_ext(sc_core::sc_module_name name, unsigned int nrOfTransactions=0x5, unsigned int baseAddress=0x0)
sync_enum_type myNBTransport(transaction_type &trans, phase_type &phase, sc_core::sc_time &t)
void logStartTransation(transaction_type &trans)
sc_dt::uint64 get_address() const
const sc_time & sc_time_stamp()
void set_data_ptr(unsigned char *data)
void set_response_status(const tlm_response_status response_status)
Generated on Wed Sep 30 2020 14:02:18 for gem5 by doxygen 1.8.17