|
The Pedigree Project 0.1
|
Abstrace base class for hardware I/O capabilities. More...
#include <IoBase.h>
Inheritance diagram for IoBase:
Collaboration diagram for IoBase:Public Member Functions | |
| virtual | ~IoBase () |
| virtual size_t | size () const =0 |
| virtual uint8_t | read8 (size_t offset=0)=0 |
| virtual uint16_t | read16 (size_t offset=0)=0 |
| virtual uint32_t | read32 (size_t offset=0)=0 |
| virtual uint64_t | read64 (size_t offset=0)=0 |
| uint64_t | read64LowFirst (size_t offset=0) |
| uint64_t | read64HighFirst (size_t offset=0) |
| virtual void | write8 (uint8_t value, size_t offset=0)=0 |
| virtual void | write16 (uint16_t value, size_t offset=0)=0 |
| virtual void | write32 (uint32_t value, size_t offset=0)=0 |
| virtual void | write64 (uint64_t value, size_t offset=0)=0 |
| void | write64LowFirst (uint64_t value, size_t offset=0) |
| void | write64HighFirst (uint64_t value, size_t offset=0) |
| virtual | operator bool () const =0 |
Protected Member Functions | |
| IoBase () | |
Private Member Functions | |
| IoBase (const IoBase &) | |
| IoBase & | operator= (const IoBase &) |
Abstrace base class for hardware I/O capabilities.
Interface to the hardware's I/O capabilities
|
virtualdefault |
The destructor does nothing
|
protecteddefault |
The default constructor does nothing
|
private |
The copy-constructor
|
pure virtual |
Check whether this class is usable
Implemented in IoPort, and MemoryMappedIo.
|
pure virtual |
Read two byte (16bit) from the I/O Port or the memory-mapped I/O region
| [in] | offset | offset from the I/O base port or the I/O base memory address |
Implemented in IoPort, and MemoryMappedIo.
Referenced by Uhci::cancelAsyncAndDrain(), Uhci::cancelInterruptInAndDrain(), AtaDisk::doRead(), Uhci::executeRequest(), AtaDisk::initialise(), Nic3C90x::irq(), Uhci::irq(), Nic3C90x::issueCommand(), Uhci::modifyPortControl(), Ne2k::Ne2k(), Nic3C90x::Nic3C90x(), Uhci::portReset(), Nic3C90x::readEeprom(), Uhci::start(), Uhci::stop(), and Uhci::timer().
Here is the caller graph for this function:
|
pure virtual |
Read four byte (32bit) from the I/O Port or the memory-mapped I/O region
| [in] | offset | offset from the I/O base port or the I/O base memory address |
Implemented in IoPort, and MemoryMappedIo.
Referenced by Ehci::addInterruptInHandler(), Ehci::cancelAsyncAndDrain(), Ohci::cancelAsyncAndDrain(), Ehci::cancelInterruptInAndDrain(), Ohci::doAsync(), Ehci::executeRequest(), Ohci::executeRequest(), AhciController::irq(), Ohci::irq(), Nic3C90x::Nic3C90x(), Ehci::portReset(), Ohci::portReset(), read64HighFirst(), read64LowFirst(), Ehci::replaySuppressedConnectionChange(), Nic3C90x::reset(), Nic3C90x::send(), Ohci::setRootHubStatusChangeSource(), Ohci::start(), Ohci::stop(), and Ohci::transitionControllerState().
Here is the caller graph for this function:
|
pure virtual |
Read eight byte (64bit) from the I/O Port or the memory-mapped I/O region.
| [in] | offset | offset from the I/O base port or the I/O base memory address |
Implemented in IoPort, and MemoryMappedIo.
|
inline |
Read eight byte (64bit) from the I/O Port or the memory-mapped I/O region. The 32bit at the higher address are read first, then the 32bit at the lower address.
| [in] | offset | offset from the I/O base port or the I/O base memory address |
Definition at line 31 of file IoBase.cc.
References read32().
|
inline |
Read eight byte (64bit) from the I/O Port or the memory-mapped I/O region. The 32bit at the lower address are read first, then the 32bit at the higher address.
| [in] | offset | offset from the I/O base port or the I/O base memory address |
Definition at line 25 of file IoBase.cc.
References read32().
|
pure virtual |
Read a byte (8bit) from the I/O Port or the memory-mapped I/O region
| [in] | offset | offset from the I/O base port or the I/O base memory address |
Implemented in IoPort, and MemoryMappedIo.
Referenced by BusMasterIde::add(), BusMasterIde::begin(), BusMasterIde::commandComplete(), BusMasterIde::hasCompleted(), BusMasterIde::hasError(), BusMasterIde::hasInterrupt(), AtaDisk::initialise(), Nic3C90x::irq(), Ne2k::irq(), Ps2Controller::irq(), Ne2k::Ne2k(), Ps2Controller::readByte(), and Ne2k::send().
Here is the caller graph for this function:
|
pure virtual |
Get the size of the I/O region in bytes
Implemented in IoPort, and MemoryMappedIo.
Referenced by BusMasterIde::initialise().
Here is the caller graph for this function:
|
pure virtual |
Write two byte (16bit) to the I/O port or the memory-mapped I/O region
| [in] | value | the value that should be written |
| [in] | offset | offset from the I/O base port or the I/O base memory address |
Implemented in IoPort, and MemoryMappedIo.
Referenced by Uhci::cancelAsyncAndDrain(), Uhci::cancelInterruptInAndDrain(), Uhci::irq(), Nic3C90x::issueCommand(), Uhci::modifyPortControl(), Nic3C90x::Nic3C90x(), Uhci::portReset(), Nic3C90x::readEeprom(), Nic3C90x::reset(), Ne2k::send(), Uhci::start(), Uhci::stop(), Uhci::timer(), and Nic3C90x::writeEepromWord().
Here is the caller graph for this function:
|
pure virtual |
Write four byte (32bit) to the I/O port or the memory-mapped I/O region
| [in] | value | the value that should be written |
| [in] | offset | offset from the I/O base port or the I/O base memory address |
Implemented in IoPort, and MemoryMappedIo.
Referenced by Ehci::addInterruptInHandler(), BusMasterIde::begin(), Ehci::cancelAsyncAndDrain(), Ohci::cancelAsyncAndDrain(), Ehci::cancelInterruptInAndDrain(), Ohci::detachED(), Ohci::doAsync(), Nic3C90x::irq(), AhciController::irq(), Ohci::irq(), Nic3C90x::Nic3C90x(), Ohci::portReset(), Ohci::removeED(), Ehci::replaySuppressedConnectionChange(), Nic3C90x::reset(), Nic3C90x::send(), Ohci::setRootHubStatusChangeSource(), Ohci::start(), Ohci::stop(), Ohci::transitionControllerState(), write64HighFirst(), and write64LowFirst().
Here is the caller graph for this function:
|
pure virtual |
Write eight byte (64bit) to the I/O Port or the memory-mapped I/O region.
| [in] | value | the value that should be written |
| [in] | offset | offset from the I/O base port or the I/O base memory address |
Implemented in IoPort, and MemoryMappedIo.
| void IoBase::write64HighFirst | ( | uint64_t | value, |
| size_t | offset = 0 |
||
| ) |
Write eight byte (64bit) to the I/O Port or the memory-mapped I/O region. The 32bit at the higher address are written first, then the 32bit at the lower address.
| [in] | value | the value that should be written |
| [in] | offset | offset from the I/O base port or the I/O base memory address |
Definition at line 42 of file IoBase.cc.
References write32().
| void IoBase::write64LowFirst | ( | uint64_t | value, |
| size_t | offset = 0 |
||
| ) |
Write eight byte (64bit) to the I/O Port or the memory-mapped I/O region. The 32bit at the lower address are written first, then the 32bit at the higher address.
| [in] | value | the value that should be written |
| [in] | offset | offset from the I/O base port or the I/O base memory address |
Definition at line 37 of file IoBase.cc.
References write32().
|
pure virtual |
Write a byte (8bit) to the I/O port or the memory-mapped I/O region
| [in] | value | the value that should be written |
| [in] | offset | offset from the I/O base port or the I/O base memory address |
Implemented in IoPort, and MemoryMappedIo.
Referenced by BusMasterIde::begin(), BusMasterIde::commandComplete(), AtaDisk::doRead(), AtaDisk::initialise(), Nic3C90x::irq(), Ne2k::irq(), AtaDisk::maskInterrupts(), Ne2k::Ne2k(), Nic3C90x::Nic3C90x(), Nic3C90x::reset(), Ne2k::send(), AtaDisk::setFeatures(), AtaDisk::setupLBA28(), AtaDisk::setupLBA48(), Ib700Watchdog::timer(), and AtaDisk::writePageBuffer().
Here is the caller graph for this function: