]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - source/tools/acpiexec/aemain.c
Import ACPICA 20130823.
[FreeBSD/FreeBSD.git] / source / tools / acpiexec / aemain.c
1 /******************************************************************************
2  *
3  * Module Name: aemain - Main routine for the AcpiExec utility
4  *
5  *****************************************************************************/
6
7 /*
8  * Copyright (C) 2000 - 2013, Intel Corp.
9  * All rights reserved.
10  *
11  * Redistribution and use in source and binary forms, with or without
12  * modification, are permitted provided that the following conditions
13  * are met:
14  * 1. Redistributions of source code must retain the above copyright
15  *    notice, this list of conditions, and the following disclaimer,
16  *    without modification.
17  * 2. Redistributions in binary form must reproduce at minimum a disclaimer
18  *    substantially similar to the "NO WARRANTY" disclaimer below
19  *    ("Disclaimer") and any redistribution must be conditioned upon
20  *    including a substantially similar Disclaimer requirement for further
21  *    binary redistribution.
22  * 3. Neither the names of the above-listed copyright holders nor the names
23  *    of any contributors may be used to endorse or promote products derived
24  *    from this software without specific prior written permission.
25  *
26  * Alternatively, this software may be distributed under the terms of the
27  * GNU General Public License ("GPL") version 2 as published by the Free
28  * Software Foundation.
29  *
30  * NO WARRANTY
31  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
32  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
33  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR
34  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
35  * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
36  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
37  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
38  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
39  * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
40  * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
41  * POSSIBILITY OF SUCH DAMAGES.
42  */
43
44 #include "aecommon.h"
45
46 #define _COMPONENT          ACPI_TOOLS
47         ACPI_MODULE_NAME    ("aemain")
48
49
50 /* Local prototypes */
51
52 static int
53 AeDoOptions (
54     int                     argc,
55     char                    **argv);
56
57 static ACPI_STATUS
58 AcpiDbRunBatchMode (
59     void);
60
61 static char *
62 FlStrdup (
63     char                    *String);
64
65 static char **
66 AsDoWildcard (
67     char                    *DirectoryPathname,
68     char                    *FileSpecifier);
69
70
71 #define AE_BUFFER_SIZE              1024
72 #define ASL_MAX_FILES               256
73
74 /* Execution modes */
75
76 #define AE_MODE_COMMAND_LOOP        0   /* Normal command execution loop */
77 #define AE_MODE_BATCH_MULTIPLE      1   /* -b option to execute a command line */
78 #define AE_MODE_BATCH_SINGLE        2   /* -m option to execute a single control method */
79
80
81 /* Globals */
82
83 UINT8                       AcpiGbl_RegionFillValue = 0;
84 BOOLEAN                     AcpiGbl_IgnoreErrors = FALSE;
85 BOOLEAN                     AcpiGbl_DbOpt_NoRegionSupport = FALSE;
86 BOOLEAN                     AcpiGbl_DebugTimeout = FALSE;
87 UINT8                       AcpiGbl_UseHwReducedFadt = FALSE;
88 BOOLEAN                     AcpiGbl_DoInterfaceTests = FALSE;
89 static UINT8                AcpiGbl_ExecutionMode = AE_MODE_COMMAND_LOOP;
90 static char                 BatchBuffer[AE_BUFFER_SIZE];    /* Batch command buffer */
91 static char                 *FileList[ASL_MAX_FILES];
92 static AE_TABLE_DESC        *AeTableListHead = NULL;
93
94 #define ACPIEXEC_NAME               "AML Execution/Debug Utility"
95 #define AE_SUPPORTED_OPTIONS        "?b:d:e:f:ghm^orv^:x:"
96
97
98 /******************************************************************************
99  *
100  * FUNCTION:    usage
101  *
102  * PARAMETERS:  None
103  *
104  * RETURN:      None
105  *
106  * DESCRIPTION: Print a usage message
107  *
108  *****************************************************************************/
109
110 static void
111 usage (
112     void)
113 {
114
115     ACPI_USAGE_HEADER ("acpiexec [options] AMLfile1 AMLfile2 ...");
116
117     ACPI_OPTION ("-b \"CommandLine\"",  "Batch mode command line execution (cmd1;cmd2;...)");
118     ACPI_OPTION ("-h -?",               "Display this help message");
119     ACPI_OPTION ("-m [Method]",         "Batch mode method execution. Default=MAIN");
120     printf ("\n");
121
122     ACPI_OPTION ("-da",                 "Disable method abort on error");
123     ACPI_OPTION ("-di",                 "Disable execution of STA/INI methods during init");
124     ACPI_OPTION ("-do",                 "Disable Operation Region address simulation");
125     ACPI_OPTION ("-dr",                 "Disable repair of method return values");
126     ACPI_OPTION ("-dt",                 "Disable allocation tracking (performance)");
127     printf ("\n");
128
129     ACPI_OPTION ("-ef",                 "Enable display of final memory statistics");
130     ACPI_OPTION ("-ei",                 "Enable additional tests for ACPICA interfaces");
131     ACPI_OPTION ("-em",                 "Enable Interpreter Serialized Mode");
132     ACPI_OPTION ("-es",                 "Enable Interpreter Slack Mode");
133     ACPI_OPTION ("-et",                 "Enable debug semaphore timeout");
134     printf ("\n");
135
136     ACPI_OPTION ("-f <Value>",          "Operation Region initialization fill value");
137     ACPI_OPTION ("-r",                  "Use hardware-reduced FADT V5");
138     ACPI_OPTION ("-v",                  "Display version information");
139     ACPI_OPTION ("-vi",                 "Verbose initialization output");
140     ACPI_OPTION ("-vr",                 "Verbose region handler output");
141     ACPI_OPTION ("-x <DebugLevel>",     "Debug output level");
142 }
143
144
145 /******************************************************************************
146  *
147  * FUNCTION:    AeDoOptions
148  *
149  * PARAMETERS:  argc/argv           - Standard argc/argv
150  *
151  * RETURN:      Status
152  *
153  * DESCRIPTION: Command line option processing
154  *
155  *****************************************************************************/
156
157 static int
158 AeDoOptions (
159     int                     argc,
160     char                    **argv)
161 {
162     int                     j;
163
164
165     while ((j = AcpiGetopt (argc, argv, AE_SUPPORTED_OPTIONS)) != EOF) switch (j)
166     {
167     case 'b':
168
169         if (strlen (AcpiGbl_Optarg) > (AE_BUFFER_SIZE -1))
170         {
171             printf ("**** The length of command line (%u) exceeded maximum (%u)\n",
172                 (UINT32) strlen (AcpiGbl_Optarg), (AE_BUFFER_SIZE -1));
173             return (-1);
174         }
175         AcpiGbl_ExecutionMode = AE_MODE_BATCH_MULTIPLE;
176         strcpy (BatchBuffer, AcpiGbl_Optarg);
177         break;
178
179     case 'd':
180
181         switch (AcpiGbl_Optarg[0])
182         {
183         case 'a':
184
185             AcpiGbl_IgnoreErrors = TRUE;
186             break;
187
188         case 'i':
189
190             AcpiGbl_DbOpt_ini_methods = FALSE;
191             break;
192
193         case 'o':
194
195             AcpiGbl_DbOpt_NoRegionSupport = TRUE;
196             break;
197
198         case 'r':
199
200             AcpiGbl_DisableAutoRepair = TRUE;
201             break;
202
203         case 't':
204
205             #ifdef ACPI_DBG_TRACK_ALLOCATIONS
206                 AcpiGbl_DisableMemTracking = TRUE;
207             #endif
208             break;
209
210         default:
211
212             printf ("Unknown option: -d%s\n", AcpiGbl_Optarg);
213             return (-1);
214         }
215         break;
216
217     case 'e':
218
219         switch (AcpiGbl_Optarg[0])
220         {
221         case 'f':
222
223             #ifdef ACPI_DBG_TRACK_ALLOCATIONS
224                 AcpiGbl_DisplayFinalMemStats = TRUE;
225             #endif
226             break;
227
228         case 'i':
229
230             AcpiGbl_DoInterfaceTests = TRUE;
231             break;
232
233         case 'm':
234
235             AcpiGbl_AllMethodsSerialized = TRUE;
236             printf ("Enabling AML Interpreter serialized mode\n");
237             break;
238
239         case 's':
240
241             AcpiGbl_EnableInterpreterSlack = TRUE;
242             printf ("Enabling AML Interpreter slack mode\n");
243             break;
244
245         case 't':
246
247             AcpiGbl_DebugTimeout = TRUE;
248             break;
249
250         default:
251
252             printf ("Unknown option: -e%s\n", AcpiGbl_Optarg);
253             return (-1);
254         }
255         break;
256
257     case 'f':
258
259         AcpiGbl_RegionFillValue = (UINT8) strtoul (AcpiGbl_Optarg, NULL, 0);
260         break;
261
262     case 'g':
263
264         AcpiGbl_DbOpt_tables = TRUE;
265         AcpiGbl_DbFilename = NULL;
266         break;
267
268     case 'h':
269     case '?':
270
271         usage();
272         return (0);
273
274     case 'm':
275
276         AcpiGbl_ExecutionMode = AE_MODE_BATCH_SINGLE;
277         switch (AcpiGbl_Optarg[0])
278         {
279         case '^':
280
281             strcpy (BatchBuffer, "MAIN");
282             break;
283
284         default:
285
286             strcpy (BatchBuffer, AcpiGbl_Optarg);
287             break;
288         }
289         break;
290
291     case 'o':
292
293         AcpiGbl_DbOpt_disasm = TRUE;
294         AcpiGbl_DbOpt_stats = TRUE;
295         break;
296
297     case 'r':
298
299         AcpiGbl_UseHwReducedFadt = TRUE;
300         printf ("Using ACPI 5.0 Hardware Reduced Mode via version 5 FADT\n");
301         break;
302
303     case 'v':
304
305         switch (AcpiGbl_Optarg[0])
306         {
307         case '^':  /* -v: (Version): signon already emitted, just exit */
308
309             exit (0);
310
311         case 'i':
312
313             AcpiDbgLevel |= ACPI_LV_INIT_NAMES;
314             break;
315
316         case 'r':
317
318             AcpiGbl_DisplayRegionAccess = TRUE;
319             break;
320
321         default:
322
323             printf ("Unknown option: -v%s\n", AcpiGbl_Optarg);
324             return (-1);
325         }
326         break;
327
328     case 'x':
329
330         AcpiDbgLevel = strtoul (AcpiGbl_Optarg, NULL, 0);
331         AcpiGbl_DbConsoleDebugLevel = AcpiDbgLevel;
332         printf ("Debug Level: 0x%8.8X\n", AcpiDbgLevel);
333         break;
334
335     default:
336
337         usage();
338         return (-1);
339     }
340
341     return (0);
342 }
343
344
345 /******************************************************************************
346  *
347  * FUNCTION:    main
348  *
349  * PARAMETERS:  argc, argv
350  *
351  * RETURN:      Status
352  *
353  * DESCRIPTION: Main routine for AcpiExec utility
354  *
355  *****************************************************************************/
356
357 int ACPI_SYSTEM_XFACE
358 main (
359     int                     argc,
360     char                    **argv)
361 {
362     ACPI_STATUS             Status;
363     UINT32                  InitFlags;
364     ACPI_TABLE_HEADER       *Table = NULL;
365     UINT32                  TableCount;
366     AE_TABLE_DESC           *TableDesc;
367     char                    **WildcardList;
368     char                    *Filename;
369     char                    *Directory;
370     char                    *FullPathname;
371
372
373     ACPI_DEBUG_INITIALIZE (); /* For debug version only */
374
375     printf (ACPI_COMMON_SIGNON (ACPIEXEC_NAME));
376     if (argc < 2)
377     {
378         usage ();
379         return (0);
380     }
381
382     signal (SIGINT, AeCtrlCHandler);
383
384     /* Init globals */
385
386     AcpiDbgLevel = ACPI_NORMAL_DEFAULT;
387     AcpiDbgLayer = 0xFFFFFFFF;
388
389     /* Init ACPI and start debugger thread */
390
391     Status = AcpiInitializeSubsystem ();
392     AE_CHECK_OK (AcpiInitializeSubsystem, Status);
393     if (ACPI_FAILURE (Status))
394     {
395         return (-1);
396     }
397
398     /* Get the command line options */
399
400     if (AeDoOptions (argc, argv))
401     {
402         return (-1);
403     }
404
405     /* The remaining arguments are filenames for ACPI tables */
406
407     if (argv[AcpiGbl_Optind])
408     {
409         AcpiGbl_DbOpt_tables = TRUE;
410         TableCount = 0;
411
412         /* Get each of the ACPI table files on the command line */
413
414         while (argv[AcpiGbl_Optind])
415         {
416             /* Split incoming path into a directory/filename combo */
417
418             Status = FlSplitInputPathname (argv[AcpiGbl_Optind],
419                 &Directory, &Filename);
420             if (ACPI_FAILURE (Status))
421             {
422                 return (-1);
423             }
424
425             /* Expand wildcards (Windows only) */
426
427             WildcardList = AsDoWildcard (Directory, Filename);
428             if (!WildcardList)
429             {
430                 return (-1);
431             }
432
433             while (*WildcardList)
434             {
435                 FullPathname = AcpiOsAllocate (
436                     strlen (Directory) + strlen (*WildcardList) + 1);
437
438                 /* Construct a full path to the file */
439
440                 strcpy (FullPathname, Directory);
441                 strcat (FullPathname, *WildcardList);
442
443                 /* Get one table */
444
445                 Status = AcpiDbReadTableFromFile (FullPathname, &Table);
446                 if (ACPI_FAILURE (Status))
447                 {
448                     printf ("**** Could not get input table %s, %s\n",
449                         FullPathname, AcpiFormatException (Status));
450                     goto EnterDebugger;
451                 }
452
453                 AcpiOsFree (FullPathname);
454                 AcpiOsFree (*WildcardList);
455                 *WildcardList = NULL;
456                 WildcardList++;
457
458                 /* Ignore non-AML tables, we can't use them. Except for an FADT */
459
460                 if (!ACPI_COMPARE_NAME (Table->Signature, ACPI_SIG_FADT) &&
461                     !AcpiUtIsAmlTable (Table))
462                 {
463                     ACPI_WARNING ((AE_INFO,
464                         "Table %4.4s is not an AML table, ignoring",
465                         Table->Signature));
466                     AcpiOsFree (Table);
467                     continue;
468                 }
469
470                 /* Allocate and link a table descriptor */
471
472                 TableDesc = AcpiOsAllocate (sizeof (AE_TABLE_DESC));
473                 TableDesc->Table = Table;
474                 TableDesc->Next = AeTableListHead;
475                 AeTableListHead = TableDesc;
476
477                 TableCount++;
478             }
479
480             AcpiGbl_Optind++;
481         }
482
483         /* Build a local RSDT with all tables and let ACPICA process the RSDT */
484
485         Status = AeBuildLocalTables (TableCount, AeTableListHead);
486         if (ACPI_FAILURE (Status))
487         {
488             return (-1);
489         }
490
491         Status = AeInstallTables ();
492         if (ACPI_FAILURE (Status))
493         {
494             printf ("**** Could not load ACPI tables, %s\n",
495                 AcpiFormatException (Status));
496             goto EnterDebugger;
497         }
498
499         /*
500          * Install most of the handlers.
501          * Override some default region handlers, especially SystemMemory
502          */
503         Status = AeInstallEarlyHandlers ();
504         if (ACPI_FAILURE (Status))
505         {
506             goto EnterDebugger;
507         }
508
509         /* Setup initialization flags for ACPICA */
510
511         InitFlags = (ACPI_NO_HANDLER_INIT | ACPI_NO_ACPI_ENABLE);
512         if (!AcpiGbl_DbOpt_ini_methods)
513         {
514             InitFlags |= (ACPI_NO_DEVICE_INIT | ACPI_NO_OBJECT_INIT);
515         }
516
517         /*
518          * Main initialization for ACPICA subsystem
519          * TBD: Need a way to call this after the ACPI table "LOAD" command
520          */
521         Status = AcpiEnableSubsystem (InitFlags);
522         if (ACPI_FAILURE (Status))
523         {
524             printf ("**** Could not EnableSubsystem, %s\n",
525                 AcpiFormatException (Status));
526             goto EnterDebugger;
527         }
528
529         /*
530          * Install handlers for "device driver" space IDs (EC,SMBus, etc.)
531          * and fixed event handlers
532          */
533         AeInstallLateHandlers ();
534
535         /* Finish the ACPICA initialization */
536
537         Status = AcpiInitializeObjects (InitFlags);
538         if (ACPI_FAILURE (Status))
539         {
540             printf ("**** Could not InitializeObjects, %s\n",
541                 AcpiFormatException (Status));
542             goto EnterDebugger;
543         }
544
545         AeMiscellaneousTests ();
546     }
547
548 EnterDebugger:
549
550     /* Exit if error above and we are in one of the batch modes */
551
552     if (ACPI_FAILURE (Status) && (AcpiGbl_ExecutionMode > 0))
553     {
554         return (-1);
555     }
556
557     /* Run a batch command or enter the command loop */
558
559     switch (AcpiGbl_ExecutionMode)
560     {
561     default:
562     case AE_MODE_COMMAND_LOOP:
563
564         AcpiDbUserCommands (ACPI_DEBUGGER_COMMAND_PROMPT, NULL);
565         break;
566
567     case AE_MODE_BATCH_MULTIPLE:
568
569         AcpiDbRunBatchMode ();
570         break;
571
572     case AE_MODE_BATCH_SINGLE:
573
574         AcpiDbExecute (BatchBuffer, NULL, NULL, EX_NO_SINGLE_STEP);
575         break;
576     }
577
578     return (0);
579 }
580
581
582 /******************************************************************************
583  *
584  * FUNCTION:    AcpiDbRunBatchMode
585  *
586  * PARAMETERS:  BatchCommandLine    - A semicolon separated list of commands
587  *                                    to be executed.
588  *                                    Use only commas to separate elements of
589  *                                    particular command.
590  * RETURN:      Status
591  *
592  * DESCRIPTION: For each command of list separated by ';' prepare the command
593  *              buffer and pass it to AcpiDbCommandDispatch.
594  *
595  *****************************************************************************/
596
597 static ACPI_STATUS
598 AcpiDbRunBatchMode (
599     void)
600 {
601     ACPI_STATUS             Status;
602     char                    *Ptr = BatchBuffer;
603     char                    *Cmd = Ptr;
604     UINT8                   Run = 0;
605
606
607     AcpiGbl_MethodExecuting = FALSE;
608     AcpiGbl_StepToNextCall = FALSE;
609
610     while (*Ptr)
611     {
612         if (*Ptr == ',')
613         {
614             /* Convert commas to spaces */
615             *Ptr = ' ';
616         }
617         else if (*Ptr == ';')
618         {
619             *Ptr = '\0';
620             Run = 1;
621         }
622
623         Ptr++;
624
625         if (Run || (*Ptr == '\0'))
626         {
627             (void) AcpiDbCommandDispatch (Cmd, NULL, NULL);
628             Run = 0;
629             Cmd = Ptr;
630         }
631     }
632
633     Status = AcpiTerminate ();
634     return (Status);
635 }
636
637
638 /******************************************************************************
639  *
640  * FUNCTION:    FlStrdup
641  *
642  * DESCRIPTION: Local strdup function
643  *
644  *****************************************************************************/
645
646 static char *
647 FlStrdup (
648     char                    *String)
649 {
650     char                    *NewString;
651
652
653     NewString = AcpiOsAllocate (strlen (String) + 1);
654     if (!NewString)
655     {
656         return (NULL);
657     }
658
659     strcpy (NewString, String);
660     return (NewString);
661 }
662
663
664 /******************************************************************************
665  *
666  * FUNCTION:    FlSplitInputPathname
667  *
668  * PARAMETERS:  InputFilename       - The user-specified ASL source file to be
669  *                                    compiled
670  *              OutDirectoryPath    - Where the directory path prefix is
671  *                                    returned
672  *              OutFilename         - Where the filename part is returned
673  *
674  * RETURN:      Status
675  *
676  * DESCRIPTION: Split the input path into a directory and filename part
677  *              1) Directory part used to open include files
678  *              2) Filename part used to generate output filenames
679  *
680  *****************************************************************************/
681
682 ACPI_STATUS
683 FlSplitInputPathname (
684     char                    *InputPath,
685     char                    **OutDirectoryPath,
686     char                    **OutFilename)
687 {
688     char                    *Substring;
689     char                    *DirectoryPath;
690     char                    *Filename;
691
692
693     *OutDirectoryPath = NULL;
694     *OutFilename = NULL;
695
696     if (!InputPath)
697     {
698         return (AE_OK);
699     }
700
701     /* Get the path to the input filename's directory */
702
703     DirectoryPath = FlStrdup (InputPath);
704     if (!DirectoryPath)
705     {
706         return (AE_NO_MEMORY);
707     }
708
709     /* Convert backslashes to slashes in the entire path */
710
711     UtConvertBackslashes (DirectoryPath);
712
713     /* Backup to last slash or colon */
714
715     Substring = strrchr (DirectoryPath, '/');
716     if (!Substring)
717     {
718         Substring = strrchr (DirectoryPath, ':');
719     }
720
721     /* Extract the simple filename */
722
723     if (!Substring)
724     {
725         DirectoryPath[0] = 0;
726         Filename = FlStrdup (InputPath);
727     }
728     else
729     {
730         Filename = FlStrdup (Substring + 1);
731         *(Substring + 1) = 0;
732     }
733
734     if (!Filename)
735     {
736         return (AE_NO_MEMORY);
737     }
738
739     *OutDirectoryPath = DirectoryPath;
740     *OutFilename = Filename;
741     return (AE_OK);
742 }
743
744
745 /******************************************************************************
746  *
747  * FUNCTION:    AsDoWildcard
748  *
749  * PARAMETERS:  DirectoryPathname   - Path to parent directory
750  *              FileSpecifier       - the wildcard specification (*.c, etc.)
751  *
752  * RETURN:      Pointer to a list of filenames
753  *
754  * DESCRIPTION: Process files via wildcards. This function is for the Windows
755  *              case only.
756  *
757  *****************************************************************************/
758
759 static char **
760 AsDoWildcard (
761     char                    *DirectoryPathname,
762     char                    *FileSpecifier)
763 {
764 #ifdef WIN32
765     void                    *DirInfo;
766     char                    *Filename;
767     int                     FileCount;
768
769
770     FileCount = 0;
771
772     /* Open parent directory */
773
774     DirInfo = AcpiOsOpenDirectory (DirectoryPathname, FileSpecifier,
775         REQUEST_FILE_ONLY);
776     if (!DirInfo)
777     {
778         /* Either the directory or file does not exist */
779
780         printf ("File or directory \"%s%s\" does not exist\n",
781             DirectoryPathname, FileSpecifier);
782         return (NULL);
783     }
784
785     /* Process each file that matches the wildcard specification */
786
787     while ((Filename = AcpiOsGetNextFilename (DirInfo)))
788     {
789         /* Add the filename to the file list */
790
791         FileList[FileCount] = AcpiOsAllocate (strlen (Filename) + 1);
792         strcpy (FileList[FileCount], Filename);
793         FileCount++;
794
795         if (FileCount >= ASL_MAX_FILES)
796         {
797             printf ("Max files reached\n");
798             FileList[0] = NULL;
799             return (FileList);
800         }
801     }
802
803     /* Cleanup */
804
805     AcpiOsCloseDirectory (DirInfo);
806     FileList[FileCount] = NULL;
807     return (FileList);
808
809 #else
810     if (!FileSpecifier)
811     {
812         return (NULL);
813     }
814
815     /*
816      * Linux/Unix cases - Wildcards are expanded by the shell automatically.
817      * Just return the filename in a null terminated list
818      */
819     FileList[0] = AcpiOsAllocate (strlen (FileSpecifier) + 1);
820     strcpy (FileList[0], FileSpecifier);
821     FileList[1] = NULL;
822
823     return (FileList);
824 #endif
825 }