Home | History | Annotate | Line # | Download | only in include
acconfig.h revision 1.1.1.2
      1      1.1  jruoho /******************************************************************************
      2      1.1  jruoho  *
      3      1.1  jruoho  * Name: acconfig.h - Global configuration constants
      4      1.1  jruoho  *
      5      1.1  jruoho  *****************************************************************************/
      6      1.1  jruoho 
      7  1.1.1.2  jruoho /*
      8  1.1.1.2  jruoho  * Copyright (C) 2000 - 2011, Intel Corp.
      9      1.1  jruoho  * All rights reserved.
     10      1.1  jruoho  *
     11  1.1.1.2  jruoho  * Redistribution and use in source and binary forms, with or without
     12  1.1.1.2  jruoho  * modification, are permitted provided that the following conditions
     13  1.1.1.2  jruoho  * are met:
     14  1.1.1.2  jruoho  * 1. Redistributions of source code must retain the above copyright
     15  1.1.1.2  jruoho  *    notice, this list of conditions, and the following disclaimer,
     16  1.1.1.2  jruoho  *    without modification.
     17  1.1.1.2  jruoho  * 2. Redistributions in binary form must reproduce at minimum a disclaimer
     18  1.1.1.2  jruoho  *    substantially similar to the "NO WARRANTY" disclaimer below
     19  1.1.1.2  jruoho  *    ("Disclaimer") and any redistribution must be conditioned upon
     20  1.1.1.2  jruoho  *    including a substantially similar Disclaimer requirement for further
     21  1.1.1.2  jruoho  *    binary redistribution.
     22  1.1.1.2  jruoho  * 3. Neither the names of the above-listed copyright holders nor the names
     23  1.1.1.2  jruoho  *    of any contributors may be used to endorse or promote products derived
     24  1.1.1.2  jruoho  *    from this software without specific prior written permission.
     25  1.1.1.2  jruoho  *
     26  1.1.1.2  jruoho  * Alternatively, this software may be distributed under the terms of the
     27  1.1.1.2  jruoho  * GNU General Public License ("GPL") version 2 as published by the Free
     28  1.1.1.2  jruoho  * Software Foundation.
     29  1.1.1.2  jruoho  *
     30  1.1.1.2  jruoho  * NO WARRANTY
     31  1.1.1.2  jruoho  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
     32  1.1.1.2  jruoho  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
     33  1.1.1.2  jruoho  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR
     34  1.1.1.2  jruoho  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
     35  1.1.1.2  jruoho  * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
     36  1.1.1.2  jruoho  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
     37  1.1.1.2  jruoho  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
     38  1.1.1.2  jruoho  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
     39  1.1.1.2  jruoho  * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
     40  1.1.1.2  jruoho  * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
     41  1.1.1.2  jruoho  * POSSIBILITY OF SUCH DAMAGES.
     42  1.1.1.2  jruoho  */
     43      1.1  jruoho 
     44      1.1  jruoho #ifndef _ACCONFIG_H
     45      1.1  jruoho #define _ACCONFIG_H
     46      1.1  jruoho 
     47      1.1  jruoho 
     48      1.1  jruoho /******************************************************************************
     49      1.1  jruoho  *
     50      1.1  jruoho  * Configuration options
     51      1.1  jruoho  *
     52      1.1  jruoho  *****************************************************************************/
     53      1.1  jruoho 
     54      1.1  jruoho /*
     55      1.1  jruoho  * ACPI_DEBUG_OUTPUT    - This switch enables all the debug facilities of the
     56      1.1  jruoho  *                        ACPI subsystem.  This includes the DEBUG_PRINT output
     57      1.1  jruoho  *                        statements.  When disabled, all DEBUG_PRINT
     58      1.1  jruoho  *                        statements are compiled out.
     59      1.1  jruoho  *
     60      1.1  jruoho  * ACPI_APPLICATION     - Use this switch if the subsystem is going to be run
     61      1.1  jruoho  *                        at the application level.
     62      1.1  jruoho  *
     63      1.1  jruoho  */
     64      1.1  jruoho 
     65      1.1  jruoho /*
     66      1.1  jruoho  * OS name, used for the _OS object.  The _OS object is essentially obsolete,
     67      1.1  jruoho  * but there is a large base of ASL/AML code in existing machines that check
     68      1.1  jruoho  * for the string below.  The use of this string usually guarantees that
     69      1.1  jruoho  * the ASL will execute down the most tested code path.  Also, there is some
     70      1.1  jruoho  * code that will not execute the _OSI method unless _OS matches the string
     71      1.1  jruoho  * below.  Therefore, change this string at your own risk.
     72      1.1  jruoho  */
     73      1.1  jruoho #define ACPI_OS_NAME                    "Microsoft Windows NT"
     74      1.1  jruoho 
     75      1.1  jruoho /* Maximum objects in the various object caches */
     76      1.1  jruoho 
     77      1.1  jruoho #define ACPI_MAX_STATE_CACHE_DEPTH      96          /* State objects */
     78      1.1  jruoho #define ACPI_MAX_PARSE_CACHE_DEPTH      96          /* Parse tree objects */
     79      1.1  jruoho #define ACPI_MAX_EXTPARSE_CACHE_DEPTH   96          /* Parse tree objects */
     80      1.1  jruoho #define ACPI_MAX_OBJECT_CACHE_DEPTH     96          /* Interpreter operand objects */
     81      1.1  jruoho #define ACPI_MAX_NAMESPACE_CACHE_DEPTH  96          /* Namespace objects */
     82      1.1  jruoho 
     83      1.1  jruoho /*
     84      1.1  jruoho  * Should the subsystem abort the loading of an ACPI table if the
     85      1.1  jruoho  * table checksum is incorrect?
     86      1.1  jruoho  */
     87      1.1  jruoho #define ACPI_CHECKSUM_ABORT             FALSE
     88      1.1  jruoho 
     89      1.1  jruoho 
     90      1.1  jruoho /******************************************************************************
     91      1.1  jruoho  *
     92      1.1  jruoho  * Subsystem Constants
     93      1.1  jruoho  *
     94      1.1  jruoho  *****************************************************************************/
     95      1.1  jruoho 
     96      1.1  jruoho /* Version of ACPI supported */
     97      1.1  jruoho 
     98      1.1  jruoho #define ACPI_CA_SUPPORT_LEVEL           3
     99      1.1  jruoho 
    100      1.1  jruoho /* Maximum count for a semaphore object */
    101      1.1  jruoho 
    102      1.1  jruoho #define ACPI_MAX_SEMAPHORE_COUNT        256
    103      1.1  jruoho 
    104      1.1  jruoho /* Maximum object reference count (detects object deletion issues) */
    105      1.1  jruoho 
    106      1.1  jruoho #define ACPI_MAX_REFERENCE_COUNT        0x800
    107      1.1  jruoho 
    108      1.1  jruoho /* Default page size for use in mapping memory for operation regions */
    109      1.1  jruoho 
    110      1.1  jruoho #define ACPI_DEFAULT_PAGE_SIZE          4096    /* Must be power of 2 */
    111      1.1  jruoho 
    112      1.1  jruoho /* OwnerId tracking. 8 entries allows for 255 OwnerIds */
    113      1.1  jruoho 
    114      1.1  jruoho #define ACPI_NUM_OWNERID_MASKS          8
    115      1.1  jruoho 
    116      1.1  jruoho /* Size of the root table array is increased by this increment */
    117      1.1  jruoho 
    118      1.1  jruoho #define ACPI_ROOT_TABLE_SIZE_INCREMENT  4
    119      1.1  jruoho 
    120      1.1  jruoho /* Maximum number of While() loop iterations before forced abort */
    121      1.1  jruoho 
    122      1.1  jruoho #define ACPI_MAX_LOOP_ITERATIONS        0xFFFF
    123      1.1  jruoho 
    124      1.1  jruoho /* Maximum sleep allowed via Sleep() operator */
    125      1.1  jruoho 
    126      1.1  jruoho #define ACPI_MAX_SLEEP                  20000   /* Two seconds */
    127      1.1  jruoho 
    128      1.1  jruoho 
    129      1.1  jruoho /******************************************************************************
    130      1.1  jruoho  *
    131      1.1  jruoho  * ACPI Specification constants (Do not change unless the specification changes)
    132      1.1  jruoho  *
    133      1.1  jruoho  *****************************************************************************/
    134      1.1  jruoho 
    135      1.1  jruoho /* Method info (in WALK_STATE), containing local variables and argumetns */
    136      1.1  jruoho 
    137      1.1  jruoho #define ACPI_METHOD_NUM_LOCALS          8
    138      1.1  jruoho #define ACPI_METHOD_MAX_LOCAL           7
    139      1.1  jruoho 
    140      1.1  jruoho #define ACPI_METHOD_NUM_ARGS            7
    141      1.1  jruoho #define ACPI_METHOD_MAX_ARG             6
    142      1.1  jruoho 
    143      1.1  jruoho /*
    144      1.1  jruoho  * Operand Stack (in WALK_STATE), Must be large enough to contain METHOD_MAX_ARG
    145      1.1  jruoho  */
    146      1.1  jruoho #define ACPI_OBJ_NUM_OPERANDS           8
    147      1.1  jruoho #define ACPI_OBJ_MAX_OPERAND            7
    148      1.1  jruoho 
    149      1.1  jruoho /* Number of elements in the Result Stack frame, can be an arbitrary value */
    150      1.1  jruoho 
    151      1.1  jruoho #define ACPI_RESULTS_FRAME_OBJ_NUM      8
    152      1.1  jruoho 
    153      1.1  jruoho /*
    154      1.1  jruoho  * Maximal number of elements the Result Stack can contain,
    155      1.1  jruoho  * it may be an arbitray value not exceeding the types of
    156      1.1  jruoho  * ResultSize and ResultCount (now UINT8).
    157      1.1  jruoho  */
    158      1.1  jruoho #define ACPI_RESULTS_OBJ_NUM_MAX        255
    159      1.1  jruoho 
    160      1.1  jruoho /* Constants used in searching for the RSDP in low memory */
    161      1.1  jruoho 
    162      1.1  jruoho #define ACPI_EBDA_PTR_LOCATION          0x0000040E     /* Physical Address */
    163      1.1  jruoho #define ACPI_EBDA_PTR_LENGTH            2
    164      1.1  jruoho #define ACPI_EBDA_WINDOW_SIZE           1024
    165      1.1  jruoho #define ACPI_HI_RSDP_WINDOW_BASE        0x000E0000     /* Physical Address */
    166      1.1  jruoho #define ACPI_HI_RSDP_WINDOW_SIZE        0x00020000
    167      1.1  jruoho #define ACPI_RSDP_SCAN_STEP             16
    168      1.1  jruoho 
    169      1.1  jruoho /* Operation regions */
    170      1.1  jruoho 
    171      1.1  jruoho #define ACPI_NUM_PREDEFINED_REGIONS     9
    172      1.1  jruoho #define ACPI_USER_REGION_BEGIN          0x80
    173      1.1  jruoho 
    174      1.1  jruoho /* Maximum SpaceIds for Operation Regions */
    175      1.1  jruoho 
    176      1.1  jruoho #define ACPI_MAX_ADDRESS_SPACE          255
    177      1.1  jruoho 
    178      1.1  jruoho /* Array sizes.  Used for range checking also */
    179      1.1  jruoho 
    180      1.1  jruoho #define ACPI_MAX_MATCH_OPCODE           5
    181      1.1  jruoho 
    182      1.1  jruoho /* RSDP checksums */
    183      1.1  jruoho 
    184      1.1  jruoho #define ACPI_RSDP_CHECKSUM_LENGTH       20
    185      1.1  jruoho #define ACPI_RSDP_XCHECKSUM_LENGTH      36
    186      1.1  jruoho 
    187      1.1  jruoho /* SMBus and IPMI bidirectional buffer size */
    188      1.1  jruoho 
    189      1.1  jruoho #define ACPI_SMBUS_BUFFER_SIZE          34
    190      1.1  jruoho #define ACPI_IPMI_BUFFER_SIZE           66
    191      1.1  jruoho 
    192      1.1  jruoho /* _SxD and _SxW control methods */
    193      1.1  jruoho 
    194      1.1  jruoho #define ACPI_NUM_SxD_METHODS            4
    195      1.1  jruoho #define ACPI_NUM_SxW_METHODS            5
    196      1.1  jruoho 
    197      1.1  jruoho 
    198      1.1  jruoho /******************************************************************************
    199      1.1  jruoho  *
    200      1.1  jruoho  * ACPI AML Debugger
    201      1.1  jruoho  *
    202      1.1  jruoho  *****************************************************************************/
    203      1.1  jruoho 
    204      1.1  jruoho #define ACPI_DEBUGGER_MAX_ARGS          8  /* Must be max method args + 1 */
    205      1.1  jruoho 
    206      1.1  jruoho #define ACPI_DEBUGGER_COMMAND_PROMPT    '-'
    207      1.1  jruoho #define ACPI_DEBUGGER_EXECUTE_PROMPT    '%'
    208      1.1  jruoho 
    209      1.1  jruoho 
    210      1.1  jruoho #endif /* _ACCONFIG_H */
    211      1.1  jruoho 
    212