Page MenuHomeFreeBSD

D24107.id69619.diff
No OneTemporary

D24107.id69619.diff

Index: usr.sbin/bhyve/smbiostbl.c
===================================================================
--- usr.sbin/bhyve/smbiostbl.c
+++ usr.sbin/bhyve/smbiostbl.c
@@ -444,7 +444,7 @@
-1, /* handle of memory error data */
64, /* total width in bits including ecc */
64, /* data width in bits */
- 0x7fff, /* size in bytes (0x7fff=use extended)*/
+ 0, /* size in bytes (0x7fff=use extended)*/
SMBIOS_MDFF_UNKNOWN,
0, /* set (0x00=none, 0xff=unknown) */
1, /* device locator string */
@@ -695,12 +695,17 @@
uint16_t *n, uint16_t *size)
{
struct smbios_table_type17 *type17;
+ uint64_t memsize, size_MB;
smbios_generic_initializer(template_entry, template_strings,
curaddr, endaddr, n, size);
type17 = (struct smbios_table_type17 *)curaddr;
type17->arrayhand = type16_handle;
- type17->xsize = guest_lomem;
+
+ memsize = guest_lomem + guest_himem;
+ size_MB = memsize / MB;
+
+ type17->size = size_MB & 0x7FFF;
if (guest_himem > 0) {
curaddr = *endaddr;
@@ -708,7 +713,10 @@
curaddr, endaddr, n, size);
type17 = (struct smbios_table_type17 *)curaddr;
type17->arrayhand = type16_handle;
- type17->xsize = guest_himem;
+ if (size_MB > 0x7FFF) {
+ type17->size = 0x7FFF;
+ type17->xsize = size_MB & 0x7FFFFFFF;
+ }
}
return (0);
@@ -750,12 +758,12 @@
smbios_ep->eplen = 0x1F;
assert(sizeof (struct smbios_entry_point) == smbios_ep->eplen);
smbios_ep->major = 2;
- smbios_ep->minor = 6;
+ smbios_ep->minor = 7;
smbios_ep->revision = 0;
memcpy(smbios_ep->ianchor, SMBIOS_ENTRY_IANCHOR,
SMBIOS_ENTRY_IANCHORLEN);
smbios_ep->staddr = staddr;
- smbios_ep->bcdrev = 0x24;
+ smbios_ep->bcdrev = 0x27;
}
static void

File Metadata

Mime Type
text/plain
Expires
Mon, Jan 13, 1:38 AM (20 h, 8 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
15774622
Default Alt Text
D24107.id69619.diff (1 KB)

Event Timeline