]> git.proxmox.com Git - mirror_edk2.git/blame - UefiCpuPkg/Library/SmmCpuFeaturesLib/StandaloneMmCpuFeaturesLib.c
UefiCpuPkg: Move AsmRelocateApLoopStart from Mpfuncs.nasm to AmdSev.nasm
[mirror_edk2.git] / UefiCpuPkg / Library / SmmCpuFeaturesLib / StandaloneMmCpuFeaturesLib.c
CommitLineData
edd46cd4
MK
1/** @file\r
2Standalone MM CPU specific programming.\r
3\r
4Copyright (c) 2010 - 2019, Intel Corporation. All rights reserved.<BR>\r
5Copyright (c) Microsoft Corporation.<BR>\r
6SPDX-License-Identifier: BSD-2-Clause-Patent\r
7\r
8**/\r
9\r
10#include <PiMm.h>\r
11#include <Library/PcdLib.h>\r
12#include "CpuFeaturesLib.h"\r
13\r
14/**\r
15 Gets the maximum number of logical processors from the PCD PcdCpuMaxLogicalProcessorNumber.\r
16\r
17 This access is abstracted from the PCD services to enforce that the PCD be\r
18 FixedAtBuild in the Standalone MM build of this driver.\r
19\r
20 @return The value of PcdCpuMaxLogicalProcessorNumber.\r
21\r
22**/\r
23UINT32\r
24GetCpuMaxLogicalProcessorNumber (\r
25 VOID\r
26 )\r
27{\r
28 return FixedPcdGet32 (PcdCpuMaxLogicalProcessorNumber);\r
29}\r
30\r
31/**\r
32 The Standalone MM library constructor.\r
33\r
34 @param[in] ImageHandle Image handle of this driver.\r
35 @param[in] SystemTable A Pointer to the EFI System Table.\r
36\r
37 @retval EFI_SUCCESS This constructor always returns success.\r
38\r
39**/\r
40EFI_STATUS\r
41EFIAPI\r
42StandaloneMmCpuFeaturesLibConstructor (\r
43 IN EFI_HANDLE ImageHandle,\r
44 IN EFI_MM_SYSTEM_TABLE *SystemTable\r
45 )\r
46{\r
47 CpuFeaturesLibInitialization ();\r
48\r
49 return EFI_SUCCESS;\r
50}\r