Chameleon

Chameleon Commit Details

Date:2010-01-16 00:09:13 (10 years 4 months ago)
Author:Rekursor
Commit:7
Parents: 6
Message:Cleanup some tabs, encapsulated detail smbios debug in ifdef/endif clauses.
Changes:
M/branches/rekursor/i386/libsaio/fake_efi.c

File differences

branches/rekursor/i386/libsaio/fake_efi.c
346346
347347
348348
349
349
350350
351351
352352
......
361361
362362
363363
364
364365
365366
366367
368
367369
368370
369371
370372
371373
374
372375
376
373377
374
375
378
379
380
376381
377382
378383
379384
385
380386
387
381388
382389
383390
......
600607
601608
602609
603
604
610
611
605612
606
607
613
614
608615
609616
return dst;
}
#define DEBUG_SMBIOS 1
#define DEBUG_SMBIOS 0
/* Get the SystemID from the bios dmi info */
static EFI_CHAR8* getSmbiosUUID()
if (memcmp( &smbios->dmi.anchor[0], "_DMI_", 5) != 0) {
return 0;
}
#if DEBUG_SMBIOS
verbose(">>> SMBIOSAddr=0x%08x\n", smbios);
verbose(">>> DMI: addr=0x%08x, len=0x%d, count=%d\n", smbios->dmi.tableAddress,
smbios->dmi.tableLength, smbios->dmi.structureCount);
#endif
i = 0;
found = 0;
p = (SMBByte *) smbios->dmi.tableAddress;
while (i < smbios->dmi.structureCount && p + 4 <= (SMBByte *)smbios->dmi.tableAddress + smbios->dmi.tableLength) {
dmihdr = (struct DMIHeader *) p;
#if DEBUG_SMBIOS
verbose(">>>>>> DMI(%d): type=0x%02x, len=0x%d\n",i,dmihdr->type,dmihdr->length);
#endif
if (dmihdr->length < 4 || dmihdr->type == 127 /* EOT */) break;
if (dmihdr->type == 1) {/* 3.3.2 System Information */
if (dmihdr->length >= 0x19) found = 1;
if (dmihdr->type == 1) /* 3.3.2 System Information */
{
if (dmihdr->length >= 0x19) found = 1;
break;
}
p = p + dmihdr->length;
while ((p - (SMBByte *)smbios->dmi.tableAddress + 1 < smbios->dmi.tableLength) && (p[0] != 0x00 || p[1] != 0x00))
{
p++;
}
p += 2;
i++;
}
// Initialize the base table
setupEfiTables();
// Initialize the device tree
setupEfiDeviceTree();
// Initialize the device tree
setupEfiDeviceTree();
// Add configuration table entries to both the services table and the device tree
setupEfiConfigurationTable();
// Add configuration table entries to both the services table and the device tree
setupEfiConfigurationTable();
}

Archive Download the corresponding diff file

Revision: 7