TianoCore EDK2 master
Loading...
Searching...
No Matches
AmlResourceData.h File Reference
#include <AmlInclude.h>
#include <IndustryStandard/Acpi.h>

Go to the source code of this file.

Macros

#define AML_RD_SMALL_SIZE_MASK   (0x7U)
 
#define AML_RD_SMALL_ID_MASK   (0xFU << 3)
 
#define AML_RD_LARGE_ID_MASK   (0x7FU)
 
#define AML_RD_IS_LARGE(Header)
 
#define AML_RD_BUILD_SMALL_DESC_ID(Id)   ((AML_RD_HEADER)((Id & 0xF) << 3))
 
#define AML_RD_BUILD_LARGE_DESC_ID(Id)   ((AML_RD_HEADER)((BIT7) | Id))
 

Typedefs

typedef UINT8 AML_RD_HEADER
 

Functions

BOOLEAN EFIAPI AmlRdCompareDescId (IN CONST AML_RD_HEADER *Header, IN AML_RD_HEADER DescriptorId)
 
AML_RD_HEADER EFIAPI AmlRdGetDescId (IN CONST AML_RD_HEADER *Header)
 
UINT32 EFIAPI AmlRdGetSize (IN CONST AML_RD_HEADER *Header)
 
EFI_STATUS EFIAPI AmlRdSetEndTagChecksum (IN CONST AML_RD_HEADER *Header, IN UINT8 CheckSum)
 

Detailed Description

AML Resource Data.

Copyright (c) 2019 - 2020, Arm Limited. All rights reserved.

SPDX-License-Identifier: BSD-2-Clause-Patent

Glossary:
  • Rd or RD - Resource Data
  • Rds or RDS - Resource Data Small
  • Rdl or RDL - Resource Data Large

Definition in file AmlResourceData.h.

Macro Definition Documentation

◆ AML_RD_LARGE_ID_MASK

#define AML_RD_LARGE_ID_MASK   (0x7FU)

Mask for the large resource data ID.

Definition at line 73 of file AmlResourceData.h.

◆ AML_RD_SMALL_ID_MASK

#define AML_RD_SMALL_ID_MASK   (0xFU << 3)

Mask for the small resource data ID.

Definition at line 67 of file AmlResourceData.h.

◆ AML_RD_SMALL_SIZE_MASK

#define AML_RD_SMALL_SIZE_MASK   (0x7U)

Mask for the small resource data size.

Definition at line 61 of file AmlResourceData.h.

Typedef Documentation

◆ AML_RD_HEADER

typedef UINT8 AML_RD_HEADER

Resource Descriptor header for Small/Large Resource Data Object. This is the first byte of a Small/Large Resource Data element.

Can be a ACPI_SMALL_RESOURCE_HEADER or ACPI_LARGE_RESOURCE_HEADER.

Definition at line 55 of file AmlResourceData.h.

Function Documentation

◆ AmlRdSetEndTagChecksum()

EFI_STATUS EFIAPI AmlRdSetEndTagChecksum ( IN CONST AML_RD_HEADER Header,
IN UINT8  CheckSum 
)

Set the Checksum of an EndTag resource data.

ACPI 6.4, s6.4.2.9 "End Tag": "This checksum is generated such that adding it to the sum of all the data bytes will produce a zero sum." "If the checksum field is zero, the resource data is treated as if the checksum operation succeeded. Configuration proceeds normally."

Parameters
[in]HeaderPointer to the first byte of a resource data.
[in]CheckSumChecksum value to set.
Return values
EFI_SUCCESSThe function completed successfully.
EFI_INVALID_PARAMETERInvalid parameter.

Definition at line 121 of file AmlResourceData.c.