4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/** @file
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync High-level Io/Mmio functions.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync All assertions for bit field operations are handled bit field functions in the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Base Library.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Copyright (c) 2010, Intel Corporation. All rights reserved.<BR>
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync This program and the accompanying materials are licensed and made available
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync under the terms and conditions of the BSD License which accompanies this
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync distribution. The full text of the license may be found at
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync http://opensource.org/licenses/bsd-license.php.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync#include "DxeCpuIo2LibInternal.h"
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads an 8-bit I/O port, performs a bitwise OR, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result back to the 8-bit I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 8-bit I/O port specified by Port, performs a bitwise OR
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by OrData, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result to the 8-bit I/O port specified by Port. The value written to the I/O
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync port is returned. This function must guarantee that all I/O read and write
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 8-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT8
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoOr8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite8 (Port, (UINT8) (IoRead8 (Port) | OrData));
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads an 8-bit I/O port, performs a bitwise AND, and writes the result back
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync to the 8-bit I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 8-bit I/O port specified by Port, performs a bitwise AND between
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the read result and the value specified by AndData, and writes the result to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the 8-bit I/O port specified by Port. The value written to the I/O port is
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync returned. This function must guarantee that all I/O read and write operations
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 8-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT8
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoAnd8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 AndData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite8 (Port, (UINT8) (IoRead8 (Port) & AndData));
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads an 8-bit I/O port, performs a bitwise AND followed by a bitwise
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync inclusive OR, and writes the result back to the 8-bit I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 8-bit I/O port specified by Port, performs a bitwise AND between
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the read result and the value specified by AndData, performs a bitwise OR
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the result of the AND operation and the value specified by OrData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync and writes the result to the 8-bit I/O port specified by Port. The value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync written to the I/O port is returned. This function must guarantee that all
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync I/O read and write operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 8-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the result of the AND operation.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT8
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoAndThenOr8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 AndData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite8 (Port, (UINT8) ((IoRead8 (Port) & AndData) | OrData));
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field of an I/O register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the bit field in an 8-bit I/O register. The bit field is specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the StartBit and the EndBit. The value of the bit field is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 8-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT8
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldRead8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return BitFieldRead8 (IoRead8 (Port), StartBit, EndBit);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Writes a bit field to an I/O register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Writes Value to the bit field of the I/O register. The bit field is specified
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync by the StartBit and the EndBit. All other bits in the destination I/O
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync register are preserved. The value written to the I/O port is returned. Extra
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync left bits in Value are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 8-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Value The new value of the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT8
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldWrite8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 Value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldWrite8 (IoRead8 (Port), StartBit, EndBit, Value)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in an 8-bit port, performs a bitwise OR, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result back to the bit field in the 8-bit port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 8-bit I/O port specified by Port, performs a bitwise OR
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by OrData, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result to the 8-bit I/O port specified by Port. The value written to the I/O
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync port is returned. This function must guarantee that all I/O read and write
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync operations are serialized. Extra left bits in OrData are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 8-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT8
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldOr8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldOr8 (IoRead8 (Port), StartBit, EndBit, OrData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in an 8-bit port, performs a bitwise AND, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result back to the bit field in the 8-bit port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 8-bit I/O port specified by Port, performs a bitwise AND between
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the read result and the value specified by AndData, and writes the result to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the 8-bit I/O port specified by Port. The value written to the I/O port is
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync returned. This function must guarantee that all I/O read and write operations
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync are serialized. Extra left bits in AndData are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 8-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT8
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldAnd8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 AndData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldAnd8 (IoRead8 (Port), StartBit, EndBit, AndData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in an 8-bit port, performs a bitwise AND followed by a
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync bitwise OR, and writes the result back to the bit field in the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync 8-bit port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 8-bit I/O port specified by Port, performs a bitwise AND followed
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync by a bitwise OR between the read result and the value specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync AndData, and writes the result to the 8-bit I/O port specified by Port. The
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync value written to the I/O port is returned. This function must guarantee that
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync all I/O read and write operations are serialized. Extra left bits in both
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync AndData and OrData are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 8-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the result of the AND operation.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT8
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldAndThenOr8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 AndData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldAndThenOr8 (IoRead8 (Port), StartBit, EndBit, AndData, OrData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 16-bit I/O port, performs a bitwise OR, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result back to the 16-bit I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 16-bit I/O port specified by Port, performs a bitwise OR
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by OrData, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result to the 16-bit I/O port specified by Port. The value written to the I/O
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync port is returned. This function must guarantee that all I/O read and write
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 16-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT16
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoOr16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite16 (Port, (UINT16) (IoRead16 (Port) | OrData));
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 16-bit I/O port, performs a bitwise AND, and writes the result back
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync to the 16-bit I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 16-bit I/O port specified by Port, performs a bitwise AND between
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the read result and the value specified by AndData, and writes the result to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the 16-bit I/O port specified by Port. The value written to the I/O port is
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync returned. This function must guarantee that all I/O read and write operations
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 16-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT16
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoAnd16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 AndData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite16 (Port, (UINT16) (IoRead16 (Port) & AndData));
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 16-bit I/O port, performs a bitwise AND followed by a bitwise
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync inclusive OR, and writes the result back to the 16-bit I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 16-bit I/O port specified by Port, performs a bitwise AND between
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the read result and the value specified by AndData, performs a bitwise OR
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the result of the AND operation and the value specified by OrData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync and writes the result to the 16-bit I/O port specified by Port. The value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync written to the I/O port is returned. This function must guarantee that all
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync I/O read and write operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 16-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the result of the AND operation.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT16
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoAndThenOr16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 AndData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite16 (Port, (UINT16) ((IoRead16 (Port) & AndData) | OrData));
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field of an I/O register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the bit field in a 16-bit I/O register. The bit field is specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the StartBit and the EndBit. The value of the bit field is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 16-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT16
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldRead16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return BitFieldRead16 (IoRead16 (Port), StartBit, EndBit);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Writes a bit field to an I/O register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Writes Value to the bit field of the I/O register. The bit field is specified
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync by the StartBit and the EndBit. All other bits in the destination I/O
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync register are preserved. The value written to the I/O port is returned. Extra
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync left bits in Value are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 16-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Value The new value of the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT16
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldWrite16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 Value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldWrite16 (IoRead16 (Port), StartBit, EndBit, Value)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 16-bit port, performs a bitwise OR, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result back to the bit field in the 16-bit port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 16-bit I/O port specified by Port, performs a bitwise OR
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by OrData, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result to the 16-bit I/O port specified by Port. The value written to the I/O
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync port is returned. This function must guarantee that all I/O read and write
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync operations are serialized. Extra left bits in OrData are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 16-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT16
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldOr16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldOr16 (IoRead16 (Port), StartBit, EndBit, OrData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 16-bit port, performs a bitwise AND, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result back to the bit field in the 16-bit port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 16-bit I/O port specified by Port, performs a bitwise AND between
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the read result and the value specified by AndData, and writes the result to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the 16-bit I/O port specified by Port. The value written to the I/O port is
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync returned. This function must guarantee that all I/O read and write operations
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync are serialized. Extra left bits in AndData are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 16-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT16
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldAnd16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 AndData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldAnd16 (IoRead16 (Port), StartBit, EndBit, AndData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 16-bit port, performs a bitwise AND followed by a
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync bitwise OR, and writes the result back to the bit field in the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync 16-bit port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 16-bit I/O port specified by Port, performs a bitwise AND followed
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync by a bitwise OR between the read result and the value specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync AndData, and writes the result to the 16-bit I/O port specified by Port. The
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync value written to the I/O port is returned. This function must guarantee that
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync all I/O read and write operations are serialized. Extra left bits in both
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync AndData and OrData are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 16-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the result of the AND operation.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT16
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldAndThenOr16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 AndData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldAndThenOr16 (IoRead16 (Port), StartBit, EndBit, AndData, OrData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 32-bit I/O port, performs a bitwise OR, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result back to the 32-bit I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 32-bit I/O port specified by Port, performs a bitwise OR
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by OrData, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result to the 32-bit I/O port specified by Port. The value written to the I/O
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync port is returned. This function must guarantee that all I/O read and write
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 32-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT32
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoOr32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite32 (Port, IoRead32 (Port) | OrData);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 32-bit I/O port, performs a bitwise AND, and writes the result back
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync to the 32-bit I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 32-bit I/O port specified by Port, performs a bitwise AND between
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the read result and the value specified by AndData, and writes the result to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the 32-bit I/O port specified by Port. The value written to the I/O port is
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync returned. This function must guarantee that all I/O read and write operations
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 32-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT32
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoAnd32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 AndData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite32 (Port, IoRead32 (Port) & AndData);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 32-bit I/O port, performs a bitwise AND followed by a bitwise
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync inclusive OR, and writes the result back to the 32-bit I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 32-bit I/O port specified by Port, performs a bitwise AND between
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the read result and the value specified by AndData, performs a bitwise OR
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the result of the AND operation and the value specified by OrData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync and writes the result to the 32-bit I/O port specified by Port. The value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync written to the I/O port is returned. This function must guarantee that all
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync I/O read and write operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 32-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the result of the AND operation.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT32
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoAndThenOr32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 AndData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite32 (Port, (IoRead32 (Port) & AndData) | OrData);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field of an I/O register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the bit field in a 32-bit I/O register. The bit field is specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the StartBit and the EndBit. The value of the bit field is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 32-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT32
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldRead32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return BitFieldRead32 (IoRead32 (Port), StartBit, EndBit);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Writes a bit field to an I/O register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Writes Value to the bit field of the I/O register. The bit field is specified
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync by the StartBit and the EndBit. All other bits in the destination I/O
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync register are preserved. The value written to the I/O port is returned. Extra
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync left bits in Value are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 32-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Value The new value of the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT32
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldWrite32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 Value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldWrite32 (IoRead32 (Port), StartBit, EndBit, Value)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 32-bit port, performs a bitwise OR, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result back to the bit field in the 32-bit port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 32-bit I/O port specified by Port, performs a bitwise OR
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by OrData, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result to the 32-bit I/O port specified by Port. The value written to the I/O
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync port is returned. This function must guarantee that all I/O read and write
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync operations are serialized. Extra left bits in OrData are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 32-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT32
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldOr32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldOr32 (IoRead32 (Port), StartBit, EndBit, OrData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 32-bit port, performs a bitwise AND, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result back to the bit field in the 32-bit port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 32-bit I/O port specified by Port, performs a bitwise AND between
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the read result and the value specified by AndData, and writes the result to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the 32-bit I/O port specified by Port. The value written to the I/O port is
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync returned. This function must guarantee that all I/O read and write operations
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync are serialized. Extra left bits in AndData are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 32-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT32
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldAnd32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 AndData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldAnd32 (IoRead32 (Port), StartBit, EndBit, AndData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 32-bit port, performs a bitwise AND followed by a
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync bitwise OR, and writes the result back to the bit field in the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync 32-bit port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 32-bit I/O port specified by Port, performs a bitwise AND followed
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync by a bitwise OR between the read result and the value specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync AndData, and writes the result to the 32-bit I/O port specified by Port. The
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync value written to the I/O port is returned. This function must guarantee that
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync all I/O read and write operations are serialized. Extra left bits in both
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync AndData and OrData are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 32-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the result of the AND operation.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT32
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldAndThenOr32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 AndData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldAndThenOr32 (IoRead32 (Port), StartBit, EndBit, AndData, OrData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 64-bit I/O port, performs a bitwise OR, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result back to the 64-bit I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 64-bit I/O port specified by Port, performs a bitwise OR
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by OrData, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result to the 64-bit I/O port specified by Port. The value written to the I/O
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync port is returned. This function must guarantee that all I/O read and write
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 64-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT64
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoOr64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite64 (Port, IoRead64 (Port) | OrData);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 64-bit I/O port, performs a bitwise AND, and writes the result back
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync to the 64-bit I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 64-bit I/O port specified by Port, performs a bitwise AND between
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the read result and the value specified by AndData, and writes the result to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the 64-bit I/O port specified by Port. The value written to the I/O port is
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync returned. This function must guarantee that all I/O read and write operations
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 64-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT64
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoAnd64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 AndData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite64 (Port, IoRead64 (Port) & AndData);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 64-bit I/O port, performs a bitwise AND followed by a bitwise
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync inclusive OR, and writes the result back to the 64-bit I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 64-bit I/O port specified by Port, performs a bitwise AND between
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the read result and the value specified by AndData, performs a bitwise OR
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the result of the AND operation and the value specified by OrData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync and writes the result to the 64-bit I/O port specified by Port. The value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync written to the I/O port is returned. This function must guarantee that all
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync I/O read and write operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 64-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the result of the AND operation.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT64
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoAndThenOr64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 AndData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite64 (Port, (IoRead64 (Port) & AndData) | OrData);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field of an I/O register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the bit field in a 64-bit I/O register. The bit field is specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the StartBit and the EndBit. The value of the bit field is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 64-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT64
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldRead64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return BitFieldRead64 (IoRead64 (Port), StartBit, EndBit);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Writes a bit field to an I/O register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Writes Value to the bit field of the I/O register. The bit field is specified
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync by the StartBit and the EndBit. All other bits in the destination I/O
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync register are preserved. The value written to the I/O port is returned. Extra
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync left bits in Value are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 64-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Value The new value of the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT64
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldWrite64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 Value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldWrite64 (IoRead64 (Port), StartBit, EndBit, Value)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 64-bit port, performs a bitwise OR, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result back to the bit field in the 64-bit port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 64-bit I/O port specified by Port, performs a bitwise OR
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by OrData, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result to the 64-bit I/O port specified by Port. The value written to the I/O
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync port is returned. This function must guarantee that all I/O read and write
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync operations are serialized. Extra left bits in OrData are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 64-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT64
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldOr64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldOr64 (IoRead64 (Port), StartBit, EndBit, OrData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 64-bit port, performs a bitwise AND, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result back to the bit field in the 64-bit port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 64-bit I/O port specified by Port, performs a bitwise AND between
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the read result and the value specified by AndData, and writes the result to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the 64-bit I/O port specified by Port. The value written to the I/O port is
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync returned. This function must guarantee that all I/O read and write operations
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync are serialized. Extra left bits in AndData are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 64-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT64
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldAnd64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 AndData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldAnd64 (IoRead64 (Port), StartBit, EndBit, AndData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 64-bit port, performs a bitwise AND followed by a
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync bitwise OR, and writes the result back to the bit field in the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync 64-bit port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 64-bit I/O port specified by Port, performs a bitwise AND followed
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync by a bitwise OR between the read result and the value specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync AndData, and writes the result to the 64-bit I/O port specified by Port. The
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync value written to the I/O port is returned. This function must guarantee that
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync all I/O read and write operations are serialized. Extra left bits in both
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync AndData and OrData are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 64-bit I/O port operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Port The I/O port to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the result of the AND operation.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the I/O port.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT64
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncIoBitFieldAndThenOr64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 AndData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return IoWrite64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Port,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldAndThenOr64 (IoRead64 (Port), StartBit, EndBit, AndData, OrData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads an 8-bit MMIO register, performs a bitwise OR, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result back to the 8-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 8-bit MMIO register specified by Address, performs a bitwise
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync inclusive OR between the read result and the value specified by OrData, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync writes the result to the 8-bit MMIO register specified by Address. The value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync written to the MMIO register is returned. This function must guarantee that
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync all MMIO read and write operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 8-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT8
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioOr8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite8 (Address, (UINT8) (MmioRead8 (Address) | OrData));
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads an 8-bit MMIO register, performs a bitwise AND, and writes the result
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync back to the 8-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 8-bit MMIO register specified by Address, performs a bitwise AND
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by AndData, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result to the 8-bit MMIO register specified by Address. The value written to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the MMIO register is returned. This function must guarantee that all MMIO
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync read and write operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 8-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT8
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioAnd8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 AndData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite8 (Address, (UINT8) (MmioRead8 (Address) & AndData));
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads an 8-bit MMIO register, performs a bitwise AND followed by a bitwise
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync inclusive OR, and writes the result back to the 8-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 8-bit MMIO register specified by Address, performs a bitwise AND
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by AndData, performs a
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync bitwise OR between the result of the AND operation and the value specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync OrData, and writes the result to the 8-bit MMIO register specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address. The value written to the MMIO register is returned. This function
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync must guarantee that all MMIO read and write operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 8-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the result of the AND operation.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT8
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioAndThenOr8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 AndData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite8 (Address, (UINT8) ((MmioRead8 (Address) & AndData) | OrData));
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field of a MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the bit field in an 8-bit MMIO register. The bit field is specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the StartBit and the EndBit. The value of the bit field is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 8-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT8
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldRead8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return BitFieldRead8 (MmioRead8 (Address), StartBit, EndBit);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Writes a bit field to a MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Writes Value to the bit field of the MMIO register. The bit field is
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync specified by the StartBit and the EndBit. All other bits in the destination
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync MMIO register are preserved. The new value of the 8-bit register is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 8-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Value The new value of the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT8
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldWrite8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 Value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldWrite8 (MmioRead8 (Address), StartBit, EndBit, Value)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in an 8-bit MMIO register, performs a bitwise OR, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync writes the result back to the bit field in the 8-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 8-bit MMIO register specified by Address, performs a bitwise
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync inclusive OR between the read result and the value specified by OrData, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync writes the result to the 8-bit MMIO register specified by Address. The value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync written to the MMIO register is returned. This function must guarantee that
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync all MMIO read and write operations are serialized. Extra left bits in OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 8-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT8
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldOr8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldOr8 (MmioRead8 (Address), StartBit, EndBit, OrData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in an 8-bit MMIO register, performs a bitwise AND, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync writes the result back to the bit field in the 8-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 8-bit MMIO register specified by Address, performs a bitwise AND
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by AndData, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result to the 8-bit MMIO register specified by Address. The value written to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the MMIO register is returned. This function must guarantee that all MMIO
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync read and write operations are serialized. Extra left bits in AndData are
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 8-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT8
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldAnd8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 AndData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldAnd8 (MmioRead8 (Address), StartBit, EndBit, AndData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in an 8-bit MMIO register, performs a bitwise AND followed
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync by a bitwise OR, and writes the result back to the bit field in the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync 8-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 8-bit MMIO register specified by Address, performs a bitwise AND
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync followed by a bitwise OR between the read result and the value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync specified by AndData, and writes the result to the 8-bit MMIO register
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync specified by Address. The value written to the MMIO register is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync This function must guarantee that all MMIO read and write operations are
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync serialized. Extra left bits in both AndData and OrData are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 8-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 7, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..7.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the result of the AND operation.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT8
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldAndThenOr8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 AndData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT8 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite8 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldAndThenOr8 (MmioRead8 (Address), StartBit, EndBit, AndData, OrData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 16-bit MMIO register, performs a bitwise OR, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result back to the 16-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 16-bit MMIO register specified by Address, performs a bitwise
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync inclusive OR between the read result and the value specified by OrData, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync writes the result to the 16-bit MMIO register specified by Address. The value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync written to the MMIO register is returned. This function must guarantee that
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync all MMIO read and write operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 16-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT16
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioOr16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite16 (Address, (UINT16) (MmioRead16 (Address) | OrData));
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 16-bit MMIO register, performs a bitwise AND, and writes the result
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync back to the 16-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 16-bit MMIO register specified by Address, performs a bitwise AND
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by AndData, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result to the 16-bit MMIO register specified by Address. The value written to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the MMIO register is returned. This function must guarantee that all MMIO
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync read and write operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 16-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT16
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioAnd16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 AndData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite16 (Address, (UINT16) (MmioRead16 (Address) & AndData));
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 16-bit MMIO register, performs a bitwise AND followed by a bitwise
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync inclusive OR, and writes the result back to the 16-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 16-bit MMIO register specified by Address, performs a bitwise AND
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by AndData, performs a
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync bitwise OR between the result of the AND operation and the value specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync OrData, and writes the result to the 16-bit MMIO register specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address. The value written to the MMIO register is returned. This function
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync must guarantee that all MMIO read and write operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 16-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the result of the AND operation.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT16
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioAndThenOr16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 AndData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite16 (Address, (UINT16) ((MmioRead16 (Address) & AndData) | OrData));
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field of a MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the bit field in a 16-bit MMIO register. The bit field is specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the StartBit and the EndBit. The value of the bit field is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 16-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT16
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldRead16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return BitFieldRead16 (MmioRead16 (Address), StartBit, EndBit);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Writes a bit field to a MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Writes Value to the bit field of the MMIO register. The bit field is
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync specified by the StartBit and the EndBit. All other bits in the destination
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync MMIO register are preserved. The new value of the 16-bit register is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 16-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Value The new value of the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT16
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldWrite16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 Value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldWrite16 (MmioRead16 (Address), StartBit, EndBit, Value)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 16-bit MMIO register, performs a bitwise OR, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync writes the result back to the bit field in the 16-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 16-bit MMIO register specified by Address, performs a bitwise
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync inclusive OR between the read result and the value specified by OrData, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync writes the result to the 16-bit MMIO register specified by Address. The value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync written to the MMIO register is returned. This function must guarantee that
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync all MMIO read and write operations are serialized. Extra left bits in OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 16-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT16
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldOr16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldOr16 (MmioRead16 (Address), StartBit, EndBit, OrData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 16-bit MMIO register, performs a bitwise AND, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync writes the result back to the bit field in the 16-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 16-bit MMIO register specified by Address, performs a bitwise AND
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by AndData, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result to the 16-bit MMIO register specified by Address. The value written to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the MMIO register is returned. This function must guarantee that all MMIO
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync read and write operations are serialized. Extra left bits in AndData are
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 16-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT16
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldAnd16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 AndData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldAnd16 (MmioRead16 (Address), StartBit, EndBit, AndData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 16-bit MMIO register, performs a bitwise AND followed
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync by a bitwise OR, and writes the result back to the bit field in the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync 16-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 16-bit MMIO register specified by Address, performs a bitwise AND
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync followed by a bitwise OR between the read result and the value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync specified by AndData, and writes the result to the 16-bit MMIO register
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync specified by Address. The value written to the MMIO register is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync This function must guarantee that all MMIO read and write operations are
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync serialized. Extra left bits in both AndData and OrData are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 16-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 15, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..15.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the result of the AND operation.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT16
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldAndThenOr16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 AndData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT16 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite16 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldAndThenOr16 (MmioRead16 (Address), StartBit, EndBit, AndData, OrData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 32-bit MMIO register, performs a bitwise OR, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result back to the 32-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 32-bit MMIO register specified by Address, performs a bitwise
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync inclusive OR between the read result and the value specified by OrData, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync writes the result to the 32-bit MMIO register specified by Address. The value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync written to the MMIO register is returned. This function must guarantee that
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync all MMIO read and write operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 32-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT32
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioOr32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite32 (Address, MmioRead32 (Address) | OrData);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 32-bit MMIO register, performs a bitwise AND, and writes the result
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync back to the 32-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 32-bit MMIO register specified by Address, performs a bitwise AND
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by AndData, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result to the 32-bit MMIO register specified by Address. The value written to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the MMIO register is returned. This function must guarantee that all MMIO
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync read and write operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 32-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT32
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioAnd32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 AndData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite32 (Address, MmioRead32 (Address) & AndData);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 32-bit MMIO register, performs a bitwise AND followed by a bitwise
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync inclusive OR, and writes the result back to the 32-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 32-bit MMIO register specified by Address, performs a bitwise AND
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by AndData, performs a
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync bitwise OR between the result of the AND operation and the value specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync OrData, and writes the result to the 32-bit MMIO register specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address. The value written to the MMIO register is returned. This function
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync must guarantee that all MMIO read and write operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 32-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the result of the AND operation.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT32
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioAndThenOr32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 AndData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite32 (Address, (MmioRead32 (Address) & AndData) | OrData);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field of a MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the bit field in a 32-bit MMIO register. The bit field is specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the StartBit and the EndBit. The value of the bit field is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 32-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT32
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldRead32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return BitFieldRead32 (MmioRead32 (Address), StartBit, EndBit);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Writes a bit field to a MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Writes Value to the bit field of the MMIO register. The bit field is
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync specified by the StartBit and the EndBit. All other bits in the destination
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync MMIO register are preserved. The new value of the 32-bit register is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 32-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Value The new value of the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT32
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldWrite32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 Value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldWrite32 (MmioRead32 (Address), StartBit, EndBit, Value)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 32-bit MMIO register, performs a bitwise OR, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync writes the result back to the bit field in the 32-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 32-bit MMIO register specified by Address, performs a bitwise
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync inclusive OR between the read result and the value specified by OrData, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync writes the result to the 32-bit MMIO register specified by Address. The value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync written to the MMIO register is returned. This function must guarantee that
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync all MMIO read and write operations are serialized. Extra left bits in OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 32-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT32
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldOr32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldOr32 (MmioRead32 (Address), StartBit, EndBit, OrData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 32-bit MMIO register, performs a bitwise AND, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync writes the result back to the bit field in the 32-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 32-bit MMIO register specified by Address, performs a bitwise AND
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by AndData, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result to the 32-bit MMIO register specified by Address. The value written to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the MMIO register is returned. This function must guarantee that all MMIO
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync read and write operations are serialized. Extra left bits in AndData are
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 32-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT32
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldAnd32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 AndData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldAnd32 (MmioRead32 (Address), StartBit, EndBit, AndData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 32-bit MMIO register, performs a bitwise AND followed
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync by a bitwise OR, and writes the result back to the bit field in the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync 32-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 32-bit MMIO register specified by Address, performs a bitwise AND
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync followed by a bitwise OR between the read result and the value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync specified by AndData, and writes the result to the 32-bit MMIO register
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync specified by Address. The value written to the MMIO register is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync This function must guarantee that all MMIO read and write operations are
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync serialized. Extra left bits in both AndData and OrData are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 32-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 31, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..31.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the result of the AND operation.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT32
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldAndThenOr32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 AndData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT32 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite32 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldAndThenOr32 (MmioRead32 (Address), StartBit, EndBit, AndData, OrData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 64-bit MMIO register, performs a bitwise OR, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result back to the 64-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 64-bit MMIO register specified by Address, performs a bitwise
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync inclusive OR between the read result and the value specified by OrData, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync writes the result to the 64-bit MMIO register specified by Address. The value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync written to the MMIO register is returned. This function must guarantee that
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync all MMIO read and write operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 64-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT64
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioOr64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite64 (Address, MmioRead64 (Address) | OrData);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 64-bit MMIO register, performs a bitwise AND, and writes the result
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync back to the 64-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 64-bit MMIO register specified by Address, performs a bitwise AND
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by AndData, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result to the 64-bit MMIO register specified by Address. The value written to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the MMIO register is returned. This function must guarantee that all MMIO
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync read and write operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 64-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT64
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioAnd64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 AndData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite64 (Address, MmioRead64 (Address) & AndData);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a 64-bit MMIO register, performs a bitwise AND followed by a bitwise
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync inclusive OR, and writes the result back to the 64-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 64-bit MMIO register specified by Address, performs a bitwise AND
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by AndData, performs a
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync bitwise OR between the result of the AND operation and the value specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync OrData, and writes the result to the 64-bit MMIO register specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address. The value written to the MMIO register is returned. This function
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync must guarantee that all MMIO read and write operations are serialized.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 64-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with the read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the result of the AND operation.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT64
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioAndThenOr64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 AndData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite64 (Address, (MmioRead64 (Address) & AndData) | OrData);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field of a MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the bit field in a 64-bit MMIO register. The bit field is specified by
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the StartBit and the EndBit. The value of the bit field is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 64-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value read.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT64
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldRead64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return BitFieldRead64 (MmioRead64 (Address), StartBit, EndBit);
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Writes a bit field to a MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Writes Value to the bit field of the MMIO register. The bit field is
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync specified by the StartBit and the EndBit. All other bits in the destination
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync MMIO register are preserved. The new value of the 64-bit register is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 64-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Value The new value of the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT64
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldWrite64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 Value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldWrite64 (MmioRead64 (Address), StartBit, EndBit, Value)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 64-bit MMIO register, performs a bitwise OR, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync writes the result back to the bit field in the 64-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 64-bit MMIO register specified by Address, performs a bitwise
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync inclusive OR between the read result and the value specified by OrData, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync writes the result to the 64-bit MMIO register specified by Address. The value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync written to the MMIO register is returned. This function must guarantee that
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync all MMIO read and write operations are serialized. Extra left bits in OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 64-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT64
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldOr64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldOr64 (MmioRead64 (Address), StartBit, EndBit, OrData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 64-bit MMIO register, performs a bitwise AND, and
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync writes the result back to the bit field in the 64-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 64-bit MMIO register specified by Address, performs a bitwise AND
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync between the read result and the value specified by AndData, and writes the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync result to the 64-bit MMIO register specified by Address. The value written to
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync the MMIO register is returned. This function must guarantee that all MMIO
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync read and write operations are serialized. Extra left bits in AndData are
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 64-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT64
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldAnd64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 AndData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldAnd64 (MmioRead64 (Address), StartBit, EndBit, AndData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync/**
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads a bit field in a 64-bit MMIO register, performs a bitwise AND followed
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync by a bitwise OR, and writes the result back to the bit field in the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync 64-bit MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Reads the 64-bit MMIO register specified by Address, performs a bitwise AND
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync followed by a bitwise OR between the read result and the value
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync specified by AndData, and writes the result to the 64-bit MMIO register
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync specified by Address. The value written to the MMIO register is returned.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync This function must guarantee that all MMIO read and write operations are
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync serialized. Extra left bits in both AndData and OrData are stripped.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If 64-bit MMIO register operations are not supported, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If StartBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is greater than 63, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync If EndBit is less than StartBit, then ASSERT().
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param Address The MMIO register to write.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param StartBit The ordinal of the least significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param EndBit The ordinal of the most significant bit in the bit field.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Range 0..63.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param AndData The value to AND with read value from the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @param OrData The value to OR with the result of the AND operation.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync @return The value written back to the MMIO register.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync**/
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncUINT64
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncEFIAPI
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncMmioBitFieldAndThenOr64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN StartBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINTN EndBit,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 AndData,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync IN UINT64 OrData
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync )
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync{
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync return MmioWrite64 (
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync Address,
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync BitFieldAndThenOr64 (MmioRead64 (Address), StartBit, EndBit, AndData, OrData)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync );
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync}