Changeset View
Changeset View
Standalone View
Standalone View
usr.sbin/bhyve/smbiostbl.c
Show First 20 Lines • Show All 660 Lines • ▼ Show 20 Lines | smbios_type1_initializer(struct smbios_structure *template_entry, | ||||
type1 = (struct smbios_table_type1 *)curaddr; | type1 = (struct smbios_table_type1 *)curaddr; | ||||
guest_uuid_str = get_config_value("uuid"); | guest_uuid_str = get_config_value("uuid"); | ||||
if (guest_uuid_str != NULL) { | if (guest_uuid_str != NULL) { | ||||
uuid_t uuid; | uuid_t uuid; | ||||
uint32_t status; | uint32_t status; | ||||
uuid_from_string(guest_uuid_str, &uuid, &status); | uuid_from_string(guest_uuid_str, &uuid, &status); | ||||
if (status != uuid_s_ok) | if (status != uuid_s_ok) { | ||||
EPRINTLN("Invalid UUID"); | |||||
jhb: Direct use of fprintf to stderr isn't used in bhyve since a uart on stdio can put the tty into… | |||||
return (-1); | return (-1); | ||||
} | |||||
Done Inline ActionsThis should remain a return (-1); And the assert in bhyverun.c should be changed to an exit(4); rgrimes: This should remain a return (-1); And the assert in bhyverun.c should be changed to an exit… | |||||
uuid_enc_le(&type1->uuid, &uuid); | uuid_enc_le(&type1->uuid, &uuid); | ||||
} else { | } else { | ||||
MD5_CTX mdctx; | MD5_CTX mdctx; | ||||
u_char digest[16]; | u_char digest[16]; | ||||
char hostname[MAXHOSTNAMELEN]; | char hostname[MAXHOSTNAMELEN]; | ||||
const char *vmname; | const char *vmname; | ||||
/* | /* | ||||
▲ Show 20 Lines • Show All 254 Lines • Show Last 20 Lines |
Direct use of fprintf to stderr isn't used in bhyve since a uart on stdio can put the tty into raw mode. There are wrapper macros (EPRINTLN or the like) that are used in bhyve instead.