3 Common definitions needed for Platform Runtime Mechanism (PRM) modules.
5 Copyright (c) Microsoft Corporation
6 SPDX-License-Identifier: BSD-2-Clause-Patent
14 #include <PrmContextBuffer.h>
15 #include <PrmDataBuffer.h>
16 #include <PrmExportDescriptor.h>
18 #include <PrmModuleUpdate.h>
19 #include <PrmOsServices.h>
22 Macro that provides a condensed form of a PRM Handler.
24 This macro can be used to define a PRM Handler that uses the standard PRM Handle
25 signature. It is simply provided for convenience.
28 #define PRM_HANDLER_EXPORT(Name) \
29 STATIC_ASSERT (sizeof (PRM_STRING_(Name)) <= PRM_HANDLER_NAME_MAXIMUM_LENGTH, "The PRM handler exceeds the maximum allowed size of 128."); \
32 A Platform Runtime Mechanism (PRM) handler. \
34 @param[in] ParameterBuffer A pointer to the PRM handler parameter buffer \
35 @param[in] ContextBUffer A pointer to the PRM handler context buffer \
37 @retval EFI_STATUS The PRM handler executed successfully. \
38 @retval Others An error occurred in the PRM handler. \
45 IN VOID *ParameterBuffer, \
46 IN PRM_CONTEXT_BUFFER *ContextBuffer \
50 A macro that declares the PRM Module Update Lock Descriptor for a PRM Module.
52 This macro is intended to be used once in a PRM Module so the module update lock descriptor is
53 exported for the module.
56 #define PRM_MODULE_UPDATE_LOCK_EXPORT \
57 PRM_EXPORT_API PRM_MODULE_UPDATE_LOCK_DESCRIPTOR PRM_MODULE_UPDATE_LOCK_DESCRIPTOR_NAME = { \
58 PRM_MODULE_UPDATE_LOCK_DESCRIPTOR_SIGNATURE, \
59 PRM_MODULE_UPDATE_LOCK_REVISION, \
64 // A PRM module is required to export the PRM Module Update Lock
66 PRM_MODULE_UPDATE_LOCK_EXPORT
;