OpenCore  1.0.4
OpenCore Bootloader
Loading...
Searching...
No Matches
OcAcpiLib.h File Reference
#include <IndustryStandard/Acpi62.h>
#include <Protocol/SimpleFileSystem.h>

Go to the source code of this file.

Data Structures

struct  OC_ACPI_6_2_ROOT_SYSTEM_DESCRIPTION_TABLE
 
struct  OC_ACPI_6_2_EXTENDED_SYSTEM_DESCRIPTION_TABLE
 
struct  OC_ACPI_REGION
 
struct  OC_ACPI_CONTEXT
 
struct  OC_ACPI_PATCH
 

Macros

#define OC_ACPI_NAME_SIZE   4
 

Functions

EFI_STATUS AcpiInitContext (IN OUT OC_ACPI_CONTEXT *Context)
 
VOID AcpiFreeContext (IN OUT OC_ACPI_CONTEXT *Context)
 
EFI_STATUS AcpiApplyContext (IN OUT OC_ACPI_CONTEXT *Context)
 
EFI_STATUS AcpiDeleteTable (IN OUT OC_ACPI_CONTEXT *Context, IN UINT32 Signature, IN UINT32 Length, IN UINT64 OemTableId, IN BOOLEAN All)
 
EFI_STATUS AcpiInsertTable (IN OUT OC_ACPI_CONTEXT *Context, IN CONST UINT8 *Data, IN UINT32 Length)
 
VOID AcpiNormalizeHeaders (IN OUT OC_ACPI_CONTEXT *Context)
 
EFI_STATUS AcpiApplyPatch (IN OUT OC_ACPI_CONTEXT *Context, IN OC_ACPI_PATCH *Patch)
 
EFI_STATUS AcpiLoadRegions (IN OUT OC_ACPI_CONTEXT *Context)
 
VOID AcpiRelocateRegions (IN OUT OC_ACPI_CONTEXT *Context)
 
EFI_STATUS AcpiFadtEnableReset (IN OUT OC_ACPI_CONTEXT *Context)
 
VOID AcpiResetLogoStatus (IN OUT OC_ACPI_CONTEXT *Context)
 
VOID AcpiSyncTableIds (IN OUT OC_ACPI_CONTEXT *Context)
 
VOID AcpiHandleHardwareSignature (IN OUT OC_ACPI_CONTEXT *Context, IN BOOLEAN Reset)
 
EFI_STATUS AcpiDumpTables (IN EFI_FILE_PROTOCOL *Root)
 
EFI_STATUS AcpiFindEntryInMemory (IN UINT8 *Table, IN CONST CHAR8 *PathString, IN UINT8 Entry, OUT UINT32 *Offset, IN UINT32 TableLength OPTIONAL)
 

Detailed Description

Copyright (C) 2016, The HermitCrabs Lab. All rights reserved.

All rights reserved.

This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at http://opensource.org/licenses/bsd-license.php

THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.

Definition in file OcAcpiLib.h.

Macro Definition Documentation

◆ OC_ACPI_NAME_SIZE

#define OC_ACPI_NAME_SIZE   4

Definition at line 21 of file OcAcpiLib.h.

Function Documentation

◆ AcpiApplyContext()

EFI_STATUS AcpiApplyContext ( IN OUT OC_ACPI_CONTEXT * Context)

Apply ACPI context to this system.

Parameters
[in,out]ContextACPI library context.

Definition at line 900 of file OcAcpiLib.c.

◆ AcpiApplyPatch()

EFI_STATUS AcpiApplyPatch ( IN OUT OC_ACPI_CONTEXT * Context,
IN OC_ACPI_PATCH * Patch )

Patch ACPI tables.

Parameters
[in,out]ContextACPI library context.
[in]PatchACPI patch.

Definition at line 1247 of file OcAcpiLib.c.

◆ AcpiDeleteTable()

EFI_STATUS AcpiDeleteTable ( IN OUT OC_ACPI_CONTEXT * Context,
IN UINT32 Signature,
IN UINT32 Length,
IN UINT64 OemTableId,
IN BOOLEAN All )

Delete one ACPI table.

Parameters
[in,out]ContextACPI library context.
[in]SignatureTable signature or 0.
[in]LengthTable length or 0.
[in]OemTableIdTable Id or 0.
[in]AllDelete all tables or first matched.

Definition at line 1015 of file OcAcpiLib.c.

◆ AcpiDumpTables()

EFI_STATUS AcpiDumpTables ( IN EFI_FILE_PROTOCOL * Root)

Dump ACPI tables to the specified directory.

Parameters
[in]RootDirectory to write tables.

Definition at line 102 of file AcpiDump.c.

◆ AcpiFadtEnableReset()

EFI_STATUS AcpiFadtEnableReset ( IN OUT OC_ACPI_CONTEXT * Context)

Upgrade FADT to support reset register needed on very old legacy hardware.

Parameters
[in,out]ContextACPI library context.
Returns
EFI_SUCCESS if successful or not needed.

Definition at line 1510 of file OcAcpiLib.c.

◆ AcpiFindEntryInMemory()

EFI_STATUS AcpiFindEntryInMemory ( IN UINT8 * Table,
IN CONST CHAR8 * PathString,
IN UINT8 Entry,
OUT UINT32 * Offset,
IN UINT32 TableLength OPTIONAL )

Finds offset of required entry in ACPI table in case it exists.

Parameters
[in]TablePointer to start of ACPI table.
[in]PathStringPath to entry which must be found.
[in]EntryNumber of entry which must be found.
[out]OffsetOffset of the entry if it was found.
[out]TableLengthLength of ACPI table.
Return values
EFI_SUCCESSRequired entry was found.
EFI_NOT_FOUNDRequired entry was not found.
EFI_DEVICE_ERRORError occured during parsing ACPI table.
EFI_OUT_OF_RESOURCESNesting limit has been reached.
EFI_INVALID_PARAMETERGot wrong path to the entry.

Definition at line 2021 of file AcpiParser.c.

◆ AcpiFreeContext()

VOID AcpiFreeContext ( IN OUT OC_ACPI_CONTEXT * Context)

Free ACPI context dynamic resources.

Parameters
[in,out]ContextACPI library context.

Definition at line 884 of file OcAcpiLib.c.

◆ AcpiHandleHardwareSignature()

VOID AcpiHandleHardwareSignature ( IN OUT OC_ACPI_CONTEXT * Context,
IN BOOLEAN Reset )

Log and reset FACS hardware signature.

Parameters
[in,out]ContextACPI library context.
[in]ResetPerform reset.

Definition at line 1700 of file OcAcpiLib.c.

◆ AcpiInitContext()

EFI_STATUS AcpiInitContext ( IN OUT OC_ACPI_CONTEXT * Context)

Find ACPI System Tables for later table configuration.

Parameters
[in,out]ContextACPI library context.
Returns
EFI_SUCCESS when Rsdp and Xsdt or Rsdt are found.

Definition at line 738 of file OcAcpiLib.c.

◆ AcpiInsertTable()

EFI_STATUS AcpiInsertTable ( IN OUT OC_ACPI_CONTEXT * Context,
IN CONST UINT8 * Data,
IN UINT32 Length )

Install one ACPI table. For DSDT this performs table replacement.

Parameters
[in,out]ContextACPI library context.
[in]DataTable data.
[in]LengthTable length.

Definition at line 1082 of file OcAcpiLib.c.

◆ AcpiLoadRegions()

EFI_STATUS AcpiLoadRegions ( IN OUT OC_ACPI_CONTEXT * Context)

Try to load ACPI regions.

Parameters
[in,out]ContextACPI library context.

Definition at line 1421 of file OcAcpiLib.c.

◆ AcpiNormalizeHeaders()

VOID AcpiNormalizeHeaders ( IN OUT OC_ACPI_CONTEXT * Context)

Normalise ACPI headers to contain 7-bit ASCII.

Parameters
[in,out]ContextACPI library context.

Definition at line 1164 of file OcAcpiLib.c.

◆ AcpiRelocateRegions()

VOID AcpiRelocateRegions ( IN OUT OC_ACPI_CONTEXT * Context)

Attempt to relocate ACPI regions based on loaded ones.

Parameters
[in,out]ContextACPI library context.

Definition at line 1465 of file OcAcpiLib.c.

◆ AcpiResetLogoStatus()

VOID AcpiResetLogoStatus ( IN OUT OC_ACPI_CONTEXT * Context)

Reset BGRT Displayed status.

Parameters
[in,out]ContextACPI library context.

Definition at line 1596 of file OcAcpiLib.c.

◆ AcpiSyncTableIds()

VOID AcpiSyncTableIds ( IN OUT OC_ACPI_CONTEXT * Context)

Sync ACPI table identifiers with SLIC.

Parameters
[in,out]ContextACPI library context.

Definition at line 1640 of file OcAcpiLib.c.