* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
- * Authors: Giacomo Travaglini
*/
#include "dev/arm/gic_v3_its.hh"
+#include <cassert>
+#include <functional>
+
+#include "base/logging.hh"
+#include "base/trace.hh"
#include "debug/AddrRanges.hh"
#include "debug/Drain.hh"
#include "debug/GIC.hh"
#define COMMAND(x, method) { x, DispatchEntry(#x, method) }
-const AddrRange Gicv3Its::GITS_BASER(0x0100, 0x0138);
+const AddrRange Gicv3Its::GITS_BASER(0x0100, 0x0140);
const uint32_t Gicv3Its::CTLR_QUIESCENT = 0x80000000;
a.type = ItsActionType::SEND_REQ;
RequestPtr req = std::make_shared<Request>(
- addr, size, 0, its.masterId);
+ addr, size, 0, its.requestorId);
req->taskId(ContextSwitchTaskId::DMA);
a.type = ItsActionType::SEND_REQ;
RequestPtr req = std::make_shared<Request>(
- addr, size, 0, its.masterId);
+ addr, size, 0, its.requestorId);
req->taskId(ContextSwitchTaskId::DMA);
panic("ITS %s command unimplemented", __func__);
}
-Gicv3Its::Gicv3Its(const Gicv3ItsParams *params)
- : BasicPioDevice(params, params->pio_size),
+Gicv3Its::Gicv3Its(const Gicv3ItsParams ¶ms)
+ : BasicPioDevice(params, params.pio_size),
dmaPort(name() + ".dma", *this),
gitsControl(CTLR_QUIESCENT),
- gitsTyper(params->gits_typer),
+ gitsTyper(params.gits_typer),
gitsCbaser(0), gitsCreadr(0),
gitsCwriter(0), gitsIidr(0),
tableBases(NUM_BASER_REGS, 0),
- masterId(params->system->getMasterId(this)),
+ requestorId(params.system->getRequestorId(this)),
gic(nullptr),
commandEvent([this] { checkCommandQueue(); }, name()),
pendingCommands(false),
}
}
- pkt->setUintX(value, LittleEndianByteOrder);
+ pkt->setUintX(value, ByteOrder::little);
pkt->makeAtomicResponse();
return pioDelay;
}
rd2->updateDistributor();
}
-
-Gicv3Its *
-Gicv3ItsParams::create()
-{
- return new Gicv3Its(this);
-}