Fix the bug that BDS assumes any boot option resides in the FV is Shell which causes that the non-Shell FV boot option is removed by GenericBdsLib.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11342 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
niruiyu 2011-03-01 06:46:24 +00:00
parent 157136700d
commit 6617d838fa
1 changed files with 6 additions and 3 deletions

View File

@ -2326,14 +2326,17 @@ BdsLibIsValidEFIBootOptDevicePathExt (
} }
// //
// Check if it's a valid boot option for internal Shell // Check if it's a valid boot option for internal FV application
// //
if (EfiGetNameGuidFromFwVolDevicePathNode ((MEDIA_FW_VOL_FILEPATH_DEVICE_PATH *) LastDeviceNode) != NULL) { if (EfiGetNameGuidFromFwVolDevicePathNode ((MEDIA_FW_VOL_FILEPATH_DEVICE_PATH *) LastDeviceNode) != NULL) {
// //
// If the boot option point to Internal FV shell, make sure it is valid // If the boot option point to internal FV application, make sure it is valid
// //
TempDevicePath = DevPath; TempDevicePath = DevPath;
Status = BdsLibUpdateFvFileDevicePath (&TempDevicePath, PcdGetPtr(PcdShellFile)); Status = BdsLibUpdateFvFileDevicePath (
&TempDevicePath,
EfiGetNameGuidFromFwVolDevicePathNode ((MEDIA_FW_VOL_FILEPATH_DEVICE_PATH *) LastDeviceNode)
);
if (Status == EFI_ALREADY_STARTED) { if (Status == EFI_ALREADY_STARTED) {
return TRUE; return TRUE;
} else { } else {