80 Status =
gRT->GetVariable (
81 EFI_PLATFORM_LANG_VARIABLE_NAME,
87 if (Status == EFI_BUFFER_TOO_SMALL) {
88 Status =
gBS->AllocatePool (
91 (VOID **)&PlatformLang
93 if (!EFI_ERROR (Status)) {
94 Status =
gRT->GetVariable (
95 EFI_PLATFORM_LANG_VARIABLE_NAME,
101 if (EFI_ERROR (Status)) {
102 gBS->FreePool (PlatformLang);
107 if (!EFI_ERROR (Status)) {
108 if (AsciiStrnLenS (PlatformLang,
Size) < 2) {
109 gBS->FreePool (PlatformLang);
116 if (PlatformLang == NULL) {
121 EFI_PLATFORM_LANG_VARIABLE_NAME,
123 EFI_VARIABLE_RUNTIME_ACCESS | EFI_VARIABLE_BOOTSERVICE_ACCESS | EFI_VARIABLE_NON_VOLATILE,
127 }
else if (AsciiStrnCmp (PlatformLang,
"en", 2) != 0) {
136 "UnicodeLanguages must contain one extra language"
147 if (PlatformLang != NULL) {
148 gBS->FreePool (PlatformLang);
168 if (((Index >=
'a') && (Index <=
'z')) || ((Index >= 0xe0) && (Index <= 0xf6)) || ((Index >= 0xf8) && (Index <= 0xfe))) {
169 Index2 = Index - 0x20;
178 for (Index = 0;
mOtherChars[Index] != 0; Index++) {
199 IN EFI_UNICODE_COLLATION_PROTOCOL *This,
227 IN EFI_UNICODE_COLLATION_PROTOCOL *This,
248 IN EFI_UNICODE_COLLATION_PROTOCOL *This,
273 IN EFI_UNICODE_COLLATION_PROTOCOL *This,
301 while (*String != 0) {
346 if ((CharP == 0) || (CharP ==
']')) {
375 while ((CharP != 0) && (CharP !=
']')) {
409 IN EFI_UNICODE_COLLATION_PROTOCOL *This,
418 while ((*Fat != 0) && (FatSize != 0)) {
446 IN EFI_UNICODE_COLLATION_PROTOCOL *This,
452 BOOLEAN SpecialCharExist;
454 SpecialCharExist = FALSE;
455 while ((*String != 0) && (FatSize != 0)) {
459 if ((*String !=
'.') && (*String !=
' ')) {
468 SpecialCharExist = TRUE;
481 return SpecialCharExist;
DMG_SIZE_DEVICE_PATH Size
STATIC_ASSERT(BYTES_PER_PIXEL==sizeof(UINT32), "Non 4-byte pixels are unsupported!")
VOID OcUnicodeCollationInitializeMappingTables(VOID)
STATIC CHAR8 UnicodeLanguages[6]
BOOLEAN EFIAPI EngStrToFat(IN EFI_UNICODE_COLLATION_PROTOCOL *This, IN CHAR16 *String, IN UINTN FatSize, OUT CHAR8 *Fat)
VOID EFIAPI EngStrLwr(IN EFI_UNICODE_COLLATION_PROTOCOL *This, IN OUT CHAR16 *Str)
VOID EFIAPI EngFatToStr(IN EFI_UNICODE_COLLATION_PROTOCOL *This, IN UINTN FatSize, IN CHAR8 *Fat, OUT CHAR16 *String)
VOID OcUnicodeCollationUpdatePlatformLanguage(VOID)
VOID EFIAPI EngStrUpr(IN EFI_UNICODE_COLLATION_PROTOCOL *This, IN OUT CHAR16 *Str)
CHAR8 mEngLowerMap[MAP_TABLE_SIZE]
CHAR8 mEngUpperMap[MAP_TABLE_SIZE]
BOOLEAN EFIAPI EngMetaiMatch(IN EFI_UNICODE_COLLATION_PROTOCOL *This, IN CHAR16 *String, IN CHAR16 *Pattern)
CHAR8 mEngInfoMap[MAP_TABLE_SIZE]
INTN EFIAPI EngStriColl(IN EFI_UNICODE_COLLATION_PROTOCOL *This, IN CHAR16 *Str1, IN CHAR16 *Str2)
GLOBAL_REMOVE_IF_UNREFERENCED EFI_UNICODE_COLLATION_PROTOCOL gInternalUnicode2Eng
EFI_RUNTIME_SERVICES * gRT
EFI_GUID gEfiGlobalVariableGuid