Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.
This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at http://opensource.org/licenses/bsd-license.php.
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
Reads a 16-bit I/O port.
Reads the 16-bit I/O port specified by Port. The 16-bit read value is returned. This function must guarantee that all I/O read and write operations are serialized.
If Port is not aligned on a 16-bit boundary, then ASSERT().
If 16-bit I/O port operations are not supported, then ASSERT().
Port | The I/O port to read. |
References ASSERT, IoReadWorker(), and SMM_IO_UINT16.
Referenced by IoAnd16(), IoAndThenOr16(), IoBitFieldAnd16(), IoBitFieldAndThenOr16(), IoBitFieldOr16(), IoBitFieldRead16(), IoBitFieldWrite16(), IoOr16(), PciCf8Read16(), and S3IoRead16().
Reads a 32-bit I/O port.
Reads the 32-bit I/O port specified by Port. The 32-bit read value is returned. This function must guarantee that all I/O read and write operations are serialized.
If Port is not aligned on a 32-bit boundary, then ASSERT().
If 32-bit I/O port operations are not supported, then ASSERT().
Port | The I/O port to read. |
References ASSERT, IoReadWorker(), and SMM_IO_UINT32.
Referenced by IoAnd32(), IoAndThenOr32(), IoBitFieldAnd32(), IoBitFieldAndThenOr32(), IoBitFieldOr32(), IoBitFieldRead32(), IoBitFieldWrite32(), IoOr32(), PciCf8And16(), PciCf8And32(), PciCf8And8(), PciCf8AndThenOr16(), PciCf8AndThenOr32(), PciCf8AndThenOr8(), PciCf8BitFieldAnd16(), PciCf8BitFieldAnd32(), PciCf8BitFieldAnd8(), PciCf8BitFieldAndThenOr16(), PciCf8BitFieldAndThenOr32(), PciCf8BitFieldAndThenOr8(), PciCf8BitFieldOr16(), PciCf8BitFieldOr32(), PciCf8BitFieldOr8(), PciCf8BitFieldRead16(), PciCf8BitFieldRead32(), PciCf8BitFieldRead8(), PciCf8BitFieldWrite16(), PciCf8BitFieldWrite32(), PciCf8BitFieldWrite8(), PciCf8Or16(), PciCf8Or32(), PciCf8Or8(), PciCf8Read16(), PciCf8Read32(), PciCf8Read8(), PciCf8Write16(), PciCf8Write32(), PciCf8Write8(), and S3IoRead32().
Reads a 64-bit I/O port.
Reads the 64-bit I/O port specified by Port. The 64-bit read value is returned. This function must guarantee that all I/O read and write operations are serialized.
If Port is not aligned on a 64-bit boundary, then ASSERT().
If 64-bit I/O port operations are not supported, then ASSERT().
Port | The I/O port to read. |
References ASSERT, IoReadWorker(), and SMM_IO_UINT64.
Referenced by IoAnd64(), IoAndThenOr64(), IoBitFieldAnd64(), IoBitFieldAndThenOr64(), IoBitFieldOr64(), IoBitFieldRead64(), IoBitFieldWrite64(), IoOr64(), and S3IoRead64().
Reads an 8-bit I/O port.
Reads the 8-bit I/O port specified by Port. The 8-bit read value is returned. This function must guarantee that all I/O read and write operations are serialized.
If 8-bit I/O port operations are not supported, then ASSERT().
Port | The I/O port to read. |
References IoReadWorker(), and SMM_IO_UINT8.
Referenced by IoAnd8(), IoAndThenOr8(), IoBitFieldAnd8(), IoBitFieldAndThenOr8(), IoBitFieldOr8(), IoBitFieldRead8(), IoBitFieldWrite8(), IoOr8(), PciCf8Read8(), and S3IoRead8().
UINT64 EFIAPI IoReadWorker | ( | IN UINTN | Port, | |
IN EFI_SMM_IO_WIDTH | Width | |||
) |
Reads registers in the EFI CPU I/O space.
Reads the I/O port specified by Port with registers width specified by Width. The read value is returned. If such operations are not supported, then ASSERT(). This function must guarantee that all I/O read and write operations are serialized.
Port | The base address of the I/O operation. The caller is responsible for aligning the Address if required. | |
Width | The width of the I/O operation. |
References ASSERT_EFI_ERROR, gSmst, _EFI_SMM_CPU_IO2_PROTOCOL::Io, EFI_SMM_IO_ACCESS2::Read, and _EFI_SMM_SYSTEM_TABLE2::SmmIo.
Writes a 16-bit I/O port.
Writes the 16-bit I/O port specified by Port with the value specified by Value and returns Value. This function must guarantee that all I/O read and write operations are serialized.
If Port is not aligned on a 16-bit boundary, then ASSERT().
If 16-bit I/O port operations are not supported, then ASSERT().
Port | The I/O port to write. | |
Value | The value to write to the I/O port. |
References ASSERT, IoWriteWorker(), and SMM_IO_UINT16.
Referenced by IoAnd16(), IoAndThenOr16(), IoBitFieldAnd16(), IoBitFieldAndThenOr16(), IoBitFieldOr16(), IoBitFieldWrite16(), IoOr16(), PciCf8Write16(), and S3IoWrite16().
Writes a 32-bit I/O port.
Writes the 32-bit I/O port specified by Port with the value specified by Value and returns Value. This function must guarantee that all I/O read and write operations are serialized.
If Port is not aligned on a 32-bit boundary, then ASSERT().
If 32-bit I/O port operations are not supported, then ASSERT().
Port | The I/O port to write. | |
Value | The value to write to the I/O port. |
References ASSERT, IoWriteWorker(), and SMM_IO_UINT32.
Referenced by IoAnd32(), IoAndThenOr32(), IoBitFieldAnd32(), IoBitFieldAndThenOr32(), IoBitFieldOr32(), IoBitFieldWrite32(), IoOr32(), PciCf8And16(), PciCf8And32(), PciCf8And8(), PciCf8AndThenOr16(), PciCf8AndThenOr32(), PciCf8AndThenOr8(), PciCf8BitFieldAnd16(), PciCf8BitFieldAnd32(), PciCf8BitFieldAnd8(), PciCf8BitFieldAndThenOr16(), PciCf8BitFieldAndThenOr32(), PciCf8BitFieldAndThenOr8(), PciCf8BitFieldOr16(), PciCf8BitFieldOr32(), PciCf8BitFieldOr8(), PciCf8BitFieldRead16(), PciCf8BitFieldRead32(), PciCf8BitFieldRead8(), PciCf8BitFieldWrite16(), PciCf8BitFieldWrite32(), PciCf8BitFieldWrite8(), PciCf8Or16(), PciCf8Or32(), PciCf8Or8(), PciCf8Read16(), PciCf8Read32(), PciCf8Read8(), PciCf8Write16(), PciCf8Write32(), PciCf8Write8(), and S3IoWrite32().
Writes a 64-bit I/O port.
Writes the 64-bit I/O port specified by Port with the value specified by Value and returns Value. This function must guarantee that all I/O read and write operations are serialized.
If Port is not aligned on a 64-bit boundary, then ASSERT().
If 64-bit I/O port operations are not supported, then ASSERT().
Port | The I/O port to write. | |
Value | The value to write to the I/O port. |
References ASSERT, IoWriteWorker(), and SMM_IO_UINT64.
Referenced by IoAnd64(), IoAndThenOr64(), IoBitFieldAnd64(), IoBitFieldAndThenOr64(), IoBitFieldOr64(), IoBitFieldWrite64(), IoOr64(), and S3IoWrite64().
Writes an 8-bit I/O port.
Writes the 8-bit I/O port specified by Port with the value specified by Value and returns Value. This function must guarantee that all I/O read and write operations are serialized.
If 8-bit I/O port operations are not supported, then ASSERT().
Port | The I/O port to write. | |
Value | The value to write to the I/O port. |
References IoWriteWorker(), and SMM_IO_UINT8.
Referenced by IoAnd8(), IoAndThenOr8(), IoBitFieldAnd8(), IoBitFieldAndThenOr8(), IoBitFieldOr8(), IoBitFieldWrite8(), IoOr8(), PciCf8Write8(), PostCode(), PostCodeWithDescription(), and S3IoWrite8().
UINT64 EFIAPI IoWriteWorker | ( | IN UINTN | Port, | |
IN EFI_SMM_IO_WIDTH | Width, | |||
IN UINT64 | Data | |||
) |
Writes registers in the EFI CPU I/O space.
Writes the I/O port specified by Port with registers width and value specified by Width and Data respectively. Data is returned. If such operations are not supported, then ASSERT(). This function must guarantee that all I/O read and write operations are serialized.
Port | The base address of the I/O operation. The caller is responsible for aligning the Address if required. | |
Width | The width of the I/O operation. | |
Data | The value to write to the I/O port. |
References ASSERT_EFI_ERROR, gSmst, _EFI_SMM_CPU_IO2_PROTOCOL::Io, _EFI_SMM_SYSTEM_TABLE2::SmmIo, and EFI_SMM_IO_ACCESS2::Write.
Reads a 16-bit MMIO register.
Reads the 16-bit MMIO register specified by Address. The 16-bit read value is returned. This function must guarantee that all MMIO read and write operations are serialized.
If Address is not aligned on a 16-bit boundary, then ASSERT().
If 16-bit MMIO register operations are not supported, then ASSERT().
Address | The MMIO register to read. |
References ASSERT, MmioReadWorker(), and SMM_IO_UINT16.
Referenced by IoRead16(), MmioAnd16(), MmioAndThenOr16(), MmioBitFieldAnd16(), MmioBitFieldAndThenOr16(), MmioBitFieldOr16(), MmioBitFieldRead16(), MmioBitFieldWrite16(), MmioOr16(), MmioReadBuffer16(), PciExpressRead16(), and S3MmioRead16().
Reads a 32-bit MMIO register.
Reads the 32-bit MMIO register specified by Address. The 32-bit read value is returned. This function must guarantee that all MMIO read and write operations are serialized.
If Address is not aligned on a 32-bit boundary, then ASSERT().
If 32-bit MMIO register operations are not supported, then ASSERT().
Address | The MMIO register to read. |
References ASSERT, MmioReadWorker(), and SMM_IO_UINT32.
Referenced by InternalX86GetInitTimerCount(), InternalX86GetTimerTick(), IoRead32(), MmioAnd32(), MmioAndThenOr32(), MmioBitFieldAnd32(), MmioBitFieldAndThenOr32(), MmioBitFieldOr32(), MmioBitFieldRead32(), MmioBitFieldWrite32(), MmioOr32(), MmioReadBuffer32(), PciExpressRead32(), and S3MmioRead32().
Reads a 64-bit MMIO register.
Reads the 64-bit MMIO register specified by Address. The 64-bit read value is returned. This function must guarantee that all MMIO read and write operations are serialized.
If Address is not aligned on a 64-bit boundary, then ASSERT().
If 64-bit MMIO register operations are not supported, then ASSERT().
Address | The MMIO register to read. |
References ASSERT, MmioReadWorker(), and SMM_IO_UINT64.
Referenced by MmioAnd64(), MmioAndThenOr64(), MmioBitFieldAnd64(), MmioBitFieldAndThenOr64(), MmioBitFieldOr64(), MmioBitFieldRead64(), MmioBitFieldWrite64(), MmioOr64(), MmioReadBuffer64(), and S3MmioRead64().
Reads an 8-bit MMIO register.
Reads the 8-bit MMIO register specified by Address. The 8-bit read value is returned. This function must guarantee that all MMIO read and write operations are serialized.
If 8-bit MMIO register operations are not supported, then ASSERT().
Address | The MMIO register to read. |
References MmioReadWorker(), and SMM_IO_UINT8.
Referenced by IoRead8(), MmioAnd8(), MmioAndThenOr8(), MmioBitFieldAnd8(), MmioBitFieldAndThenOr8(), MmioBitFieldOr8(), MmioBitFieldRead8(), MmioBitFieldWrite8(), MmioOr8(), MmioReadBuffer8(), PciExpressRead8(), and S3MmioRead8().
UINT64 EFIAPI MmioReadWorker | ( | IN UINTN | Address, | |
IN EFI_SMM_IO_WIDTH | Width | |||
) |
Reads memory-mapped registers in the EFI system memory space.
Reads the MMIO registers specified by Address with registers width specified by Width. The read value is returned. If such operations are not supported, then ASSERT(). This function must guarantee that all MMIO read and write operations are serialized.
Address | The MMIO register to read. The caller is responsible for aligning the Address if required. | |
Width | The width of the I/O operation. |
References ASSERT_EFI_ERROR, gSmst, _EFI_SMM_CPU_IO2_PROTOCOL::Mem, EFI_SMM_IO_ACCESS2::Read, and _EFI_SMM_SYSTEM_TABLE2::SmmIo.
Writes a 16-bit MMIO register.
Writes the 16-bit MMIO register specified by Address with the value specified by Value and returns Value. This function must guarantee that all MMIO read and write operations are serialized.
If Address is not aligned on a 16-bit boundary, then ASSERT().
If 16-bit MMIO register operations are not supported, then ASSERT().
Address | The MMIO register to write. | |
Value | The value to write to the MMIO register. |
References ASSERT, MmioWriteWorker(), and SMM_IO_UINT16.
Referenced by IoWrite16(), MmioAnd16(), MmioAndThenOr16(), MmioBitFieldAnd16(), MmioBitFieldAndThenOr16(), MmioBitFieldOr16(), MmioBitFieldWrite16(), MmioOr16(), MmioWriteBuffer16(), PciExpressWrite16(), and S3MmioWrite16().
Writes a 32-bit MMIO register.
Writes the 32-bit MMIO register specified by Address with the value specified by Value and returns Value. This function must guarantee that all MMIO read and write operations are serialized.
If Address is not aligned on a 32-bit boundary, then ASSERT().
If 32-bit MMIO register operations are not supported, then ASSERT().
Address | The MMIO register to write. | |
Value | The value to write to the MMIO register. |
References ASSERT, MmioWriteWorker(), and SMM_IO_UINT32.
Referenced by IoWrite32(), MmioAnd32(), MmioAndThenOr32(), MmioBitFieldAnd32(), MmioBitFieldAndThenOr32(), MmioBitFieldOr32(), MmioBitFieldWrite32(), MmioOr32(), MmioWriteBuffer32(), PciExpressWrite32(), and S3MmioWrite32().
Writes a 64-bit MMIO register.
Writes the 64-bit MMIO register specified by Address with the value specified by Value and returns Value. This function must guarantee that all MMIO read and write operations are serialized.
If Address is not aligned on a 64-bit boundary, then ASSERT().
If 64-bit MMIO register operations are not supported, then ASSERT().
Address | The MMIO register to write. | |
Value | The value to write to the MMIO register. |
References ASSERT, MmioWriteWorker(), and SMM_IO_UINT64.
Referenced by MmioAnd64(), MmioAndThenOr64(), MmioBitFieldAnd64(), MmioBitFieldAndThenOr64(), MmioBitFieldOr64(), MmioBitFieldWrite64(), MmioOr64(), MmioWriteBuffer64(), and S3MmioWrite64().
Writes an 8-bit MMIO register.
Writes the 8-bit MMIO register specified by Address with the value specified by Value and returns Value. This function must guarantee that all MMIO read and write operations are serialized.
If 8-bit MMIO register operations are not supported, then ASSERT().
Address | The MMIO register to write. | |
Value | The value to write to the MMIO register. |
References MmioWriteWorker(), and SMM_IO_UINT8.
Referenced by IoWrite8(), MmioAnd8(), MmioAndThenOr8(), MmioBitFieldAnd8(), MmioBitFieldAndThenOr8(), MmioBitFieldOr8(), MmioBitFieldWrite8(), MmioOr8(), MmioWriteBuffer8(), PciExpressWrite8(), and S3MmioWrite8().
UINT64 EFIAPI MmioWriteWorker | ( | IN UINTN | Address, | |
IN EFI_SMM_IO_WIDTH | Width, | |||
IN UINT64 | Data | |||
) |
Writes memory-mapped registers in the EFI system memory space.
Writes the MMIO registers specified by Address with registers width and value specified by Width and Data respectively. Data is returned. If such operations are not supported, then ASSERT(). This function must guarantee that all MMIO read and write operations are serialized.
Address | The MMIO register to read. The caller is responsible for aligning the Address if required. | |
Width | The width of the I/O operation. | |
Data | The value to write to the I/O port. |
References ASSERT_EFI_ERROR, gSmst, _EFI_SMM_CPU_IO2_PROTOCOL::Mem, _EFI_SMM_SYSTEM_TABLE2::SmmIo, and EFI_SMM_IO_ACCESS2::Write.