29#ifndef __DEV_X86_I8254_HH__
30#define __DEV_X86_I8254_HH__
35#include "params/I8254.hh"
55 parent->counterInterrupt(num);
77 if (if_name ==
"int_pin")
86 for (
int i = 0;
i <
p.port_int_pin_connection_count;
i++) {
88 "%s.int_pin[%d]",
name(),
i),
i,
this));
98 return pit.outputHigh(num);
104 return pit.readCounter(num);
BasicPioDevice(const Params &p, Addr size)
const std::string & name() const
Intel8254Timer(EventManager *em, const std::string &name)
virtual std::string name() const
Port & getPort(const std::string &if_name, PortID idx=InvalidPortID) override
Get a port with a given name and index.
Ports are used to interface objects to each other.
void counterInterrupt(unsigned int num)
X86Intel8254Timer(const std::string &name, I8254 *_parent)
uint8_t readCounter(unsigned int num)
void writeControl(uint8_t val)
bool outputHigh(unsigned int num)
void writeCounter(unsigned int num, const uint8_t data)
void unserialize(CheckpointIn &cp) override
Unserialize an object.
Port & getPort(const std::string &if_name, PortID idx=InvalidPortID) override
Get a port with a given name and index.
std::vector< IntSourcePin< I8254 > * > intPin
void startup() override
startup() is the final initialization call before simulation.
Tick write(PacketPtr pkt) override
Pure virtual function that the device must implement.
void counterInterrupt(unsigned int num)
Tick read(PacketPtr pkt) override
Pure virtual function that the device must implement.
void serialize(CheckpointOut &cp) const override
Serialize an object.
This is exposed globally, independent of the ISA.
Copyright (c) 2024 Arm Limited All rights reserved.
const PortID InvalidPortID
IntSourcePinBase IntSourcePin
std::ostream CheckpointOut
int16_t PortID
Port index/ID type, and a symbolic name for an invalid port id.
uint64_t Tick
Tick count type.
std::string csprintf(const char *format, const Args &...args)