Print this page
update to acpica-unix2-20140114
update to acpica-unix2-20131218
acpica-unix2-20130823
PANKOVs restructure

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/intel/sys/acpi/actbl2.h
          +++ new/usr/src/common/acpica/include/actbl2.h
   1    1  /******************************************************************************
   2    2   *
   3    3   * Name: actbl2.h - ACPI Table Definitions (tables not in ACPI spec)
   4    4   *
   5    5   *****************************************************************************/
   6    6  
   7    7  /*
   8      - * Copyright (C) 2000 - 2011, Intel Corp.
        8 + * Copyright (C) 2000 - 2014, Intel Corp.
   9    9   * All rights reserved.
  10   10   *
  11   11   * Redistribution and use in source and binary forms, with or without
  12   12   * modification, are permitted provided that the following conditions
  13   13   * are met:
  14   14   * 1. Redistributions of source code must retain the above copyright
  15   15   *    notice, this list of conditions, and the following disclaimer,
  16   16   *    without modification.
  17   17   * 2. Redistributions in binary form must reproduce at minimum a disclaimer
  18   18   *    substantially similar to the "NO WARRANTY" disclaimer below
↓ open down ↓ 39 lines elided ↑ open up ↑
  58   58   ******************************************************************************/
  59   59  
  60   60  
  61   61  /*
  62   62   * Values for description table header signatures for tables defined in this
  63   63   * file. Useful because they make it more difficult to inadvertently type in
  64   64   * the wrong signature.
  65   65   */
  66   66  #define ACPI_SIG_ASF            "ASF!"      /* Alert Standard Format table */
  67   67  #define ACPI_SIG_BOOT           "BOOT"      /* Simple Boot Flag Table */
       68 +#define ACPI_SIG_CSRT           "CSRT"      /* Core System Resource Table */
       69 +#define ACPI_SIG_DBG2           "DBG2"      /* Debug Port table type 2 */
  68   70  #define ACPI_SIG_DBGP           "DBGP"      /* Debug Port table */
  69   71  #define ACPI_SIG_DMAR           "DMAR"      /* DMA Remapping table */
  70   72  #define ACPI_SIG_HPET           "HPET"      /* High Precision Event Timer table */
  71   73  #define ACPI_SIG_IBFT           "IBFT"      /* iSCSI Boot Firmware Table */
  72   74  #define ACPI_SIG_IVRS           "IVRS"      /* I/O Virtualization Reporting Structure */
  73   75  #define ACPI_SIG_MCFG           "MCFG"      /* PCI Memory Mapped Configuration table */
  74   76  #define ACPI_SIG_MCHI           "MCHI"      /* Management Controller Host Interface table */
       77 +#define ACPI_SIG_MTMR           "MTMR"      /* MID Timer table */
  75   78  #define ACPI_SIG_SLIC           "SLIC"      /* Software Licensing Description Table */
  76   79  #define ACPI_SIG_SPCR           "SPCR"      /* Serial Port Console Redirection table */
  77   80  #define ACPI_SIG_SPMI           "SPMI"      /* Server Platform Management Interface table */
  78   81  #define ACPI_SIG_TCPA           "TCPA"      /* Trusted Computing Platform Alliance table */
  79   82  #define ACPI_SIG_UEFI           "UEFI"      /* Uefi Boot Optimization Table */
       83 +#define ACPI_SIG_VRTC           "VRTC"      /* Virtual Real Time Clock Table */
  80   84  #define ACPI_SIG_WAET           "WAET"      /* Windows ACPI Emulated devices Table */
  81   85  #define ACPI_SIG_WDAT           "WDAT"      /* Watchdog Action Table */
  82   86  #define ACPI_SIG_WDDT           "WDDT"      /* Watchdog Timer Description Table */
  83   87  #define ACPI_SIG_WDRT           "WDRT"      /* Watchdog Resource Table */
  84   88  
  85   89  #ifdef ACPI_UNDEFINED_TABLES
  86   90  /*
  87   91   * These tables have been seen in the field, but no definition has been found
  88   92   */
  89   93  #define ACPI_SIG_ATKG           "ATKG"
↓ open down ↓ 1 lines elided ↑ open up ↑
  91   95  #define ACPI_SIG_IEIT           "IEIT"
  92   96  #endif
  93   97  
  94   98  /*
  95   99   * All tables must be byte-packed to match the ACPI specification, since
  96  100   * the tables are provided by the system BIOS.
  97  101   */
  98  102  #pragma pack(1)
  99  103  
 100  104  /*
 101      - * Note about bitfields: The UINT8 type is used for bitfields in ACPI tables.
 102      - * This is the only type that is even remotely portable. Anything else is not
 103      - * portable, so do not use any other bitfield types.
      105 + * Note: C bitfields are not used for this reason:
      106 + *
      107 + * "Bitfields are great and easy to read, but unfortunately the C language
      108 + * does not specify the layout of bitfields in memory, which means they are
      109 + * essentially useless for dealing with packed data in on-disk formats or
      110 + * binary wire protocols." (Or ACPI tables and buffers.) "If you ask me,
      111 + * this decision was a design error in C. Ritchie could have picked an order
      112 + * and stuck with it." Norman Ramsey.
      113 + * See http://stackoverflow.com/a/1053662/41661
 104  114   */
 105  115  
 106  116  
 107  117  /*******************************************************************************
 108  118   *
 109  119   * ASF - Alert Standard Format table (Signature "ASF!")
 110  120   *       Revision 0x10
 111  121   *
 112  122   * Conforms to the Alert Standard Format Specification V2.0, 23 April 2003
 113  123   *
↓ open down ↓ 143 lines elided ↑ open up ↑
 257  267  {
 258  268      ACPI_TABLE_HEADER       Header;             /* Common ACPI table header */
 259  269      UINT8                   CmosIndex;          /* Index in CMOS RAM for the boot register */
 260  270      UINT8                   Reserved[3];
 261  271  
 262  272  } ACPI_TABLE_BOOT;
 263  273  
 264  274  
 265  275  /*******************************************************************************
 266  276   *
      277 + * CSRT - Core System Resource Table
      278 + *        Version 0
      279 + *
      280 + * Conforms to the "Core System Resource Table (CSRT)", November 14, 2011
      281 + *
      282 + ******************************************************************************/
      283 +
      284 +typedef struct acpi_table_csrt
      285 +{
      286 +    ACPI_TABLE_HEADER       Header;             /* Common ACPI table header */
      287 +
      288 +} ACPI_TABLE_CSRT;
      289 +
      290 +
      291 +/* Resource Group subtable */
      292 +
      293 +typedef struct acpi_csrt_group
      294 +{
      295 +    UINT32                  Length;
      296 +    UINT32                  VendorId;
      297 +    UINT32                  SubvendorId;
      298 +    UINT16                  DeviceId;
      299 +    UINT16                  SubdeviceId;
      300 +    UINT16                  Revision;
      301 +    UINT16                  Reserved;
      302 +    UINT32                  SharedInfoLength;
      303 +
      304 +    /* Shared data immediately follows (Length = SharedInfoLength) */
      305 +
      306 +} ACPI_CSRT_GROUP;
      307 +
      308 +/* Shared Info subtable */
      309 +
      310 +typedef struct acpi_csrt_shared_info
      311 +{
      312 +    UINT16                  MajorVersion;
      313 +    UINT16                  MinorVersion;
      314 +    UINT32                  MmioBaseLow;
      315 +    UINT32                  MmioBaseHigh;
      316 +    UINT32                  GsiInterrupt;
      317 +    UINT8                   InterruptPolarity;
      318 +    UINT8                   InterruptMode;
      319 +    UINT8                   NumChannels;
      320 +    UINT8                   DmaAddressWidth;
      321 +    UINT16                  BaseRequestLine;
      322 +    UINT16                  NumHandshakeSignals;
      323 +    UINT32                  MaxBlockSize;
      324 +
      325 +    /* Resource descriptors immediately follow (Length = Group Length - SharedInfoLength) */
      326 +
      327 +} ACPI_CSRT_SHARED_INFO;
      328 +
      329 +/* Resource Descriptor subtable */
      330 +
      331 +typedef struct acpi_csrt_descriptor
      332 +{
      333 +    UINT32                  Length;
      334 +    UINT16                  Type;
      335 +    UINT16                  Subtype;
      336 +    UINT32                  Uid;
      337 +
      338 +    /* Resource-specific information immediately follows */
      339 +
      340 +} ACPI_CSRT_DESCRIPTOR;
      341 +
      342 +
      343 +/* Resource Types */
      344 +
      345 +#define ACPI_CSRT_TYPE_INTERRUPT    0x0001
      346 +#define ACPI_CSRT_TYPE_TIMER        0x0002
      347 +#define ACPI_CSRT_TYPE_DMA          0x0003
      348 +
      349 +/* Resource Subtypes */
      350 +
      351 +#define ACPI_CSRT_XRUPT_LINE        0x0000
      352 +#define ACPI_CSRT_XRUPT_CONTROLLER  0x0001
      353 +#define ACPI_CSRT_TIMER             0x0000
      354 +#define ACPI_CSRT_DMA_CHANNEL       0x0000
      355 +#define ACPI_CSRT_DMA_CONTROLLER    0x0001
      356 +
      357 +
      358 +/*******************************************************************************
      359 + *
      360 + * DBG2 - Debug Port Table 2
      361 + *        Version 0 (Both main table and subtables)
      362 + *
      363 + * Conforms to "Microsoft Debug Port Table 2 (DBG2)", May 22 2012.
      364 + *
      365 + ******************************************************************************/
      366 +
      367 +typedef struct acpi_table_dbg2
      368 +{
      369 +    ACPI_TABLE_HEADER       Header;             /* Common ACPI table header */
      370 +    UINT32                  InfoOffset;
      371 +    UINT32                  InfoCount;
      372 +
      373 +} ACPI_TABLE_DBG2;
      374 +
      375 +
      376 +typedef struct acpi_dbg2_header
      377 +{
      378 +    UINT32                  InfoOffset;
      379 +    UINT32                  InfoCount;
      380 +
      381 +} ACPI_DBG2_HEADER;
      382 +
      383 +
      384 +/* Debug Device Information Subtable */
      385 +
      386 +typedef struct acpi_dbg2_device
      387 +{
      388 +    UINT8                   Revision;
      389 +    UINT16                  Length;
      390 +    UINT8                   RegisterCount;      /* Number of BaseAddress registers */
      391 +    UINT16                  NamepathLength;
      392 +    UINT16                  NamepathOffset;
      393 +    UINT16                  OemDataLength;
      394 +    UINT16                  OemDataOffset;
      395 +    UINT16                  PortType;
      396 +    UINT16                  PortSubtype;
      397 +    UINT16                  Reserved;
      398 +    UINT16                  BaseAddressOffset;
      399 +    UINT16                  AddressSizeOffset;
      400 +    /*
      401 +     * Data that follows:
      402 +     *    BaseAddress (required) - Each in 12-byte Generic Address Structure format.
      403 +     *    AddressSize (required) - Array of UINT32 sizes corresponding to each BaseAddress register.
      404 +     *    Namepath    (required) - Null terminated string. Single dot if not supported.
      405 +     *    OemData     (optional) - Length is OemDataLength.
      406 +     */
      407 +} ACPI_DBG2_DEVICE;
      408 +
      409 +/* Types for PortType field above */
      410 +
      411 +#define ACPI_DBG2_SERIAL_PORT       0x8000
      412 +#define ACPI_DBG2_1394_PORT         0x8001
      413 +#define ACPI_DBG2_USB_PORT          0x8002
      414 +#define ACPI_DBG2_NET_PORT          0x8003
      415 +
      416 +/* Subtypes for PortSubtype field above */
      417 +
      418 +#define ACPI_DBG2_16550_COMPATIBLE  0x0000
      419 +#define ACPI_DBG2_16550_SUBSET      0x0001
      420 +
      421 +#define ACPI_DBG2_1394_STANDARD     0x0000
      422 +
      423 +#define ACPI_DBG2_USB_XHCI          0x0000
      424 +#define ACPI_DBG2_USB_EHCI          0x0001
      425 +
      426 +
      427 +/*******************************************************************************
      428 + *
 267  429   * DBGP - Debug Port table
 268  430   *        Version 1
 269  431   *
 270  432   * Conforms to the "Debug Port Specification", Version 1.00, 2/9/2000
 271  433   *
 272  434   ******************************************************************************/
 273  435  
 274  436  typedef struct acpi_table_dbgp
 275  437  {
 276  438      ACPI_TABLE_HEADER       Header;             /* Common ACPI table header */
↓ open down ↓ 547 lines elided ↑ open up ↑
 824  986      UINT8                   PciSegment;
 825  987      UINT8                   PciBus;
 826  988      UINT8                   PciDevice;
 827  989      UINT8                   PciFunction;
 828  990  
 829  991  } ACPI_TABLE_MCHI;
 830  992  
 831  993  
 832  994  /*******************************************************************************
 833  995   *
      996 + * MTMR - MID Timer Table
      997 + *        Version 1
      998 + *
      999 + * Conforms to "Simple Firmware Interface Specification",
     1000 + * Draft 0.8.2, Oct 19, 2010
     1001 + * NOTE: The ACPI MTMR is equivalent to the SFI MTMR table.
     1002 + *
     1003 + ******************************************************************************/
     1004 +
     1005 +typedef struct acpi_table_mtmr
     1006 +{
     1007 +    ACPI_TABLE_HEADER       Header;             /* Common ACPI table header */
     1008 +
     1009 +} ACPI_TABLE_MTMR;
     1010 +
     1011 +/* MTMR entry */
     1012 +
     1013 +typedef struct acpi_mtmr_entry
     1014 +{
     1015 +    ACPI_GENERIC_ADDRESS    PhysicalAddress;
     1016 +    UINT32                  Frequency;
     1017 +    UINT32                  Irq;
     1018 +
     1019 +} ACPI_MTMR_ENTRY;
     1020 +
     1021 +
     1022 +/*******************************************************************************
     1023 + *
 834 1024   * SLIC - Software Licensing Description Table
 835 1025   *        Version 1
 836 1026   *
 837 1027   * Conforms to "OEM Activation 2.0 for Windows Vista Operating Systems",
 838 1028   * Copyright 2006
 839 1029   *
 840 1030   ******************************************************************************/
 841 1031  
 842 1032  /* Basic SLIC table is only the common ACPI header */
 843 1033  
↓ open down ↓ 179 lines elided ↑ open up ↑
1023 1213  {
1024 1214      ACPI_TABLE_HEADER       Header;             /* Common ACPI table header */
1025 1215      UINT8                   Identifier[16];     /* UUID identifier */
1026 1216      UINT16                  DataOffset;         /* Offset of remaining data in table */
1027 1217  
1028 1218  } ACPI_TABLE_UEFI;
1029 1219  
1030 1220  
1031 1221  /*******************************************************************************
1032 1222   *
     1223 + * VRTC - Virtual Real Time Clock Table
     1224 + *        Version 1
     1225 + *
     1226 + * Conforms to "Simple Firmware Interface Specification",
     1227 + * Draft 0.8.2, Oct 19, 2010
     1228 + * NOTE: The ACPI VRTC is equivalent to The SFI MRTC table.
     1229 + *
     1230 + ******************************************************************************/
     1231 +
     1232 +typedef struct acpi_table_vrtc
     1233 +{
     1234 +    ACPI_TABLE_HEADER       Header;             /* Common ACPI table header */
     1235 +
     1236 +} ACPI_TABLE_VRTC;
     1237 +
     1238 +/* VRTC entry */
     1239 +
     1240 +typedef struct acpi_vrtc_entry
     1241 +{
     1242 +    ACPI_GENERIC_ADDRESS    PhysicalAddress;
     1243 +    UINT32                  Irq;
     1244 +
     1245 +} ACPI_VRTC_ENTRY;
     1246 +
     1247 +
     1248 +/*******************************************************************************
     1249 + *
1033 1250   * WAET - Windows ACPI Emulated devices Table
1034 1251   *        Version 1
1035 1252   *
1036 1253   * Conforms to "Windows ACPI Emulated Devices Table", version 1.0, April 6, 2009
1037 1254   *
1038 1255   ******************************************************************************/
1039 1256  
1040 1257  typedef struct acpi_table_waet
1041 1258  {
1042 1259      ACPI_TABLE_HEADER       Header;             /* Common ACPI table header */
↓ open down ↓ 154 lines elided ↑ open up ↑
1197 1414      UINT8                   Units;
1198 1415  
1199 1416  } ACPI_TABLE_WDRT;
1200 1417  
1201 1418  
1202 1419  /* Reset to default packing */
1203 1420  
1204 1421  #pragma pack()
1205 1422  
1206 1423  #endif /* __ACTBL2_H__ */
1207      -
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX