\r
[LibraryClasses.IPF]\r
IoLib|MdePkg/Library/BaseIoLibIntrinsic/BaseIoLibIntrinsic.inf\r
+ TimerLib|MdePkg/Library/SecPeiDxeTimerLibCpu/SecPeiDxeTimerLibCpu.inf\r
+ PalCallLib|MdePkg/Library/BasePalCallLibNull/BasePalCallLibNull.inf\r
\r
[LibraryClasses.EBC.DXE_DRIVER]\r
IoLib|IntelFrameworkPkg/Library/DxeIoLibCpuIo/DxeIoLibCpuIo.inf\r
[LibraryClasses.X64.UEFI_APPLICATION]\r
TimerLib|MdePkg/Library/SecPeiDxeTimerLibCpu/SecPeiDxeTimerLibCpu.inf\r
\r
-[LibraryClasses.IPF.BASE]\r
- TimerLib|MdePkg/Library/SecPeiDxeTimerLibCpu/SecPeiDxeTimerLibCpu.inf\r
-\r
-[LibraryClasses.IPF.SEC]\r
- TimerLib|MdePkg/Library/SecPeiDxeTimerLibCpu/SecPeiDxeTimerLibCpu.inf\r
-\r
-[LibraryClasses.IPF.PEI_CORE]\r
- TimerLib|MdePkg/Library/SecPeiDxeTimerLibCpu/SecPeiDxeTimerLibCpu.inf\r
-\r
-[LibraryClasses.IPF.PEIM]\r
- TimerLib|MdePkg/Library/SecPeiDxeTimerLibCpu/SecPeiDxeTimerLibCpu.inf\r
-\r
-[LibraryClasses.IPF.DXE_DRIVER]\r
- TimerLib|MdePkg/Library/SecPeiDxeTimerLibCpu/SecPeiDxeTimerLibCpu.inf\r
-\r
-[LibraryClasses.IPF.DXE_SAL_DRIVER]\r
- TimerLib|MdePkg/Library/SecPeiDxeTimerLibCpu/SecPeiDxeTimerLibCpu.inf\r
-\r
-[LibraryClasses.IPF.UEFI_DRIVER]\r
- TimerLib|MdePkg/Library/SecPeiDxeTimerLibCpu/SecPeiDxeTimerLibCpu.inf\r
-\r
-[LibraryClasses.IPF.UEFI_APPLICATION]\r
- TimerLib|MdePkg/Library/SecPeiDxeTimerLibCpu/SecPeiDxeTimerLibCpu.inf\r
-\r
[LibraryClasses.IA32.DXE_RUNTIME_DRIVER]\r
UefiRuntimeLib|MdePkg/Library/UefiRuntimeLib/UefiRuntimeLib.inf\r
\r
#define PAL_CACHE_FLUSH_INVALIDATE_LINES BIT0\r
#define PAL_CACHE_FLUSH_NO_INVALIDATE_LINES 0\r
#define PAL_CACHE_FLUSH_POLL_INTERRUPT BIT1\r
-#define PAL_CACHE_FLUSH_NO_INTERRUPT 0\r
+#define PAL_CACHE_FLUSH_NO_INTERRUPT 0\r
\r
/**\r
\r
VOID\r
)\r
{\r
- PalCall (1, 1, 1, 0);\r
+ PalCall (PAL_CACHE_FLUSH, PAL_CACHE_FLUSH_INSTRUCTION_ALL, PAL_CACHE_FLUSH_INVALIDATE_LINES, 0);\r
}\r
\r
/**\r
VOID\r
)\r
{\r
- PalCall (1, 2, 1, 0);\r
+ PalCall (PAL_CACHE_FLUSH, PAL_CACHE_FLUSH_DATA_ALL, PAL_CACHE_FLUSH_INVALIDATE_LINES, 0);\r
}\r
\r
/**\r
VOID\r
)\r
{\r
- PalCall (1, 2, 0, 0);\r
+ PalCall (PAL_CACHE_FLUSH, PAL_CACHE_FLUSH_DATA_ALL, PAL_CACHE_FLUSH_NO_INVALIDATE_LINES | PAL_CACHE_FLUSH_NO_INTERRUPT, 0);\r
}\r
\r
/**\r
--- /dev/null
+#/** @file\r
+# Component description file for NULL Debug Library\r
+#\r
+# Debug Library with empty functions.\r
+# Copyright (c) 2007, Intel Corporation.\r
+#\r
+# All rights reserved. This program and the accompanying materials\r
+# are licensed and made available under the terms and conditions of the BSD License\r
+# which accompanies this distribution. The full text of the license may be found at\r
+# http://opensource.org/licenses/bsd-license.php\r
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+#\r
+#\r
+#**/\r
+\r
+[Defines]\r
+ INF_VERSION = 0x00010005\r
+ BASE_NAME = BasePalCallLibNull\r
+ FILE_GUID = 632D5625-B73D-43b8-AF30-8D225D96168E\r
+ MODULE_TYPE = BASE\r
+ VERSION_STRING = 1.0\r
+ LIBRARY_CLASS = PalCallLib \r
+ EDK_RELEASE_VERSION = 0x00020000\r
+ EFI_SPECIFICATION_VERSION = 0x00020000\r
+\r
+\r
+#\r
+# VALID_ARCHITECTURES = IPF\r
+#\r
+\r
+[Sources.common]\r
+ PalCall.c\r
+\r
+\r
+[Packages]\r
+ MdePkg/MdePkg.dec\r
+\r
+\r
+[LibraryClasses]\r
+ DebugLib\r
+\r
--- /dev/null
+/** @file\r
+ \r
+ Template and Sample instance of PalCallLib.\r
+ \r
+ Copyright (c) 2006 - 2007, Intel Corporation\r
+ All rights reserved. This program and the accompanying materials\r
+ are licensed and made available under the terms and conditions of the BSD License\r
+ which accompanies this distribution. The full text of the license may be found at\r
+ http://opensource.org/licenses/bsd-license.php\r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+**/\r
+#include <Base.h>\r
+#include <Library/PalCallLib.h>\r
+#include <Library/DebugLib.h>\r
+\r
+/**\r
+ Makes a PAL procedure call.\r
+\r
+ This is a wrapper function to make a PAL procedure call. Based on the Index value,\r
+ this API will make static or stacked PAL call. Architected procedures may be designated\r
+ as required or optional. If a PAL procedure is specified as optional, a unique return\r
+ code of 0xFFFFFFFFFFFFFFFF is returned in the Status field of the PAL_CALL_RETURN structure.\r
+ This indicates that the procedure is not present in this PAL implementation. It is the\r
+ caller¡¯s responsibility to check for this return code after calling any optional PAL\r
+ procedure. No parameter checking is performed on the 4 input parameters, but there are\r
+ some common rules that the caller should follow when making a PAL call. Any address\r
+ passed to PAL as buffers for return parameters must be 8-byte aligned. Unaligned addresses\r
+ may cause undefined results. For those parameters defined as reserved or some fields\r
+ defined as reserved must be zero filled or the invalid argument return value may be\r
+ returned or undefined result may occur during the execution of the procedure.\r
+ This function is only available on IPF.\r
+\r
+ @param Index - The PAL procedure Index number.\r
+ @param Arg2 - The 2nd parameter for PAL procedure calls.\r
+ @param Arg3 - The 3rd parameter for PAL procedure calls.\r
+ @param Arg4 - The 4th parameter for PAL procedure calls.\r
+\r
+ @return structure returned from the PAL Call procedure, including the status and return value.\r
+\r
+**/\r
+PAL_CALL_RETURN\r
+EFIAPI\r
+PalCall (\r
+ IN UINT64 Index,\r
+ IN UINT64 Arg2,\r
+ IN UINT64 Arg3,\r
+ IN UINT64 Arg4\r
+ )\r
+{\r
+ PAL_CALL_RETURN Ret;\r
+\r
+ Ret.Status = (UINT64) -1;\r
+ ASSERT (!RETURN_ERROR (RETURN_UNSUPPORTED));\r
+ return Ret;\r
+}\r
*EndValue = (UINT64)(-1);\r
}\r
\r
- PalRet = PalCall (13, 0, 0, 0);\r
+ PalRet = PalCall (PAL_FREQ_BASE, 0, 0, 0);\r
if (PalRet.Status != 0) {\r
return 1000000;\r
}\r
BaseFrequence = PalRet.r9;\r
\r
- PalRet = PalCall (14, 0, 0, 0);\r
+ PalRet = PalCall (PAL_FREQ_RATIOS, 0, 0, 0);\r
if (PalRet.Status != 0) {\r
return 1000000;\r
}\r
[Components.IPF]\r
MdePkg/Library/SecPeiDxeTimerLibCpu/SecPeiDxeTimerLibCpu.inf\r
MdePkg/Library/PeiServicesTablePointerLibKr7/PeiServicesTablePointerLibKr7.inf\r
+ MdePkg/Library/BasePalCallLibNull/BasePalCallLibNull.inf\r