#include "mem/mem_object.hh"
#include "mem/packet.hh"
#include "mem/port.hh"
+#include "params/Bridge.hh"
#include "sim/eventq.hh"
class Bridge : public MemObject
expectResponse(_pkt->needsResponse() && !nack)
{
- if (!pkt->isResponse() && !nack && pkt->result != Packet::Nacked)
+ if (!pkt->isResponse() && !nack && !pkt->wasNacked())
pkt->senderState = this;
}
virtual void process() { port->trySend(); }
- virtual const char *description() { return "bridge send event"; }
+ virtual const char *description() { return "bridge send"; }
};
SendEvent sendEvent;
/** When receiving a address range request the peer port,
pass it to the bridge. */
virtual void getDeviceAddressRanges(AddrRangeList &resp,
- AddrRangeList &snoop);
+ bool &snoop);
};
BridgePort portA, portB;
bool ackWrites;
public:
- struct Params
- {
- std::string name;
- int req_size_a;
- int req_size_b;
- int resp_size_a;
- int resp_size_b;
- Tick delay;
- Tick nack_delay;
- bool write_ack;
- bool fix_partial_write_a;
- bool fix_partial_write_b;
- };
+ typedef BridgeParams Params;
protected:
Params *_params;