From: "Ayush Singh" <ayushdevel1325@gmail.com>
To: Pedro Falcato <pedro.falcato@gmail.com>
Cc: edk2-devel-groups-io <devel@edk2.groups.io>
Subject: Re: [edk2-devel] Need clarification about UEFI Strings
Date: Tue, 7 Jun 2022 13:49:17 +0530 [thread overview]
Message-ID: <CA+Yfj7vK9O7NWcCoE8Dn0t4Te+QoGLZho7=eeLfsN9OYTREkVw@mail.gmail.com> (raw)
In-Reply-To: <CAKbZUD2w-Nba542fQVTbU2CN6dfLBwES83sg6JgcFc04VytRWQ@mail.gmail.com>
Thanks, Pedro,
However, according to the specs, it is possible to construct ASCII
Strings as well. So when would ASCII Strings be used over normal UCS-2
Strings?
Ayush Singh
On Tue, Jun 7, 2022 at 1:13 PM Pedro Falcato <pedro.falcato@gmail.com> wrote:
>
> Hi Ayush,
>
> In the latest UEFI 2.9 spec, it's specified under 2.3.1 that CHAR8 strings/characters are (usually) ASCII, and CHAR16 strings/characters are (usually) UCS-2 (*not* UTF-16).
>
> On Tue, Jun 7, 2022 at 7:02 AM Ayush Singh <ayushdevel1325@gmail.com> wrote:
>>
>> Hello everyone, I am trying to write an implementation for UEFI
>> strings in Rust and just wanted clarification about some things.
>>
>> Are UEFI Strings UTF-16 encoded? I have looked at some previous Rust
>> implementations for this and it seems UEFI does not support the whole
>> UTF-16 but rather only UCS-2
>> (https://en.wikipedia.org/wiki/Universal_Coded_Character_Set) which is
>> a subset of UTF-16.
>>
>> There is also something called WTF-8
>> (https://en.wikipedia.org/wiki/UTF-8#WTF-8) which Rust uses to
>> represent OsStrings in Windows which is supposed to use UTF-16 (?).
>>
>> Anyway, if someone can point me to the resources/specifications of
>> UEFI Strings, it would be a great help.
>>
>> Ayush Singh
>>
>>
>>
>>
>>
>
>
> --
> Pedro Falcato
next prev parent reply other threads:[~2022-06-07 8:19 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-06-07 6:02 Need clarification about UEFI Strings Ayush Singh
2022-06-07 7:43 ` [edk2-devel] " Pedro Falcato
2022-06-07 8:19 ` Ayush Singh [this message]
2022-06-07 9:58 ` Pedro Falcato
2022-06-07 11:44 ` Ayush Singh
[not found] ` <16F65406CF53B1FF.10097@groups.io>
2022-06-29 11:16 ` Ayush Singh
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CA+Yfj7vK9O7NWcCoE8Dn0t4Te+QoGLZho7=eeLfsN9OYTREkVw@mail.gmail.com' \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox