2 Internal include file of SMM CPU IO Library.
3 It includes all necessary protocol/library class's header file
4 for implementation of IoLib library instance. It is included
5 all source code of this library instance.
7 Copyright (c) 2009, Intel Corporation
8 All rights reserved. This program and the accompanying materials
9 are licensed and made available under the terms and conditions of the BSD License
10 which accompanies this distribution. The full text of the license may be found at
11 http://opensource.org/licenses/bsd-license.php
13 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
14 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
16 Module Name: DxeCpuIoLibInternal.h
20 #ifndef _SMM_CPUIO_LIB_INTERNAL_H_
21 #define _SMM_CPUIO_LIB_INTERNAL_H_
25 #include <Protocol/SmmCpuIo.h>
26 #include <Protocol/SmmPciRootBridgeIo.h>
27 #include <Library/IoLib.h>
28 #include <Library/DebugLib.h>
29 #include <Library/BaseLib.h>
30 #include <Library/SmmServicesTableLib.h>
34 Reads registers in the EFI CPU I/O space.
36 Reads the I/O port specified by Port with registers width specified by Width.
37 The read value is returned. If such operations are not supported, then ASSERT().
38 This function must guarantee that all I/O read and write operations are serialized.
40 @param Port The base address of the I/O operation.
41 The caller is responsible for aligning the Address if required.
42 @param Width The width of the I/O operation.
44 @return Data read from registers in the EFI CPU I/O space.
51 IN EFI_SMM_IO_WIDTH Width
55 Writes registers in the EFI CPU I/O space.
57 Writes the I/O port specified by Port with registers width and value specified by Width
58 and Data respectively. Data is returned. If such operations are not supported, then ASSERT().
59 This function must guarantee that all I/O read and write operations are serialized.
61 @param Port The base address of the I/O operation.
62 The caller is responsible for aligning the Address if required.
63 @param Width The width of the I/O operation.
64 @param Data The value to write to the I/O port.
66 @return The paramter of Data.
73 IN EFI_SMM_IO_WIDTH Width
,
78 Reads memory-mapped registers in the EFI system memory space.
80 Reads the MMIO registers specified by Address with registers width specified by Width.
81 The read value is returned. If such operations are not supported, then ASSERT().
82 This function must guarantee that all MMIO read and write operations are serialized.
84 @param Address The MMIO register to read.
85 The caller is responsible for aligning the Address if required.
86 @param Width The width of the I/O operation.
88 @return Data read from registers in the EFI system memory space.
95 IN EFI_SMM_IO_WIDTH Width
99 Writes memory-mapped registers in the EFI system memory space.
101 Writes the MMIO registers specified by Address with registers width and value specified by Width
102 and Data respectively. Data is returned. If such operations are not supported, then ASSERT().
103 This function must guarantee that all MMIO read and write operations are serialized.
105 @param Address The MMIO register to read.
106 The caller is responsible for aligning the Address if required.
107 @param Width The width of the I/O operation.
108 @param Data The value to write to the I/O port.
110 @return Data read from registers in the EFI system memory space.
117 IN EFI_SMM_IO_WIDTH Width
,