From: Chris Lalancette <clalance@redhat.com>
To: Anthony Liguori <anthony@codemonkey.ws>
Cc: Gleb Natapov <gleb@qumranet.com>, qemu-devel@nongnu.org
Subject: [Qemu-devel] Re: [PATCH 0/3]: Add UUID command-line option
Date: Mon, 28 Jul 2008 17:09:54 +0200 [thread overview]
Message-ID: <488DE142.1060100@redhat.com> (raw)
In-Reply-To: <488DDF8B.8020103@codemonkey.ws>
Anthony Liguori wrote:
>> Hm, but that's basically what this does, in combination with the Bochs BIOS.
>> Once the Bochs BIOS reaches the rombios32 code, it makes the calls into the
>> device model VMware backdoor to get the UUID. Assuming this all succeeds, the
>> Bochs BIOS then plumbs it into the SMBIOS tables.
>>
>
> Are there patches for the Bochs BIOS to do this? Why wouldn't it just
> use CMOS to get at the UUID?
Yeah, there's a uuid_probe() function that's already been merged into the Bochs
BIOS, and subsequently to most of the downstream projects (including KVM).
void uuid_probe(void)
{
#ifdef BX_QEMU
uint32_t eax, ebx, ecx, edx;
// check if backdoor port exists
asm volatile ("outl %%eax, %%dx"
: "=a" (eax), "=b" (ebx), "=c" (ecx), "=d" (edx)
: "a" (0x564d5868), "c" (0xa), "d" (0x5658));
if (ebx == 0x564d5868) {
uint32_t *uuid_ptr = (uint32_t *)bios_uuid;
// get uuid
asm volatile ("outl %%eax, %%dx"
: "=a" (eax), "=b" (ebx), "=c" (ecx), "=d" (edx)
: "a" (0x564d5868), "c" (0x13), "d" (0x5658));
uuid_ptr[0] = eax;
uuid_ptr[1] = ebx;
uuid_ptr[2] = ecx;
uuid_ptr[3] = edx;
} else
#endif
{
// UUID not set
memset(bios_uuid, 0, 16);
}
}
Later on in the rombios32 code the bios_uuid[] is used to build up the SMBIOS
tables.
Chris Lalancette
next prev parent reply other threads:[~2008-07-28 15:11 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-07-28 13:25 [Qemu-devel] [PATCH 0/3]: Add UUID command-line option Chris Lalancette
2008-07-28 14:15 ` [Qemu-devel] " Gleb Natapov
2008-07-28 14:37 ` Anthony Liguori
2008-07-28 14:41 ` Chris Lalancette
2008-07-28 15:02 ` Anthony Liguori
2008-07-28 15:09 ` Chris Lalancette [this message]
2008-07-28 15:12 ` Anthony Liguori
2008-07-28 15:42 ` Chris Lalancette
2008-07-28 16:02 ` Gleb Natapov
2008-07-28 16:17 ` Anthony Liguori
2008-07-28 16:27 ` Gleb Natapov
2008-07-28 17:41 ` Blue Swirl
2008-07-28 16:28 ` Jamie Lokier
2008-07-28 19:02 ` Anthony Liguori
2008-07-28 20:00 ` Jamie Lokier
2008-07-28 20:25 ` Anthony Liguori
2008-07-28 20:40 ` Paul Brook
2008-07-28 20:55 ` Anthony Liguori
2008-07-29 6:31 ` Gleb Natapov
2008-07-28 15:48 ` Jamie Lokier
2008-07-31 19:45 ` [Qemu-devel] " Sebastian Herbszt
2008-07-28 15:49 ` [Qemu-devel] " Jamie Lokier
2008-07-28 16:06 ` Anthony Liguori
2008-07-28 15:35 ` Gleb Natapov
2008-07-29 19:22 ` Anthony Liguori
2008-07-29 19:50 ` Gleb Natapov
2008-07-30 17:32 ` Blue Swirl
2008-08-05 14:33 ` Gleb Natapov
2008-08-06 2:35 ` Anthony Liguori
2008-08-06 16:26 ` Blue Swirl
2008-08-06 16:33 ` Anthony Liguori
2008-08-06 22:07 ` [Qemu-devel] " Sebastian Herbszt
2008-08-06 22:11 ` [Qemu-devel] " Anthony Liguori
2008-07-29 8:15 ` Daniel P. Berrange
2008-07-29 8:42 ` Chris Lalancette
2008-07-28 15:51 ` Jamie Lokier
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-all 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=488DE142.1060100@redhat.com \
--to=clalance@redhat.com \
--cc=anthony@codemonkey.ws \
--cc=gleb@qumranet.com \
--cc=qemu-devel@nongnu.org \
/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;
as well as URLs for NNTP newsgroup(s).