|
The Pedigree Project
0.1
|
I/O port range. More...
#include <IoPort.h>
Inheritance diagram for IoPort:
Collaboration diagram for IoPort:Public Member Functions | |
| IoPort (const char *name) | |
| virtual | ~IoPort () |
| virtual size_t | size () const |
| virtual uint8_t | read8 (size_t offset=0) |
| virtual uint16_t | read16 (size_t offset=0) |
| virtual uint32_t | read32 (size_t offset=0) |
| virtual uint64_t | read64 (size_t offset=0) |
| virtual void | write8 (uint8_t value, size_t offset=0) |
| virtual void | write16 (uint16_t value, size_t offset=0) |
| virtual void | write32 (uint32_t value, size_t offset=0) |
| virtual void | write64 (uint64_t value, size_t offset=0) |
| virtual | operator bool () const |
| io_port_t | base () const |
| const char * | name () const |
| void | free () |
| bool | allocate (io_port_t ioPort, size_t size) |
Public Member Functions inherited from IoBase | |
| virtual | ~IoBase () |
| uint64_t | read64LowFirst (size_t offset=0) |
| uint64_t | read64HighFirst (size_t offset=0) |
| void | write64LowFirst (uint64_t value, size_t offset=0) |
| void | write64HighFirst (uint64_t value, size_t offset=0) |
Private Member Functions | |
| IoPort (const IoPort &) | |
| IoPort & | operator= (const IoPort &) |
Private Attributes | |
| io_port_t | m_IoPort |
| size_t | m_Size |
| const char * | m_Name |
Additional Inherited Members | |
Protected Member Functions inherited from IoBase | |
| IoBase () | |
I/O port range.
IoPort provides access to a range of hardware I/O port
| IoPort::IoPort | ( | const char * | name | ) |
|
virtual |
|
private |
The copy-constructor
| bool IoPort::allocate | ( | io_port_t | ioPort, |
| size_t | size | ||
| ) |
Allocate an I/O port range
| [in] | ioPort | the base I/O port |
| [in] | size | the number of successive I/O ports - 1 |
Definition at line 34 of file IoPort.cc.
References free(), IoPortManager::instance(), m_IoPort, m_Size, and size().
Referenced by Device::Address::Address(), PciBus::initialise(), Pit::initialise(), Pic::initialise(), Rtc::initialise1(), and PciAtaController::PciAtaController().
Here is the caller graph for this function:| io_port_t IoPort::base | ( | ) | const |
Get the base I/O port
Definition at line 65 of file IoPort.cc.
References m_IoPort.
Referenced by IoPortManager::free().
Here is the caller graph for this function:| void IoPort::free | ( | ) |
Free an I/O port range
Definition at line 49 of file IoPort.cc.
References IoPortManager::free(), IoPortManager::instance(), m_IoPort, and m_Size.
Referenced by allocate(), Pit::uninitialise(), Rtc::uninitialise(), and ~IoPort().
Here is the caller graph for this function:| const char * IoPort::name | ( | ) | const |
|
virtual |
|
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 |
Implements IoBase.
Definition at line 34 of file x86_common/IoPort.cc.
References Processor::halt(), m_IoPort, and m_Size.
|
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 |
Implements IoBase.
Definition at line 45 of file x86_common/IoPort.cc.
References Processor::halt(), m_IoPort, and m_Size.
Referenced by PciBus::initialise(), and PciBus::readConfigSpace().
Here is the caller graph for this function:
|
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 |
Implements IoBase.
Definition at line 57 of file x86_common/IoPort.cc.
References Processor::halt().
|
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 |
Implements IoBase.
Definition at line 23 of file x86_common/IoPort.cc.
References Processor::halt(), m_IoPort, and m_Size.
Referenced by Rtc::enableRtcUpdates(), Pic::interrupt(), Rtc::read(), Rtc::setIndex(), Pic::spurious(), and Rtc::waitForUpdateCompletion().
Here is the caller graph for this function:
|
virtual |
Get the size of the I/O region in bytes
Implements IoBase.
Definition at line 60 of file IoPort.cc.
References m_Size.
Referenced by allocate(), and IoPortManager::free().
Here is the caller graph for this function:
|
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 |
Implements IoBase.
Definition at line 72 of file x86_common/IoPort.cc.
References Processor::halt(), m_IoPort, and m_Size.
|
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 |
Implements IoBase.
Definition at line 81 of file x86_common/IoPort.cc.
References Processor::halt(), m_IoPort, and m_Size.
Referenced by PciBus::initialise(), PciBus::readConfigSpace(), and PciBus::writeConfigSpace().
Here is the caller graph for this function:
|
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 |
Implements IoBase.
Definition at line 91 of file x86_common/IoPort.cc.
References Processor::halt().
|
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 |
Implements IoBase.
Definition at line 63 of file x86_common/IoPort.cc.
References Processor::halt(), m_IoPort, and m_Size.
Referenced by Rtc::enableRtcUpdates(), Pit::initialise(), Pic::initialise(), X86IsaDma::initTransfer(), Pic::interrupt(), PciAtaController::PciAtaController(), Rtc::setIndex(), Pic::spurious(), and Rtc::write().
Here is the caller graph for this function:
|
private |
|
private |
|
private |
1.8.11