mirror of https://github.com/acidanthera/audk.git
Use Device Path Macros to get Device Path Type/SubType. (Some extensions might use high-bit-set device path type to specify "unpacked" device path.)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@3880 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
bd1fc2092e
commit
3d6f81d7b4
|
@ -297,8 +297,8 @@ EfiGetNameGuidFromFwVolDevicePathNode (
|
|||
//
|
||||
// Use the new Device path that does not conflict with the UEFI
|
||||
//
|
||||
if (FrameworkFvDevicePathNode->Tiano.Header.Type == MEDIA_DEVICE_PATH &&
|
||||
FrameworkFvDevicePathNode->Tiano.Header.SubType == MEDIA_VENDOR_DP) {
|
||||
if (DevicePathType (&FrameworkFvDevicePathNode->Tiano.Header) == MEDIA_DEVICE_PATH &&
|
||||
DevicePathSubType (&FrameworkFvDevicePathNode->Tiano.Header) == MEDIA_VENDOR_DP) {
|
||||
if (CompareGuid (&gEfiFrameworkDevicePathGuid, &FrameworkFvDevicePathNode->Tiano.TianoSpecificDevicePath)) {
|
||||
if (FrameworkFvDevicePathNode->Tiano.Type == TIANO_MEDIA_FW_VOL_FILEPATH_DEVICE_PATH_TYPE) {
|
||||
return (EFI_GUID *) &FrameworkFvDevicePathNode->NameGuid;
|
||||
|
@ -328,7 +328,7 @@ VOID
|
|||
EFIAPI
|
||||
EfiInitializeFwVolDevicepathNode (
|
||||
IN OUT MEDIA_FW_VOL_FILEPATH_DEVICE_PATH *FvDevicePathNode,
|
||||
IN CONST EFI_GUID *NameGuid
|
||||
IN CONST EFI_GUID *NameGuid
|
||||
)
|
||||
{
|
||||
FRAMEWORK_MEDIA_FW_VOL_FILEPATH_DEVICE_PATH *FrameworkFvDevicePathNode;
|
||||
|
|
|
@ -283,9 +283,8 @@ EfiGetNameGuidFromFwVolDevicePathNode (
|
|||
{
|
||||
ASSERT (FvFileDevicePathNode != NULL);
|
||||
|
||||
if (FvFileDevicePathNode->Header.Type == MEDIA_DEVICE_PATH &&
|
||||
FvFileDevicePathNode->Header.SubType == MEDIA_PIWG_FW_FILE_DP
|
||||
) {
|
||||
if (DevicePathType (&FvFileDevicePathNode->Header) == MEDIA_DEVICE_PATH &&
|
||||
DevicePathSubType (&FvFileDevicePathNode->Header) == MEDIA_PIWG_FW_FILE_DP) {
|
||||
return (EFI_GUID *) &FvFileDevicePathNode->FvFileName;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue