summaryrefslogtreecommitdiffstats
path: root/sys/contrib/dev/acpica/include/acapps.h
diff options
context:
space:
mode:
Diffstat (limited to 'sys/contrib/dev/acpica/include/acapps.h')
-rw-r--r--sys/contrib/dev/acpica/include/acapps.h93
1 files changed, 43 insertions, 50 deletions
diff --git a/sys/contrib/dev/acpica/include/acapps.h b/sys/contrib/dev/acpica/include/acapps.h
index 7c4880a..87284f2 100644
--- a/sys/contrib/dev/acpica/include/acapps.h
+++ b/sys/contrib/dev/acpica/include/acapps.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2015, Intel Corp.
+ * Copyright (C) 2000 - 2016, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -44,6 +44,7 @@
#ifndef _ACAPPS
#define _ACAPPS
+#include <stdio.h>
#ifdef _MSC_VER /* disable some level-4 warnings */
#pragma warning(disable:4100) /* warning C4100: unreferenced formal parameter */
@@ -52,7 +53,7 @@
/* Common info for tool signons */
#define ACPICA_NAME "Intel ACPI Component Architecture"
-#define ACPICA_COPYRIGHT "Copyright (c) 2000 - 2015 Intel Corporation"
+#define ACPICA_COPYRIGHT "Copyright (c) 2000 - 2016 Intel Corporation"
#if ACPI_MACHINE_WIDTH == 64
#define ACPI_WIDTH "-64"
@@ -90,11 +91,49 @@
AcpiOsPrintf (Description);
#define ACPI_OPTION(Name, Description) \
- AcpiOsPrintf (" %-18s%s\n", Name, Description);
+ AcpiOsPrintf (" %-20s%s\n", Name, Description);
+/* Check for unexpected exceptions */
+
+#define ACPI_CHECK_STATUS(Name, Status, Expected) \
+ if (Status != Expected) \
+ { \
+ AcpiOsPrintf ("Unexpected %s from %s (%s-%d)\n", \
+ AcpiFormatException (Status), #Name, _AcpiModuleName, __LINE__); \
+ }
+
+/* Check for unexpected non-AE_OK errors */
+
+
+#define ACPI_CHECK_OK(Name, Status) ACPI_CHECK_STATUS (Name, Status, AE_OK);
+
#define FILE_SUFFIX_DISASSEMBLY "dsl"
-#define ACPI_TABLE_FILE_SUFFIX ".dat"
+#define FILE_SUFFIX_BINARY_TABLE ".dat" /* Needs the dot */
+
+
+/* acfileio */
+
+ACPI_STATUS
+AcGetAllTablesFromFile (
+ char *Filename,
+ UINT8 GetOnlyAmlTables,
+ ACPI_NEW_TABLE_DESC **ReturnListHead);
+
+BOOLEAN
+AcIsFileBinary (
+ FILE *File);
+
+ACPI_STATUS
+AcValidateTableHeader (
+ FILE *File,
+ long TableOffset);
+
+
+/* Values for GetOnlyAmlTables */
+
+#define ACPI_GET_ONLY_AML_TABLES TRUE
+#define ACPI_GET_ALL_TABLES FALSE
/*
@@ -125,51 +164,6 @@ CmGetFileSize (
ACPI_FILE File);
-#ifndef ACPI_DUMP_APP
-/*
- * adisasm
- */
-ACPI_STATUS
-AdAmlDisassemble (
- BOOLEAN OutToFile,
- char *Filename,
- char *Prefix,
- char **OutFilename);
-
-void
-AdPrintStatistics (
- void);
-
-ACPI_STATUS
-AdFindDsdt(
- UINT8 **DsdtPtr,
- UINT32 *DsdtLength);
-
-void
-AdDumpTables (
- void);
-
-ACPI_STATUS
-AdGetLocalTables (
- void);
-
-ACPI_STATUS
-AdParseTable (
- ACPI_TABLE_HEADER *Table,
- ACPI_OWNER_ID *OwnerId,
- BOOLEAN LoadTable,
- BOOLEAN External);
-
-ACPI_STATUS
-AdDisplayTables (
- char *Filename,
- ACPI_TABLE_HEADER *Table);
-
-ACPI_STATUS
-AdDisplayStatistics (
- void);
-
-
/*
* adwalk
*/
@@ -228,6 +222,5 @@ AdWriteTable (
UINT32 Length,
char *TableName,
char *OemTableId);
-#endif
#endif /* _ACAPPS */
OpenPOWER on IntegriCloud