TianoCore EDK2 master
Loading...
Searching...
No Matches
PrmSampleAcpiParameterBufferModule.c File Reference
#include <PrmModule.h>
#include <Library/BaseLib.h>
#include <Library/UefiLib.h>
#include <Library/DebugLib.h>

Go to the source code of this file.

Macros

#define PARAM_BUFFER_TEST_SIGNATURE   SIGNATURE_32('T','E','S','T')
 
#define CHECK_PARAM_BUFFER_PRM_HANDLER_GUID   {0x2e4f2d13, 0x6240, 0x4ed0, {0xa4, 0x01, 0xc7, 0x23, 0xfb, 0xdc, 0x34, 0xe8}}
 

Functions

 PRM_HANDLER_EXPORT (CheckParamBufferPrmHandler)
 
 PRM_MODULE_EXPORT ()
 
EFI_STATUS EFIAPI PrmSampleAcpiParameterBufferModuleInit (IN EFI_HANDLE ImageHandle, IN EFI_SYSTEM_TABLE *SystemTable)
 

Detailed Description

This PRM Module demonstrates how to define an ACPI parameter buffer that is used by a PRM handler.

Copyright (c) Microsoft Corporation SPDX-License-Identifier: BSD-2-Clause-Patent

Definition in file PrmSampleAcpiParameterBufferModule.c.

Macro Definition Documentation

◆ CHECK_PARAM_BUFFER_PRM_HANDLER_GUID

#define CHECK_PARAM_BUFFER_PRM_HANDLER_GUID   {0x2e4f2d13, 0x6240, 0x4ed0, {0xa4, 0x01, 0xc7, 0x23, 0xfb, 0xdc, 0x34, 0xe8}}

Definition at line 25 of file PrmSampleAcpiParameterBufferModule.c.

◆ PARAM_BUFFER_TEST_SIGNATURE

#define PARAM_BUFFER_TEST_SIGNATURE   SIGNATURE_32('T','E','S','T')

Definition at line 18 of file PrmSampleAcpiParameterBufferModule.c.

Function Documentation

◆ PRM_HANDLER_EXPORT()

PRM_HANDLER_EXPORT ( CheckParamBufferPrmHandler  )

A sample Platform Runtime Mechanism (PRM) handler.

This sample handler checks if a parameter buffer is provided with the data signature ('T', 'E', 'S', 'T') at the beginning of the buffer.

The contents are expected to be updated by ACPI code at OS runtime.

Parameters
[in]ParameterBufferA pointer to the PRM handler parameter buffer
[in]ContextBUfferA pointer to the PRM handler context buffer
Return values
EFI_STATUSThe PRM handler executed successfully.
OthersAn error occurred in the PRM handler.

Definition at line 42 of file PrmSampleAcpiParameterBufferModule.c.

◆ PrmSampleAcpiParameterBufferModuleInit()

EFI_STATUS EFIAPI PrmSampleAcpiParameterBufferModuleInit ( IN EFI_HANDLE  ImageHandle,
IN EFI_SYSTEM_TABLE SystemTable 
)

Module entry point.

Parameters
[in]ImageHandleThe image handle.
[in]SystemTableA pointer to the system table.
Return values
EFI_SUCCESSThis function always returns success.

Definition at line 72 of file PrmSampleAcpiParameterBufferModule.c.