[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Xen-devel] [PATCH v7 04/11] public: xen.h: add definitions for UUID handling
- To: Konrad Rzeszutek Wilk <konrad.wilk@xxxxxxxxxx>
- From: Volodymyr Babchuk <volodymyr_babchuk@xxxxxxxx>
- Date: Thu, 5 Oct 2017 17:50:20 +0300
- Cc: "Edgar E . Iglesias" <edgar.iglesias@xxxxxxxxxx>, Tim Deegan <tim@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Wei Liu <wei.liu2@xxxxxxxxxx>, George Dunlap <George.Dunlap@xxxxxxxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Ian Jackson <ian.jackson@xxxxxxxxxxxxx>, xen-devel@xxxxxxxxxxxxx, Julien Grall <julien.grall@xxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>
- Delivery-date: Thu, 05 Oct 2017 14:50:33 +0000
- List-id: Xen developer discussion <xen-devel.lists.xen.org>
- Spamdiagnosticmetadata: NSPM
- Spamdiagnosticoutput: 1:99
Hi Konrad,
On 05.10.17 16:03, Konrad Rzeszutek Wilk wrote:
On Thu, Oct 05, 2017 at 12:00:20AM +0300, Volodymyr Babchuk wrote:
Added type xen_uuid_t. This type represents UUID as an array of 16
bytes in big endian format.
Added macro XEN_DEFINE_UUID that constructs UUID in the usual way:
XEN_DEFINE_UUID(0x00112233, 0x4455, 0x6677, 0x8899,
0xaa, 0xbb, 0xcc, 0xdd, 0xee, 0xff)
will construct UUID 00112233-4455-6677-8899-aabbccddeeff presented as
{0x00, 0x11, 0x22, 0x33, 0x44, 0x55, 0x66, 0x77, 0x88,
0x99, 0xaa, 0xbb, 0xcc, 0xdd, 0xee, 0xff}
NB: This is compatible with Linux kernel and with libuuid, but it is not
compatible with Microsoft, as they use mixed-endian encoding (some
components are little-endian, some are big-endian).
Oh boy. What a mess.
Do we care about Microsoft for this or is this more for information
purpose?
This is for information. Problem is that XEN already defines EFI_GUID
which uses MS-style encoding. It is used in EFI code only, but I think
it is worth to explain differences.
There was discussion at [1]
[...]
[1] http://markmail.org/message/cawi6f33spqg4hf5
Thanks,
Volodymyr
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
https://lists.xen.org/xen-devel
|