aboutsummaryrefslogtreecommitdiff
path: root/sys/contrib/dev/acpica/compiler/asloptions.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/contrib/dev/acpica/compiler/asloptions.c')
-rw-r--r--sys/contrib/dev/acpica/compiler/asloptions.c30
1 files changed, 26 insertions, 4 deletions
diff --git a/sys/contrib/dev/acpica/compiler/asloptions.c b/sys/contrib/dev/acpica/compiler/asloptions.c
index 27308a1dc36c..a19e9a5f6af4 100644
--- a/sys/contrib/dev/acpica/compiler/asloptions.c
+++ b/sys/contrib/dev/acpica/compiler/asloptions.c
@@ -152,6 +152,7 @@
#include <contrib/dev/acpica/compiler/aslcompiler.h>
#include <contrib/dev/acpica/include/acapps.h>
#include <contrib/dev/acpica/include/acdisasm.h>
+#include <contrib/dev/acpica/include/acglobal.h>
#define _COMPONENT ACPI_COMPILER
ACPI_MODULE_NAME ("asloption")
@@ -176,7 +177,7 @@ AslDoResponseFile (
#define ASL_TOKEN_SEPARATORS " \t\n"
-#define ASL_SUPPORTED_OPTIONS "@:a:b|c|d^D:e:f^gh^i|I:l^m:no|p:P^q^r:s|t|T+G^v^w|x:z"
+#define ASL_SUPPORTED_OPTIONS "@:a:b|c|d^D:e:f^gh^i|I:l^m:no|p:P^q^r:s|:t|T+G^v^w|x:z"
/*******************************************************************************
@@ -270,7 +271,7 @@ AslDoOptions (
BOOLEAN IsResponseFile)
{
ACPI_STATUS Status;
- UINT32 j;
+ INT32 j;
/* Get the command line options */
@@ -366,7 +367,6 @@ AslDoOptions (
{
return (-1);
}
-
AslGbl_PruneType = (UINT8) strtoul (AcpiGbl_Optarg, NULL, 0);
break;
@@ -445,6 +445,28 @@ AslDoOptions (
AcpiGbl_CstyleDisassembly = FALSE;
break;
+ case 's': /* Specify table signature (Only supported for CDAT table) */
+
+ /* Get the required argument */
+
+ if (AcpiGetoptArgument (argc, argv))
+ {
+ return (-1);
+ }
+
+ /* Check for exact string "CDAT" (upper or lower case) */
+
+ AcpiGbl_CDAT = ACPI_CAST_PTR (char, &AcpiGbl_Optarg);
+ if (AcpiUtStricmp (AcpiGbl_Optarg, ACPI_SIG_CDAT))
+ {
+ printf ("\nUnknown table signature: %s\n", AcpiGbl_Optarg);
+ return (-1);
+ }
+
+ AcpiGbl_CDAT = malloc (5);
+ AcpiUtSafeStrncpy ((char *) AcpiGbl_CDAT, ACPI_SIG_CDAT, 5);
+ break;
+
default:
printf ("Unknown option: -d%s\n", AcpiGbl_Optarg);
@@ -837,7 +859,7 @@ AslDoOptions (
AslGbl_HexOutputFlag = HEX_OUTPUT_C;
break;
- case 'p': /* data table flex/bison prototype */
+ case 'p': /* data table flex/bison prototype */
AslGbl_DtLexBisonPrototype = TRUE;
break;