The Legacy Region Protocol controls the read, write and boot-lock attributes for\r
the region 0xC0000 to 0xFFFFF.\r
\r
- Copyright (c) 2009, Intel Corporation\r
- All rights reserved. This program and the accompanying materials\r
- are licensed and made available under the terms and conditions of the BSD License\r
- which accompanies this distribution. The full text of the license may be found at\r
- http://opensource.org/licenses/bsd-license.php\r
-\r
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+ Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.<BR>\r
+ SPDX-License-Identifier: BSD-2-Clause-Patent\r
\r
@par Revision Reference:\r
- This Protocol is defined in UEFI Platform Initialization Specification 1.2 \r
+ This Protocol is defined in UEFI Platform Initialization Specification 1.2\r
Volume 5: Standards\r
\r
- @attention This protocol appears to be 'EFI_LEGACY_REGION_PROTOCOL' in current PI 1.2\r
- public spec. Therefore, some names are different from public PI 1.2 spec and we should\r
- remove this attention when they appear in public PI 1.2 spec in the future. \r
-\r
**/\r
\r
#ifndef __LEGACY_REGION2_H__\r
/**\r
Modify the hardware to allow (decode) or disallow (not decode) memory reads in a region.\r
\r
- If the On parameter evaluates to TRUE, this function enables memory reads in the address range \r
+ If the On parameter evaluates to TRUE, this function enables memory reads in the address range\r
Start to (Start + Length - 1).\r
- If the On parameter evaluates to FALSE, this function disables memory reads in the address range \r
+ If the On parameter evaluates to FALSE, this function disables memory reads in the address range\r
Start to (Start + Length - 1).\r
\r
@param This[in] Indicates the EFI_LEGACY_REGION2_PROTOCOL instance.\r
**/\r
typedef\r
EFI_STATUS\r
-(EFIAPI *EFI_LEGACY_REGION2_DECODE) (\r
+(EFIAPI *EFI_LEGACY_REGION2_DECODE)(\r
IN EFI_LEGACY_REGION2_PROTOCOL *This,\r
IN UINT32 Start,\r
IN UINT32 Length,\r
**/\r
typedef\r
EFI_STATUS\r
-(EFIAPI *EFI_LEGACY_REGION2_LOCK) (\r
+(EFIAPI *EFI_LEGACY_REGION2_LOCK)(\r
IN EFI_LEGACY_REGION2_PROTOCOL *This,\r
IN UINT32 Start,\r
IN UINT32 Length,\r
/**\r
Modify the hardware to disallow memory attribute changes in a region.\r
\r
- This function makes the attributes of a region read only. Once a region is boot-locked with this \r
+ This function makes the attributes of a region read only. Once a region is boot-locked with this\r
function, the read and write attributes of that region cannot be changed until a power cycle has\r
reset the boot-lock attribute. Calls to Decode(), Lock() and Unlock() will have no effect.\r
\r
/**\r
Modify the hardware to allow memory writes in a region.\r
\r
- This function changes the attributes of a memory range to allow writes. \r
+ This function changes the attributes of a memory range to allow writes.\r
\r
@param This[in] Indicates the EFI_LEGACY_REGION2_PROTOCOL instance.\r
@param Start[in] The beginning of the physical address of the region whose\r
**/\r
typedef\r
EFI_STATUS\r
-(EFIAPI *EFI_LEGACY_REGION2_UNLOCK) (\r
+(EFIAPI *EFI_LEGACY_REGION2_UNLOCK)(\r
IN EFI_LEGACY_REGION2_PROTOCOL *This,\r
IN UINT32 Start,\r
IN UINT32 Length,\r
\r
\r
typedef struct {\r
- UINT32 Start; ///< The beginning of the physical address of this\r
- ///< region.\r
- UINT32 Length; ///< The number of bytes in this region.\r
- EFI_LEGACY_REGION_ATTRIBUTE Attribute; ///< Attribute of the Legacy Region Descriptor that\r
- ///< describes the capabilities for that memory region. \r
- UINT32 Granularity; ///< Describes the byte length programmability\r
- ///< associated with the Start address and the specified\r
- ///< Attribute setting.\r
+ ///\r
+ /// The beginning of the physical address of this\r
+ /// region.\r
+ ///\r
+ UINT32 Start;\r
+ ///\r
+ /// The number of bytes in this region.\r
+ ///\r
+ UINT32 Length;\r
+ ///\r
+ /// Attribute of the Legacy Region Descriptor that\r
+ /// describes the capabilities for that memory region.\r
+ ///\r
+ EFI_LEGACY_REGION_ATTRIBUTE Attribute;\r
+ ///\r
+ /// Describes the byte length programmability\r
+ /// associated with the Start address and the specified\r
+ /// Attribute setting.\r
+ UINT32 Granularity;\r
} EFI_LEGACY_REGION_DESCRIPTOR;\r
\r
\r
/**\r
Get region information for the attributes of the Legacy Region.\r
\r
- This function is used to discover the granularity of the attributes for the memory in the legacy \r
+ This function is used to discover the granularity of the attributes for the memory in the legacy\r
region. Each attribute may have a different granularity and the granularity may not be the same\r
- for all memory ranges in the legacy region. \r
+ for all memory ranges in the legacy region.\r
\r
@param This[in] Indicates the EFI_LEGACY_REGION2_PROTOCOL instance.\r
@param DescriptorCount[out] The number of region descriptor entries returned in the Descriptor\r
**/\r
typedef\r
EFI_STATUS\r
-(EFIAPI *EFI_LEGACY_REGION_GET_INFO) (\r
+(EFIAPI *EFI_LEGACY_REGION_GET_INFO)(\r
IN EFI_LEGACY_REGION2_PROTOCOL *This,\r
OUT UINT32 *DescriptorCount,\r
OUT EFI_LEGACY_REGION_DESCRIPTOR **Descriptor\r
);\r
\r
\r
-/**\r
- Abstracts the hardware control of the physical address region 0xC0000-0xFFFFF.\r
-\r
- The EFI_LEGACY_REGION2_PROTOCOL is used to abstract the hardware control of the memory \r
- attributes of the Option ROM shadowing region, 0xC0000 to 0xFFFFF.\r
- \r
- There are three memory attributes that can be modified through this protocol: read, write and\r
- boot-lock. These protocols may be set in any combination.\r
-\r
-**/\r
+///\r
+/// The EFI_LEGACY_REGION2_PROTOCOL is used to abstract the hardware control of the memory\r
+/// attributes of the Option ROM shadowing region, 0xC0000 to 0xFFFFF.\r
+/// There are three memory attributes that can be modified through this protocol: read, write and\r
+/// boot-lock. These protocols may be set in any combination.\r
+///\r
struct _EFI_LEGACY_REGION2_PROTOCOL {\r
- EFI_LEGACY_REGION2_DECODE Decode; ///< Modify the read attribute of a memory region. See\r
- ///< the Decode() function description.\r
- EFI_LEGACY_REGION2_LOCK Lock; ///< Modify the write attribute of a memory region to\r
- ///< prevent writes. See the Lock() function description.\r
- EFI_LEGACY_REGION2_BOOT_LOCK BootLock; ///< Modify the boot-lock attribute of a memory region to\r
- ///< prevent future changes to the memory attributes for\r
- ///< this region. See the BootLock() function description.\r
- EFI_LEGACY_REGION2_UNLOCK UnLock; ///< Modify the write attribute of a memory region to\r
- ///< allow writes. See the Unlock() function description. \r
- EFI_LEGACY_REGION_GET_INFO GetInfo; ///< Modify the write attribute of a memory region to\r
- ///< allow writes. See the GetInfo() function description.\r
+ EFI_LEGACY_REGION2_DECODE Decode;\r
+ EFI_LEGACY_REGION2_LOCK Lock;\r
+ EFI_LEGACY_REGION2_BOOT_LOCK BootLock;\r
+ EFI_LEGACY_REGION2_UNLOCK UnLock;\r
+ EFI_LEGACY_REGION_GET_INFO GetInfo;\r
};\r
\r
extern EFI_GUID gEfiLegacyRegion2ProtocolGuid;\r