]> git.proxmox.com Git - mirror_edk2.git/blobdiff - IntelFrameworkModulePkg/Universal/BdsDxe/BootMngr/BootManager.c
Refine BdsDxe driver and GenericBdsLib library so that the GenericBdsLib doesn't...
[mirror_edk2.git] / IntelFrameworkModulePkg / Universal / BdsDxe / BootMngr / BootManager.c
index a838c2ff7eca0b7d3fc70adc3d38efd28e557ff0..dc1364899ea3b0f7187a5814de60ebd51f52849c 100644 (file)
@@ -232,6 +232,14 @@ CallBootManager (
 \r
   BdsLibEnumerateAllBootOption (&mBootOptionsList);\r
 \r
+  //\r
+  // Group the legacy boot options for the same device type\r
+  //\r
+  GroupMultipleLegacyBootOption4SameType ();\r
+\r
+  InitializeListHead (&mBootOptionsList);\r
+  BdsLibBuildOptionFromVar (&mBootOptionsList, L"BootOrder");\r
+\r
   HiiHandle = gBootManagerPrivate.HiiHandle;\r
 \r
   //\r
@@ -268,9 +276,9 @@ CallBootManager (
     mKeyInput++;\r
 \r
     //\r
-    // Don't display the boot option marked as LOAD_OPTION_HIDDEN\r
+    // Don't display the hidden/inactive boot option\r
     //\r
-    if ((Option->Attribute & LOAD_OPTION_HIDDEN) != 0) {\r
+    if (((Option->Attribute & LOAD_OPTION_HIDDEN) != 0) || ((Option->Attribute & LOAD_OPTION_ACTIVE) == 0)) {\r
       continue;\r
     }\r
 \r