+ if (Normal || !Consist) {\r
+ //\r
+ // need the Normal here since people can use both on command line. otherwise unused.\r
+ //\r
+\r
+ //\r
+ // Allocate a name\r
+ //\r
+ CurrentName = NULL;\r
+ CurrentName = StrnCatGrow(&CurrentName, 0, MapList, 0);\r
+ if (CurrentName == NULL) {\r
+ return (EFI_OUT_OF_RESOURCES);\r
+ }\r
+\r
+ //\r
+ // Chop off the other names that become "Alias(s)"\r
+ // leaving just the normal name\r
+ //\r
+ TempSpot = StrStr(CurrentName, L";");\r
+ if (TempSpot != NULL) {\r
+ *TempSpot = CHAR_NULL;\r
+ }\r
+ } else {\r
+ CurrentName = NULL;\r
+\r
+ //\r
+ // Skip the first name. This is the standard name.\r
+ //\r
+ TempSpot = StrStr(MapList, L";");\r
+ if (TempSpot != NULL) {\r
+ TempSpot++;\r
+ }\r
+ SearchList(TempSpot, L"HD*", &CurrentName, TRUE, FALSE, L";");\r
+ if (CurrentName == NULL) {\r
+ SearchList(TempSpot, L"CD*", &CurrentName, TRUE, FALSE, L";");\r
+ }\r
+ if (CurrentName == NULL) {\r
+ SearchList(TempSpot, L"FP*", &CurrentName, TRUE, FALSE, L";");\r
+ }\r
+ if (CurrentName == NULL) {\r
+ SearchList(TempSpot, L"F*", &CurrentName, TRUE, FALSE, L";");\r
+ }\r
+ if (CurrentName == NULL) {\r
+ //\r
+ // We didnt find anything, so just the first one in the list...\r
+ //\r
+ CurrentName = StrnCatGrow(&CurrentName, 0, MapList, 0);\r
+ if (CurrentName == NULL) {\r
+ return (EFI_OUT_OF_RESOURCES);\r
+ }\r
+ TempSpot = StrStr(CurrentName, L";");\r
+ if (TempSpot != NULL) {\r
+ *TempSpot = CHAR_NULL;\r
+ }\r
+ } else {\r
+ Alias = StrnCatGrow(&Alias, 0, MapList, 0);\r
+ if (Alias == NULL) {\r
+ return EFI_OUT_OF_RESOURCES;\r
+ }\r
+ TempSpot = StrStr(Alias, CurrentName);\r
+ if (TempSpot != NULL) {\r
+ TempSpot2 = StrStr(TempSpot, L";");\r
+ if (TempSpot2 != NULL) {\r
+ TempSpot2++; // Move past ";" from CurrentName\r
+ CopyMem(TempSpot, TempSpot2, StrSize(TempSpot2));\r
+ } else {\r
+ *TempSpot = CHAR_NULL;\r
+ }\r
+ }\r
+ if (Alias[StrLen(Alias)-1] == L';') {\r
+ Alias[StrLen(Alias)-1] = CHAR_NULL;\r
+ }\r
+ }\r