TianoCore EDK2 master
|
#include <Base.h>
#include <Library/DebugLib.h>
#include <Library/DxeServicesTableLib.h>
#include <Library/UefiBootServicesTableLib.h>
#include <Library/UefiLib.h>
#include <Library/UefiRuntimeLib.h>
#include "ResetSystemAcpiGed.h"
Go to the source code of this file.
Functions | |
STATIC EFI_STATUS | SetMemoryAttributesRunTime (UINTN Address) |
STATIC EFI_STATUS | GetPowerManagerByParseAcpiInfo (VOID) |
STATIC VOID | ResetSystemLibAddressChangeEvent (IN EFI_EVENT Event, IN VOID *Context) |
STATIC VOID | AcpiNotificationEvent (IN EFI_EVENT Event, IN VOID *Context) |
EFI_STATUS EFIAPI | ResetSystemLibConstructor (IN EFI_HANDLE ImageHandle, IN EFI_SYSTEM_TABLE *SystemTable) |
Dxe ResetSystem library implementation.
Copyright (c) 2024 Loongson Technology Corporation Limited. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent
Definition in file DxeResetSystemAcpiGed.c.
Notification function of ACPI Table change.
This is a notification function registered on ACPI Table change event. It saves the Century address stored in ACPI FADT table.
Event | Event whose notification function is being invoked. |
Context | Pointer to the notification function's context. |
Definition at line 187 of file DxeResetSystemAcpiGed.c.
STATIC EFI_STATUS GetPowerManagerByParseAcpiInfo | ( | VOID | ) |
Find the power manager related info from ACPI table
RETURN_SUCCESS | Successfully find out all the required information. |
RETURN_NOT_FOUND | Failed to find the required info. |
Definition at line 98 of file DxeResetSystemAcpiGed.c.
This is a notification function registered on EVT_SIGNAL_VIRTUAL_ADDRESS_CHANGE event. It converts a pointer to a new virtual address.
[in] | Event | Event whose notification function is being invoked. |
[in] | Context | Pointer to the notification function's context |
Definition at line 166 of file DxeResetSystemAcpiGed.c.
EFI_STATUS EFIAPI ResetSystemLibConstructor | ( | IN EFI_HANDLE | ImageHandle, |
IN EFI_SYSTEM_TABLE * | SystemTable | ||
) |
The constructor function to Register ACPI Table change event and Address Change Event.
EFI_SUCCESS | The constructor always returns RETURN_SUCCESS. |
Definition at line 232 of file DxeResetSystemAcpiGed.c.
STATIC EFI_STATUS SetMemoryAttributesRunTime | ( | UINTN | Address | ) |
Modifies the attributes to Runtime type for a page size memory region.
BaseAddress | Specified start address |
EFI_SUCCESS | The attributes were set for the memory region. |
EFI_INVALID_PARAMETER | Length is zero. |
EFI_UNSUPPORTED | The processor does not support one or more bytes of the memory resource range specified by BaseAddress and Length. |
EFI_UNSUPPORTED | The bit mask of attributes is not support for the memory resource range specified by BaseAddress and Length. |
EFI_ACCESS_DEFINED | The attributes for the memory resource range specified by BaseAddress and Length cannot be modified. |
EFI_OUT_OF_RESOURCES | There are not enough system resources to modify the attributes of the memory resource range. |
EFI_NOT_AVAILABLE_YET | The attributes cannot be set because CPU architectural protocol is not available yet. |
Definition at line 38 of file DxeResetSystemAcpiGed.c.