ananda
2006-05-19 21:50:01 UTC
#include <windows.h>
#include <string.h>
#include <stdio.h>
#include <iostream.h>
ULONG_PTR
main(ULONG_PTR argc, char *argv[])
/*++
Description: The input to this can be
- a.pat b.pat c.pat abcd\q.pat fgh\m.apt xyz\* pqr\?.pat g.pat
- ListFile with the above list
--*/
{
UCHAR pFirmwareTableBuffer1[0x100];
UCHAR pFirmwareTableBuffer2[0x100];
ULONG_PTR retValue;
ULONG_PTR err;
retValue = EnumSystemFirmwareTables('ACPI', pFirmwareTableBuffer1, 0x100);
printf("Ret vlaue 1= %d\n", retValue);
//
// Return 20 and pFirmwareTableBuffer1 has
// FACP APIC SPCR MCFG OEMB
//
retValue = GetSystemFirmwareTable('ACPI', 'FACP', pFirmwareTableBuffer2,
0x100);
err = GetLastError();
printf("Ret vlaue 2 = %d, Err = %d\n", retValue, err);
//
// Returns 0 and err = 1168 - No elements found - Why should this fail?
//
}
Please help
thanks
ananda
#include <string.h>
#include <stdio.h>
#include <iostream.h>
ULONG_PTR
main(ULONG_PTR argc, char *argv[])
/*++
Description: The input to this can be
- a.pat b.pat c.pat abcd\q.pat fgh\m.apt xyz\* pqr\?.pat g.pat
- ListFile with the above list
--*/
{
UCHAR pFirmwareTableBuffer1[0x100];
UCHAR pFirmwareTableBuffer2[0x100];
ULONG_PTR retValue;
ULONG_PTR err;
retValue = EnumSystemFirmwareTables('ACPI', pFirmwareTableBuffer1, 0x100);
printf("Ret vlaue 1= %d\n", retValue);
//
// Return 20 and pFirmwareTableBuffer1 has
// FACP APIC SPCR MCFG OEMB
//
retValue = GetSystemFirmwareTable('ACPI', 'FACP', pFirmwareTableBuffer2,
0x100);
err = GetLastError();
printf("Ret vlaue 2 = %d, Err = %d\n", retValue, err);
//
// Returns 0 and err = 1168 - No elements found - Why should this fail?
//
}
Please help
thanks
ananda