**/\r
\r
\r
+//\r
+// Include common header file for this module.\r
+//\r
+#include "UefiLibInternal.h"\r
+\r
/**\r
An empty function to pass error checking of CreateEventEx ().\r
\r
)\r
{\r
return EfiCreateEventLegacyBootEx (\r
- EFI_TPL_CALLBACK,\r
+ TPL_CALLBACK,\r
InternalEmptyFuntion,\r
NULL,\r
LegacyBootEvent\r
\r
ASSERT (LegacyBootEvent != NULL);\r
\r
- if (gST->Hdr.Revision < 0x00020000) {\r
- //\r
- // prior to UEFI 2.0 use Tiano extension to EFI\r
- //\r
- Status = gBS->CreateEvent (\r
- EFI_EVENT_SIGNAL_LEGACY_BOOT | EFI_EVENT_NOTIFY_SIGNAL_ALL,\r
- NotifyTpl,\r
- NotifyFunction,\r
- NotifyContext,\r
- LegacyBootEvent\r
- );\r
+ if (gST->Hdr.Revision < EFI_2_00_SYSTEM_TABLE_REVISION) {\r
+ DEBUG ((EFI_D_ERROR, "EFI1.1 can't support LegacyBootEvent!"));\r
+ ASSERT (FALSE);\r
+\r
+ return EFI_UNSUPPORTED;\r
} else {\r
//\r
// For UEFI 2.0 and the future use an Event Group\r
//\r
Status = gBS->CreateEventEx (\r
- EVENT_NOTIFY_SIGNAL,\r
+ EVT_NOTIFY_SIGNAL,\r
NotifyTpl,\r
NotifyFunction,\r
NotifyContext,\r
)\r
{\r
return EfiCreateEventReadyToBootEx (\r
- EFI_TPL_CALLBACK,\r
+ TPL_CALLBACK,\r
InternalEmptyFuntion,\r
NULL,\r
ReadyToBootEvent\r
\r
ASSERT (ReadyToBootEvent != NULL);\r
\r
- if (gST->Hdr.Revision < 0x00020000) {\r
- //\r
- // prior to UEFI 2.0 use Tiano extension to EFI\r
- //\r
- Status = gBS->CreateEvent (\r
- EFI_EVENT_SIGNAL_READY_TO_BOOT | EFI_EVENT_NOTIFY_SIGNAL_ALL,\r
- NotifyTpl,\r
- NotifyFunction,\r
- NotifyContext,\r
- ReadyToBootEvent\r
- );\r
+ if (gST->Hdr.Revision < EFI_2_00_SYSTEM_TABLE_REVISION) {\r
+ DEBUG ((EFI_D_ERROR, "EFI1.1 can't support ReadyToBootEvent!"));\r
+ ASSERT (FALSE);\r
+\r
+ return EFI_UNSUPPORTED;\r
} else {\r
//\r
// For UEFI 2.0 and the future use an Event Group\r
//\r
Status = gBS->CreateEventEx (\r
- EVENT_NOTIFY_SIGNAL,\r
+ EVT_NOTIFY_SIGNAL,\r
NotifyTpl,\r
NotifyFunction,\r
NotifyContext,\r
@retval Other FvDevicePathNode is valid and pointer to NameGuid was returned.\r
\r
**/\r
-EFI_GUID *\r
+EFI_GUID*\r
EFIAPI\r
EfiGetNameGuidFromFwVolDevicePathNode (\r
- IN CONST MEDIA_FW_VOL_FILEPATH_DEVICE_PATH *FvDevicePathNode\r
+ IN CONST MEDIA_FW_VOL_FILEPATH_DEVICE_PATH *FvFileDevicePathNode\r
)\r
{\r
- ASSERT (FvDevicePathNode != NULL);\r
+ ASSERT (FvFileDevicePathNode != NULL);\r
\r
- //\r
- // Use the new Device path that does not conflict with the UEFI\r
- //\r
- if (FvDevicePathNode->Tiano.Header.Type == MEDIA_DEVICE_PATH ||\r
- FvDevicePathNode->Tiano.Header.SubType == MEDIA_VENDOR_DP) {\r
- if (CompareGuid (&gEfiFrameworkDevicePathGuid, &FvDevicePathNode->Tiano.TianoSpecificDevicePath)) {\r
- if (FvDevicePathNode->Tiano.Type == TIANO_MEDIA_FW_VOL_FILEPATH_DEVICE_PATH_TYPE) {\r
- return (EFI_GUID *) &FvDevicePathNode->NameGuid;\r
- }\r
- }\r
+ if (FvFileDevicePathNode->Header.Type == MEDIA_DEVICE_PATH &&\r
+ FvFileDevicePathNode->Header.SubType == MEDIA_PIWG_FW_FILE_DP\r
+ ) {\r
+ return (EFI_GUID *) &FvFileDevicePathNode->FvFileName;\r
}\r
\r
return NULL;\r
VOID\r
EFIAPI\r
EfiInitializeFwVolDevicepathNode (\r
- IN OUT MEDIA_FW_VOL_FILEPATH_DEVICE_PATH *FvDevicePathNode,\r
- IN CONST EFI_GUID *NameGuid\r
+ IN OUT MEDIA_FW_VOL_FILEPATH_DEVICE_PATH *FvFileDevicePathNode,\r
+ IN CONST EFI_GUID *NameGuid\r
)\r
{\r
- ASSERT (FvDevicePathNode != NULL);\r
+ ASSERT (FvFileDevicePathNode != NULL);\r
ASSERT (NameGuid != NULL);\r
\r
//\r
// Use the new Device path that does not conflict with the UEFI\r
//\r
- FvDevicePathNode->Tiano.Header.Type = MEDIA_DEVICE_PATH;\r
- FvDevicePathNode->Tiano.Header.SubType = MEDIA_VENDOR_DP;\r
- SetDevicePathNodeLength (&FvDevicePathNode->Tiano.Header, sizeof (MEDIA_FW_VOL_FILEPATH_DEVICE_PATH));\r
-\r
- //\r
- // Add the GUID for generic Tiano device paths\r
- //\r
- CopyGuid (&FvDevicePathNode->Tiano.TianoSpecificDevicePath, &gEfiFrameworkDevicePathGuid);\r
-\r
- //\r
- // Add in the FW Vol File Path Tiano defined information\r
- //\r
- FvDevicePathNode->Tiano.Type = TIANO_MEDIA_FW_VOL_FILEPATH_DEVICE_PATH_TYPE;\r
+ FvFileDevicePathNode->Header.Type = MEDIA_DEVICE_PATH;\r
+ FvFileDevicePathNode->Header.SubType = MEDIA_PIWG_FW_FILE_DP;\r
+ SetDevicePathNodeLength (&FvFileDevicePathNode->Header, sizeof (MEDIA_FW_VOL_FILEPATH_DEVICE_PATH));\r
\r
- CopyGuid (&FvDevicePathNode->NameGuid, NameGuid);\r
+ CopyGuid (&FvFileDevicePathNode->FvFileName, NameGuid);\r
}\r
\r