* [PATCH]Use a marco to standardize XEN uuid length
@ 2007-08-24 5:14 Zhang, Xing Z
2007-08-24 14:45 ` Keir Fraser
0 siblings, 1 reply; 4+ messages in thread
From: Zhang, Xing Z @ 2007-08-24 5:14 UTC (permalink / raw)
To: xen-devel, Keir Fraser; +Cc: xen-ia64-devel
[-- Attachment #1: Type: text/plain, Size: 86 bytes --]
This patch use a marco instead of hard code in smbios.c.
IA64 also need this marco.
[-- Attachment #2: use_marco_for_uuid_len_in_smbios.patch --]
[-- Type: application/octet-stream, Size: 2480 bytes --]
Use a macro stardardize XEN uuid length
Signed-off-by, Zhang Xin < xing.z.zhang@intel.com>
diff -r 5b19839d0365 tools/firmware/hvmloader/smbios.c
--- a/tools/firmware/hvmloader/smbios.c Sun Aug 12 12:19:13 2007 -0600
+++ b/tools/firmware/hvmloader/smbios.c Wed Aug 22 15:41:36 2007 +0800
@@ -30,7 +30,7 @@ static int
static int
write_smbios_tables(void *start,
uint32_t vcpus, uint64_t memsize,
- uint8_t uuid[16], char *xen_version,
+ uint8_t uuid[XENVER_UUID_LEN], char *xen_version,
uint32_t xen_major_version, uint32_t xen_minor_version);
static void
@@ -46,7 +46,7 @@ smbios_type_0_init(void *start, const ch
uint32_t xen_major_version, uint32_t xen_minor_version);
static void *
smbios_type_1_init(void *start, const char *xen_version,
- uint8_t uuid[16]);
+ uint8_t uuid[XENVER_UUID_LEN]);
static void *
smbios_type_3_init(void *start);
static void *
@@ -85,7 +85,7 @@ static int
static int
write_smbios_tables(void *start,
uint32_t vcpus, uint64_t memsize,
- uint8_t uuid[16], char *xen_version,
+ uint8_t uuid[XENVER_UUID_LEN], char *xen_version,
uint32_t xen_major_version, uint32_t xen_minor_version)
{
unsigned cpu_num, nr_structs = 0, max_struct_size = 0;
@@ -159,7 +159,7 @@ int
int
hvm_write_smbios_tables(void)
{
- uint8_t uuid[16]; /* ** This will break if xen_domain_handle_t is
+ uint8_t uuid[XENVER_UUID_LEN]; /* ** This will break if xen_domain_handle_t is
not uint8_t[16]. ** */
uint16_t xen_major_version, xen_minor_version;
uint32_t xen_version;
@@ -314,7 +314,7 @@ smbios_type_0_init(void *start, const ch
/* Type 1 -- System Information */
static void *
smbios_type_1_init(void *start, const char *xen_version,
- uint8_t uuid[16])
+ uint8_t uuid[XENVER_UUID_LEN])
{
char uuid_str[37];
struct smbios_type_1 *p = (struct smbios_type_1 *)start;
diff -r 5b19839d0365 xen/include/public/version.h
--- a/xen/include/public/version.h Sun Aug 12 12:19:13 2007 -0600
+++ b/xen/include/public/version.h Wed Aug 22 11:13:00 2007 +0800
@@ -77,6 +77,7 @@ typedef struct xen_feature_info xen_feat
/* arg == xen_domain_handle_t. */
#define XENVER_guest_handle 8
+#define XENVER_UUID_LEN 16
#endif /* __XEN_PUBLIC_VERSION_H__ */
[-- Attachment #3: Type: text/plain, Size: 138 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH]Use a marco to standardize XEN uuid length
2007-08-24 5:14 [PATCH]Use a marco to standardize XEN uuid length Zhang, Xing Z
@ 2007-08-24 14:45 ` Keir Fraser
2007-08-24 14:58 ` Alex Williamson
2007-08-27 6:22 ` Zhang, Xing Z
0 siblings, 2 replies; 4+ messages in thread
From: Keir Fraser @ 2007-08-24 14:45 UTC (permalink / raw)
To: Zhang, Xing Z, xen-devel; +Cc: xen-ia64-devel
Should just use xen_domain_handle_t directly. What does smbios.c have to do
with IA64?
-- Keir
On 24/8/07 06:14, "Zhang, Xing Z" <xing.z.zhang@intel.com> wrote:
> This patch use a marco instead of hard code in smbios.c.
> IA64 also need this marco.
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xensource.com
> http://lists.xensource.com/xen-devel
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH]Use a marco to standardize XEN uuid length
2007-08-24 14:45 ` Keir Fraser
@ 2007-08-24 14:58 ` Alex Williamson
2007-08-27 6:22 ` Zhang, Xing Z
1 sibling, 0 replies; 4+ messages in thread
From: Alex Williamson @ 2007-08-24 14:58 UTC (permalink / raw)
To: Keir Fraser; +Cc: xen-ia64-devel, xen-devel, Zhang, Xing Z
On Fri, 2007-08-24 at 15:45 +0100, Keir Fraser wrote:
> Should just use xen_domain_handle_t directly. What does smbios.c have to do
> with IA64?
ia64 systems can have an SMBIOS table. We're adding one for HVM
domains so that we can hook into the DMI capabilities in the Linux
kernel and make the ACPI _OSI call return true for "Linux" (2.6.18
already does this, but 2.6.23 doesn't by default). This way we can
identify whether the HVM guest is Linux or Windows and tune per domain
optimizations in Xen accordingly. Thanks,
Alex
--
Alex Williamson HP Open Source & Linux Org.
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: [PATCH]Use a marco to standardize XEN uuid length
2007-08-24 14:45 ` Keir Fraser
2007-08-24 14:58 ` Alex Williamson
@ 2007-08-27 6:22 ` Zhang, Xing Z
1 sibling, 0 replies; 4+ messages in thread
From: Zhang, Xing Z @ 2007-08-27 6:22 UTC (permalink / raw)
To: Keir Fraser, xen-devel; +Cc: xen-ia64-devel
xen_domain_handle_t is ok.
We add SMBios for IA64
>-----Original Message-----
>From: Keir Fraser [mailto:Keir.Fraser@cl.cam.ac.uk]
>Sent: 2007年8月24日 22:45
>To: Zhang, Xing Z; xen-devel@lists.xensource.com
>Cc: xen-ia64-devel
>Subject: Re: [XEN-DEVEL][PATCH]Use a marco to standardize XEN uuid length
>
>Should just use xen_domain_handle_t directly. What does smbios.c have to do
>with IA64?
>
> -- Keir
>
>On 24/8/07 06:14, "Zhang, Xing Z" <xing.z.zhang@intel.com> wrote:
>
>> This patch use a marco instead of hard code in smbios.c.
>> IA64 also need this marco.
>> _______________________________________________
>> Xen-devel mailing list
>> Xen-devel@lists.xensource.com
>> http://lists.xensource.com/xen-devel
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2007-08-27 6:22 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-08-24 5:14 [PATCH]Use a marco to standardize XEN uuid length Zhang, Xing Z
2007-08-24 14:45 ` Keir Fraser
2007-08-24 14:58 ` Alex Williamson
2007-08-27 6:22 ` Zhang, Xing Z
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.