1 /******************************************************************************
3 * Name: actbl1.h - Additional ACPI table definitions
5 *****************************************************************************/
8 * Copyright (C) 2000 - 2008, Intel Corp.
11 * Redistribution and use in source and binary forms, with or without
12 * modification, are permitted provided that the following conditions
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.
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.
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.
47 /*******************************************************************************
49 * Additional ACPI Tables
51 * These tables are not consumed directly by the ACPICA subsystem, but are
52 * included here to support device drivers and the AML disassembler.
54 ******************************************************************************/
57 * Values for description table header signatures. Useful because they make
58 * it more difficult to inadvertently type in the wrong signature.
60 #define ACPI_SIG_ASF "ASF!" /* Alert Standard Format table */
61 #define ACPI_SIG_BERT "BERT" /* Boot Error Record Table */
62 #define ACPI_SIG_BOOT "BOOT" /* Simple Boot Flag Table */
63 #define ACPI_SIG_CPEP "CPEP" /* Corrected Platform Error Polling table */
64 #define ACPI_SIG_DBGP "DBGP" /* Debug Port table */
65 #define ACPI_SIG_DMAR "DMAR" /* DMA Remapping table */
66 #define ACPI_SIG_ECDT "ECDT" /* Embedded Controller Boot Resources Table */
67 #define ACPI_SIG_EINJ "EINJ" /* Error Injection table */
68 #define ACPI_SIG_ERST "ERST" /* Error Record Serialization Table */
69 #define ACPI_SIG_HEST "HEST" /* Hardware Error Source Table */
70 #define ACPI_SIG_HPET "HPET" /* High Precision Event Timer table */
71 #define ACPI_SIG_IBFT "IBFT" /* i_sCSI Boot Firmware Table */
72 #define ACPI_SIG_MADT "APIC" /* Multiple APIC Description Table */
73 #define ACPI_SIG_MCFG "MCFG" /* PCI Memory Mapped Configuration table */
74 #define ACPI_SIG_SBST "SBST" /* Smart Battery Specification Table */
75 #define ACPI_SIG_SLIC "SLIC" /* Software Licensing Description Table */
76 #define ACPI_SIG_SLIT "SLIT" /* System Locality Distance Information Table */
77 #define ACPI_SIG_SPCR "SPCR" /* Serial Port Console Redirection table */
78 #define ACPI_SIG_SPMI "SPMI" /* Server Platform Management Interface table */
79 #define ACPI_SIG_SRAT "SRAT" /* System Resource Affinity Table */
80 #define ACPI_SIG_TCPA "TCPA" /* Trusted Computing Platform Alliance table */
81 #define ACPI_SIG_UEFI "UEFI" /* Uefi Boot Optimization Table */
82 #define ACPI_SIG_WDAT "WDAT" /* Watchdog Action Table */
83 #define ACPI_SIG_WDRT "WDRT" /* Watchdog Resource Table */
86 * All tables must be byte-packed to match the ACPI specification, since
87 * the tables are provided by the system BIOS.
92 * Note about bitfields: The u8 type is used for bitfields in ACPI tables.
93 * This is the only type that is even remotely portable. Anything else is not
94 * portable, so do not use any other bitfield types.
97 /* Common Subtable header (used in MADT, SRAT, etc.) */
99 struct acpi_subtable_header
{
104 /* Common Subtable header for WHEA tables (EINJ, ERST, WDAT) */
106 struct acpi_whea_header
{
111 struct acpi_generic_address register_region
;
112 u64 value
; /* Value used with Read/Write register */
113 u64 mask
; /* Bitmask required for this register instruction */
116 /*******************************************************************************
118 * ASF - Alert Standard Format table (Signature "ASF!")
120 * Conforms to the Alert Standard Format Specification V2.0, 23 April 2003
122 ******************************************************************************/
124 struct acpi_table_asf
{
125 struct acpi_table_header header
; /* Common ACPI table header */
128 /* ASF subtable header */
130 struct acpi_asf_header
{
136 /* Values for Type field above */
139 ACPI_ASF_TYPE_INFO
= 0,
140 ACPI_ASF_TYPE_ALERT
= 1,
141 ACPI_ASF_TYPE_CONTROL
= 2,
142 ACPI_ASF_TYPE_BOOT
= 3,
143 ACPI_ASF_TYPE_ADDRESS
= 4,
144 ACPI_ASF_TYPE_RESERVED
= 5
151 /* 0: ASF Information */
153 struct acpi_asf_info
{
154 struct acpi_asf_header header
;
156 u8 min_poll_interval
;
165 struct acpi_asf_alert
{
166 struct acpi_asf_header header
;
173 struct acpi_asf_alert_data
{
188 /* 2: ASF Remote Control */
190 struct acpi_asf_remote
{
191 struct acpi_asf_header header
;
197 struct acpi_asf_control_data
{
204 /* 3: ASF RMCP Boot Options */
206 struct acpi_asf_rmcp
{
207 struct acpi_asf_header header
;
219 struct acpi_asf_address
{
220 struct acpi_asf_header header
;
225 /*******************************************************************************
227 * BERT - Boot Error Record Table
229 ******************************************************************************/
231 struct acpi_table_bert
{
232 struct acpi_table_header header
; /* Common ACPI table header */
233 u32 region_length
; /* Length of the boot error region */
234 u64 address
; /* Physical addresss of the error region */
237 /* Boot Error Region */
239 struct acpi_bert_region
{
247 /* block_status Flags */
249 #define ACPI_BERT_UNCORRECTABLE (1)
250 #define ACPI_BERT_CORRECTABLE (2)
251 #define ACPI_BERT_MULTIPLE_UNCORRECTABLE (4)
252 #define ACPI_BERT_MULTIPLE_CORRECTABLE (8)
254 /*******************************************************************************
256 * BOOT - Simple Boot Flag Table
258 ******************************************************************************/
260 struct acpi_table_boot
{
261 struct acpi_table_header header
; /* Common ACPI table header */
262 u8 cmos_index
; /* Index in CMOS RAM for the boot register */
266 /*******************************************************************************
268 * CPEP - Corrected Platform Error Polling table
270 ******************************************************************************/
272 struct acpi_table_cpep
{
273 struct acpi_table_header header
; /* Common ACPI table header */
279 struct acpi_cpep_polling
{
282 u8 id
; /* Processor ID */
283 u8 eid
; /* Processor EID */
284 u32 interval
; /* Polling interval (msec) */
287 /*******************************************************************************
289 * DBGP - Debug Port table
291 ******************************************************************************/
293 struct acpi_table_dbgp
{
294 struct acpi_table_header header
; /* Common ACPI table header */
295 u8 type
; /* 0=full 16550, 1=subset of 16550 */
297 struct acpi_generic_address debug_port
;
300 /*******************************************************************************
302 * DMAR - DMA Remapping table
303 * From "Intel Virtualization Technology for Directed I/O", Sept. 2007
305 ******************************************************************************/
307 struct acpi_table_dmar
{
308 struct acpi_table_header header
; /* Common ACPI table header */
309 u8 width
; /* Host Address Width */
314 /* DMAR subtable header */
316 struct acpi_dmar_header
{
321 /* Values for subtable type in struct acpi_dmar_header */
323 enum acpi_dmar_type
{
324 ACPI_DMAR_TYPE_HARDWARE_UNIT
= 0,
325 ACPI_DMAR_TYPE_RESERVED_MEMORY
= 1,
326 ACPI_DMAR_TYPE_ATSR
= 2,
327 ACPI_DMAR_TYPE_RESERVED
= 3 /* 3 and greater are reserved */
330 struct acpi_dmar_device_scope
{
338 /* Values for entry_type in struct acpi_dmar_device_scope */
340 enum acpi_dmar_scope_type
{
341 ACPI_DMAR_SCOPE_TYPE_NOT_USED
= 0,
342 ACPI_DMAR_SCOPE_TYPE_ENDPOINT
= 1,
343 ACPI_DMAR_SCOPE_TYPE_BRIDGE
= 2,
344 ACPI_DMAR_SCOPE_TYPE_IOAPIC
= 3,
345 ACPI_DMAR_SCOPE_TYPE_HPET
= 4,
346 ACPI_DMAR_SCOPE_TYPE_RESERVED
= 5 /* 5 and greater are reserved */
349 struct acpi_dmar_pci_path
{
355 * DMAR Sub-tables, correspond to Type in struct acpi_dmar_header
358 /* 0: Hardware Unit Definition */
360 struct acpi_dmar_hardware_unit
{
361 struct acpi_dmar_header header
;
365 u64 address
; /* Register Base Address */
370 #define ACPI_DMAR_INCLUDE_ALL (1)
372 /* 1: Reserved Memory Defininition */
374 struct acpi_dmar_reserved_memory
{
375 struct acpi_dmar_header header
;
378 u64 base_address
; /* 4_k aligned base address */
379 u64 end_address
; /* 4_k aligned limit address */
384 #define ACPI_DMAR_ALLOW_ALL (1)
387 /* 2: Root Port ATS Capability Reporting Structure */
389 struct acpi_dmar_atsr
{
390 struct acpi_dmar_header header
;
398 #define ACPI_DMAR_ALL_PORTS (1)
400 /*******************************************************************************
402 * ECDT - Embedded Controller Boot Resources Table
404 ******************************************************************************/
406 struct acpi_table_ecdt
{
407 struct acpi_table_header header
; /* Common ACPI table header */
408 struct acpi_generic_address control
; /* Address of EC command/status register */
409 struct acpi_generic_address data
; /* Address of EC data register */
410 u32 uid
; /* Unique ID - must be same as the EC _UID method */
411 u8 gpe
; /* The GPE for the EC */
412 u8 id
[1]; /* Full namepath of the EC in the ACPI namespace */
415 /*******************************************************************************
417 * EINJ - Error Injection Table
419 ******************************************************************************/
421 struct acpi_table_einj
{
422 struct acpi_table_header header
; /* Common ACPI table header */
428 /* EINJ Injection Instruction Entries (actions) */
430 struct acpi_einj_entry
{
431 struct acpi_whea_header whea_header
; /* Common header for WHEA tables */
434 /* Values for Action field above */
436 enum acpi_einj_actions
{
437 ACPI_EINJ_BEGIN_OPERATION
= 0,
438 ACPI_EINJ_GET_TRIGGER_TABLE
= 1,
439 ACPI_EINJ_SET_ERROR_TYPE
= 2,
440 ACPI_EINJ_GET_ERROR_TYPE
= 3,
441 ACPI_EINJ_END_OPERATION
= 4,
442 ACPI_EINJ_EXECUTE_OPERATION
= 5,
443 ACPI_EINJ_CHECK_BUSY_STATUS
= 6,
444 ACPI_EINJ_GET_COMMAND_STATUS
= 7,
445 ACPI_EINJ_ACTION_RESERVED
= 8, /* 8 and greater are reserved */
446 ACPI_EINJ_TRIGGER_ERROR
= 0xFF /* Except for this value */
449 /* Values for Instruction field above */
451 enum acpi_einj_instructions
{
452 ACPI_EINJ_READ_REGISTER
= 0,
453 ACPI_EINJ_READ_REGISTER_VALUE
= 1,
454 ACPI_EINJ_WRITE_REGISTER
= 2,
455 ACPI_EINJ_WRITE_REGISTER_VALUE
= 3,
457 ACPI_EINJ_INSTRUCTION_RESERVED
= 5 /* 5 and greater are reserved */
460 /* EINJ Trigger Error Action Table */
462 struct acpi_einj_trigger
{
469 /*******************************************************************************
471 * ERST - Error Record Serialization Table
473 ******************************************************************************/
475 struct acpi_table_erst
{
476 struct acpi_table_header header
; /* Common ACPI table header */
482 /* ERST Serialization Entries (actions) */
484 struct acpi_erst_entry
{
485 struct acpi_whea_header whea_header
; /* Common header for WHEA tables */
488 /* Values for Action field above */
490 enum acpi_erst_actions
{
491 ACPI_ERST_BEGIN_WRITE_OPERATION
= 0,
492 ACPI_ERST_BEGIN_READ_OPERATION
= 1,
493 ACPI_ERST_BETGIN_CLEAR_OPERATION
= 2,
494 ACPI_ERST_END_OPERATION
= 3,
495 ACPI_ERST_SET_RECORD_OFFSET
= 4,
496 ACPI_ERST_EXECUTE_OPERATION
= 5,
497 ACPI_ERST_CHECK_BUSY_STATUS
= 6,
498 ACPI_ERST_GET_COMMAND_STATUS
= 7,
499 ACPI_ERST_GET_RECORD_IDENTIFIER
= 8,
500 ACPI_ERST_SET_RECORD_IDENTIFIER
= 9,
501 ACPI_ERST_GET_RECORD_COUNT
= 10,
502 ACPI_ERST_BEGIN_DUMMY_WRIITE
= 11,
503 ACPI_ERST_NOT_USED
= 12,
504 ACPI_ERST_GET_ERROR_RANGE
= 13,
505 ACPI_ERST_GET_ERROR_LENGTH
= 14,
506 ACPI_ERST_GET_ERROR_ATTRIBUTES
= 15,
507 ACPI_ERST_ACTION_RESERVED
= 16 /* 16 and greater are reserved */
510 /* Values for Instruction field above */
512 enum acpi_erst_instructions
{
513 ACPI_ERST_READ_REGISTER
= 0,
514 ACPI_ERST_READ_REGISTER_VALUE
= 1,
515 ACPI_ERST_WRITE_REGISTER
= 2,
516 ACPI_ERST_WRITE_REGISTER_VALUE
= 3,
518 ACPI_ERST_LOAD_VAR1
= 5,
519 ACPI_ERST_LOAD_VAR2
= 6,
520 ACPI_ERST_STORE_VAR1
= 7,
522 ACPI_ERST_SUBTRACT
= 9,
523 ACPI_ERST_ADD_VALUE
= 10,
524 ACPI_ERST_SUBTRACT_VALUE
= 11,
525 ACPI_ERST_STALL
= 12,
526 ACPI_ERST_STALL_WHILE_TRUE
= 13,
527 ACPI_ERST_SKIP_NEXT_IF_TRUE
= 14,
529 ACPI_ERST_SET_SRC_ADDRESS_BASE
= 16,
530 ACPI_ERST_SET_DST_ADDRESS_BASE
= 17,
531 ACPI_ERST_MOVE_DATA
= 18,
532 ACPI_ERST_INSTRUCTION_RESERVED
= 19 /* 19 and greater are reserved */
535 /*******************************************************************************
537 * HEST - Hardware Error Source Table
539 ******************************************************************************/
541 struct acpi_table_hest
{
542 struct acpi_table_header header
; /* Common ACPI table header */
543 u32 error_source_count
;
546 /* HEST subtable header */
548 struct acpi_hest_header
{
552 /* Values for Type field above for subtables */
554 enum acpi_hest_types
{
555 ACPI_HEST_TYPE_XPF_MACHINE_CHECK
= 0,
556 ACPI_HEST_TYPE_XPF_CORRECTED_MACHINE_CHECK
= 1,
557 ACPI_HEST_TYPE_XPF_UNUSED
= 2,
558 ACPI_HEST_TYPE_XPF_NON_MASKABLE_INTERRUPT
= 3,
559 ACPI_HEST_TYPE_IPF_CORRECTED_MACHINE_CHECK
= 4,
560 ACPI_HEST_TYPE_IPF_CORRECTED_PLATFORM_ERROR
= 5,
561 ACPI_HEST_TYPE_AER_ROOT_PORT
= 6,
562 ACPI_HEST_TYPE_AER_ENDPOINT
= 7,
563 ACPI_HEST_TYPE_AER_BRIDGE
= 8,
564 ACPI_HEST_TYPE_GENERIC_HARDWARE_ERROR_SOURCE
= 9,
565 ACPI_HEST_TYPE_RESERVED
= 10 /* 10 and greater are reserved */
572 /* XPF Machine Check Error Bank */
574 struct acpi_hest_xpf_error_bank
{
576 u8 clear_status_on_init
;
578 u8 config_write_enable
;
579 u32 control_register
;
580 u64 control_init_data
;
582 u32 address_register
;
586 /* Generic Error Status */
588 struct acpi_hest_generic_status
{
596 /* Generic Error Data */
598 struct acpi_hest_generic_data
{
604 u32 error_data_length
;
609 /* Common HEST structure for PCI/AER types below (6,7,8) */
611 struct acpi_hest_aer_common
{
613 u16 config_write_enable
;
616 u32 records_to_pre_allocate
;
617 u32 max_sections_per_record
;
623 u32 uncorrectable_error_mask
;
624 u32 uncorrectable_error_severity
;
625 u32 correctable_error_mask
;
626 u32 advanced_error_cababilities
;
629 /* Hardware Error Notification */
631 struct acpi_hest_notify
{
634 u16 config_write_enable
;
637 u32 polling_threshold_value
;
638 u32 polling_threshold_window
;
639 u32 error_threshold_value
;
640 u32 error_threshold_window
;
643 /* Values for Notify Type field above */
645 enum acpi_hest_notify_types
{
646 ACPI_HEST_NOTIFY_POLLED
= 0,
647 ACPI_HEST_NOTIFY_EXTERNAL
= 1,
648 ACPI_HEST_NOTIFY_LOCAL
= 2,
649 ACPI_HEST_NOTIFY_SCI
= 3,
650 ACPI_HEST_NOTIFY_NMI
= 4,
651 ACPI_HEST_NOTIFY_RESERVED
= 5 /* 5 and greater are reserved */
657 * From WHEA Design Document, 16 May 2007.
658 * Note: There is no subtable type 2 in this version of the document,
659 * and there are two different subtable type 3s.
662 /* 0: XPF Machine Check Exception */
664 struct acpi_hest_xpf_machine_check
{
665 struct acpi_hest_header header
;
667 u16 config_write_enable
;
670 u32 records_to_pre_allocate
;
671 u32 max_sections_per_record
;
672 u64 global_capability_data
;
673 u64 global_control_data
;
674 u8 num_hardware_banks
;
678 /* 1: XPF Corrected Machine Check */
680 struct acpi_table_hest_xpf_corrected
{
681 struct acpi_hest_header header
;
683 u16 config_write_enable
;
686 u32 records_to_pre_allocate
;
687 u32 max_sections_per_record
;
688 struct acpi_hest_notify notify
;
689 u8 num_hardware_banks
;
693 /* 3: XPF Non-Maskable Interrupt */
695 struct acpi_hest_xpf_nmi
{
696 struct acpi_hest_header header
;
699 u32 records_to_pre_allocate
;
700 u32 max_sections_per_record
;
701 u32 max_raw_data_length
;
704 /* 4: IPF Corrected Machine Check */
706 struct acpi_hest_ipf_corrected
{
707 struct acpi_hest_header header
;
712 /* 5: IPF Corrected Platform Error */
714 struct acpi_hest_ipf_corrected_platform
{
715 struct acpi_hest_header header
;
720 /* 6: PCI Express Root Port AER */
722 struct acpi_hest_aer_root
{
723 struct acpi_hest_header header
;
724 struct acpi_hest_aer_common aer
;
725 u32 root_error_command
;
728 /* 7: PCI Express AER (AER Endpoint) */
730 struct acpi_hest_aer
{
731 struct acpi_hest_header header
;
732 struct acpi_hest_aer_common aer
;
735 /* 8: PCI Express/PCI-X Bridge AER */
737 struct acpi_hest_aer_bridge
{
738 struct acpi_hest_header header
;
739 struct acpi_hest_aer_common aer
;
740 u32 secondary_uncorrectable_error_mask
;
741 u32 secondary_uncorrectable_error_severity
;
742 u32 secondary_advanced_capabilities
;
745 /* 9: Generic Hardware Error Source */
747 struct acpi_hest_generic
{
748 struct acpi_hest_header header
;
750 u16 related_source_id
;
751 u8 config_write_enable
;
753 u32 records_to_pre_allocate
;
754 u32 max_sections_per_record
;
755 u32 max_raw_data_length
;
756 struct acpi_generic_address error_status_address
;
757 struct acpi_hest_notify notify
;
758 u32 error_status_block_length
;
761 /*******************************************************************************
763 * HPET - High Precision Event Timer table
765 ******************************************************************************/
767 struct acpi_table_hpet
{
768 struct acpi_table_header header
; /* Common ACPI table header */
769 u32 id
; /* Hardware ID of event timer block */
770 struct acpi_generic_address address
; /* Address of event timer block */
771 u8 sequence
; /* HPET sequence number */
772 u16 minimum_tick
; /* Main counter min tick, periodic mode */
778 #define ACPI_HPET_PAGE_PROTECT (1) /* 00: No page protection */
779 #define ACPI_HPET_PAGE_PROTECT_4 (1<<1) /* 01: 4KB page protected */
780 #define ACPI_HPET_PAGE_PROTECT_64 (1<<2) /* 02: 64KB page protected */
782 /*! [End] no source code translation !*/
784 /*******************************************************************************
786 * IBFT - Boot Firmware Table
788 ******************************************************************************/
790 struct acpi_table_ibft
{
791 struct acpi_table_header header
; /* Common ACPI table header */
795 /* IBFT common subtable header */
797 struct acpi_ibft_header
{
805 /* Values for Type field above */
807 enum acpi_ibft_type
{
808 ACPI_IBFT_TYPE_NOT_USED
= 0,
809 ACPI_IBFT_TYPE_CONTROL
= 1,
810 ACPI_IBFT_TYPE_INITIATOR
= 2,
811 ACPI_IBFT_TYPE_NIC
= 3,
812 ACPI_IBFT_TYPE_TARGET
= 4,
813 ACPI_IBFT_TYPE_EXTENSIONS
= 5,
814 ACPI_IBFT_TYPE_RESERVED
= 6 /* 6 and greater are reserved */
819 struct acpi_ibft_control
{
820 struct acpi_ibft_header header
;
822 u16 initiator_offset
;
829 struct acpi_ibft_initiator
{
830 struct acpi_ibft_header header
;
833 u8 primary_server
[16];
834 u8 secondary_server
[16];
839 struct acpi_ibft_nic
{
840 struct acpi_ibft_header header
;
842 u8 subnet_mask_prefix
;
846 u8 secondary_dns
[16];
855 struct acpi_ibft_target
{
856 struct acpi_ibft_header header
;
857 u8 target_ip_address
[16];
858 u16 target_ip_socket
;
859 u8 target_boot_lun
[8];
862 u16 target_name_length
;
863 u16 target_name_offset
;
864 u16 chap_name_length
;
865 u16 chap_name_offset
;
866 u16 chap_secret_length
;
867 u16 chap_secret_offset
;
868 u16 reverse_chap_name_length
;
869 u16 reverse_chap_name_offset
;
870 u16 reverse_chap_secret_length
;
871 u16 reverse_chap_secret_offset
;
874 /*******************************************************************************
876 * MADT - Multiple APIC Description Table
878 ******************************************************************************/
880 struct acpi_table_madt
{
881 struct acpi_table_header header
; /* Common ACPI table header */
882 u32 address
; /* Physical address of local APIC */
888 #define ACPI_MADT_PCAT_COMPAT (1) /* 00: System also has dual 8259s */
890 /* Values for PCATCompat flag */
892 #define ACPI_MADT_DUAL_PIC 0
893 #define ACPI_MADT_MULTIPLE_APIC 1
895 /* Values for subtable type in struct acpi_subtable_header */
897 enum acpi_madt_type
{
898 ACPI_MADT_TYPE_LOCAL_APIC
= 0,
899 ACPI_MADT_TYPE_IO_APIC
= 1,
900 ACPI_MADT_TYPE_INTERRUPT_OVERRIDE
= 2,
901 ACPI_MADT_TYPE_NMI_SOURCE
= 3,
902 ACPI_MADT_TYPE_LOCAL_APIC_NMI
= 4,
903 ACPI_MADT_TYPE_LOCAL_APIC_OVERRIDE
= 5,
904 ACPI_MADT_TYPE_IO_SAPIC
= 6,
905 ACPI_MADT_TYPE_LOCAL_SAPIC
= 7,
906 ACPI_MADT_TYPE_INTERRUPT_SOURCE
= 8,
907 ACPI_MADT_TYPE_RESERVED
= 9 /* 9 and greater are reserved */
911 * MADT Sub-tables, correspond to Type in struct acpi_subtable_header
914 /* 0: Processor Local APIC */
916 struct acpi_madt_local_apic
{
917 struct acpi_subtable_header header
;
918 u8 processor_id
; /* ACPI processor id */
919 u8 id
; /* Processor's local APIC id */
925 struct acpi_madt_io_apic
{
926 struct acpi_subtable_header header
;
927 u8 id
; /* I/O APIC ID */
928 u8 reserved
; /* Reserved - must be zero */
929 u32 address
; /* APIC physical address */
930 u32 global_irq_base
; /* Global system interrupt where INTI lines start */
933 /* 2: Interrupt Override */
935 struct acpi_madt_interrupt_override
{
936 struct acpi_subtable_header header
;
937 u8 bus
; /* 0 - ISA */
938 u8 source_irq
; /* Interrupt source (IRQ) */
939 u32 global_irq
; /* Global system interrupt */
945 struct acpi_madt_nmi_source
{
946 struct acpi_subtable_header header
;
948 u32 global_irq
; /* Global system interrupt */
951 /* 4: Local APIC NMI */
953 struct acpi_madt_local_apic_nmi
{
954 struct acpi_subtable_header header
;
955 u8 processor_id
; /* ACPI processor id */
957 u8 lint
; /* LINTn to which NMI is connected */
960 /* 5: Address Override */
962 struct acpi_madt_local_apic_override
{
963 struct acpi_subtable_header header
;
964 u16 reserved
; /* Reserved, must be zero */
965 u64 address
; /* APIC physical address */
970 struct acpi_madt_io_sapic
{
971 struct acpi_subtable_header header
;
972 u8 id
; /* I/O SAPIC ID */
973 u8 reserved
; /* Reserved, must be zero */
974 u32 global_irq_base
; /* Global interrupt for SAPIC start */
975 u64 address
; /* SAPIC physical address */
980 struct acpi_madt_local_sapic
{
981 struct acpi_subtable_header header
;
982 u8 processor_id
; /* ACPI processor id */
983 u8 id
; /* SAPIC ID */
984 u8 eid
; /* SAPIC EID */
985 u8 reserved
[3]; /* Reserved, must be zero */
987 u32 uid
; /* Numeric UID - ACPI 3.0 */
988 char uid_string
[1]; /* String UID - ACPI 3.0 */
991 /* 8: Platform Interrupt Source */
993 struct acpi_madt_interrupt_source
{
994 struct acpi_subtable_header header
;
996 u8 type
; /* 1=PMI, 2=INIT, 3=corrected */
997 u8 id
; /* Processor ID */
998 u8 eid
; /* Processor EID */
999 u8 io_sapic_vector
; /* Vector value for PMI interrupts */
1000 u32 global_irq
; /* Global system interrupt */
1001 u32 flags
; /* Interrupt Source Flags */
1004 /* Flags field above */
1006 #define ACPI_MADT_CPEI_OVERRIDE (1)
1009 * Common flags fields for MADT subtables
1012 /* MADT Local APIC flags (lapic_flags) */
1014 #define ACPI_MADT_ENABLED (1) /* 00: Processor is usable if set */
1016 /* MADT MPS INTI flags (inti_flags) */
1018 #define ACPI_MADT_POLARITY_MASK (3) /* 00-01: Polarity of APIC I/O input signals */
1019 #define ACPI_MADT_TRIGGER_MASK (3<<2) /* 02-03: Trigger mode of APIC input signals */
1021 /* Values for MPS INTI flags */
1023 #define ACPI_MADT_POLARITY_CONFORMS 0
1024 #define ACPI_MADT_POLARITY_ACTIVE_HIGH 1
1025 #define ACPI_MADT_POLARITY_RESERVED 2
1026 #define ACPI_MADT_POLARITY_ACTIVE_LOW 3
1028 #define ACPI_MADT_TRIGGER_CONFORMS (0)
1029 #define ACPI_MADT_TRIGGER_EDGE (1<<2)
1030 #define ACPI_MADT_TRIGGER_RESERVED (2<<2)
1031 #define ACPI_MADT_TRIGGER_LEVEL (3<<2)
1033 /*******************************************************************************
1035 * MCFG - PCI Memory Mapped Configuration table and sub-table
1037 ******************************************************************************/
1039 struct acpi_table_mcfg
{
1040 struct acpi_table_header header
; /* Common ACPI table header */
1046 struct acpi_mcfg_allocation
{
1047 u64 address
; /* Base address, processor-relative */
1048 u16 pci_segment
; /* PCI segment group number */
1049 u8 start_bus_number
; /* Starting PCI Bus number */
1050 u8 end_bus_number
; /* Final PCI Bus number */
1054 /*******************************************************************************
1056 * SBST - Smart Battery Specification Table
1058 ******************************************************************************/
1060 struct acpi_table_sbst
{
1061 struct acpi_table_header header
; /* Common ACPI table header */
1067 /*******************************************************************************
1069 * SLIT - System Locality Distance Information Table
1071 ******************************************************************************/
1073 struct acpi_table_slit
{
1074 struct acpi_table_header header
; /* Common ACPI table header */
1076 u8 entry
[1]; /* Real size = localities^2 */
1079 /*******************************************************************************
1081 * SPCR - Serial Port Console Redirection table
1083 ******************************************************************************/
1085 struct acpi_table_spcr
{
1086 struct acpi_table_header header
; /* Common ACPI table header */
1087 u8 interface_type
; /* 0=full 16550, 1=subset of 16550 */
1089 struct acpi_generic_address serial_port
;
1109 /*******************************************************************************
1111 * SPMI - Server Platform Management Interface table
1113 ******************************************************************************/
1115 struct acpi_table_spmi
{
1116 struct acpi_table_header header
; /* Common ACPI table header */
1119 u16 spec_revision
; /* Version of IPMI */
1121 u8 gpe_number
; /* GPE assigned */
1125 struct acpi_generic_address ipmi_register
;
1132 /*******************************************************************************
1134 * SRAT - System Resource Affinity Table
1136 ******************************************************************************/
1138 struct acpi_table_srat
{
1139 struct acpi_table_header header
; /* Common ACPI table header */
1140 u32 table_revision
; /* Must be value '1' */
1141 u64 reserved
; /* Reserved, must be zero */
1144 /* Values for subtable type in struct acpi_subtable_header */
1146 enum acpi_srat_type
{
1147 ACPI_SRAT_TYPE_CPU_AFFINITY
= 0,
1148 ACPI_SRAT_TYPE_MEMORY_AFFINITY
= 1,
1149 ACPI_SRAT_TYPE_RESERVED
= 2
1152 /* SRAT sub-tables */
1154 struct acpi_srat_cpu_affinity
{
1155 struct acpi_subtable_header header
;
1156 u8 proximity_domain_lo
;
1160 u8 proximity_domain_hi
[3];
1161 u32 reserved
; /* Reserved, must be zero */
1166 #define ACPI_SRAT_CPU_ENABLED (1) /* 00: Use affinity structure */
1168 struct acpi_srat_mem_affinity
{
1169 struct acpi_subtable_header header
;
1170 u32 proximity_domain
;
1171 u16 reserved
; /* Reserved, must be zero */
1176 u64 reserved2
; /* Reserved, must be zero */
1181 #define ACPI_SRAT_MEM_ENABLED (1) /* 00: Use affinity structure */
1182 #define ACPI_SRAT_MEM_HOT_PLUGGABLE (1<<1) /* 01: Memory region is hot pluggable */
1183 #define ACPI_SRAT_MEM_NON_VOLATILE (1<<2) /* 02: Memory region is non-volatile */
1185 /*******************************************************************************
1187 * TCPA - Trusted Computing Platform Alliance table
1189 ******************************************************************************/
1191 struct acpi_table_tcpa
{
1192 struct acpi_table_header header
; /* Common ACPI table header */
1194 u32 max_log_length
; /* Maximum length for the event log area */
1195 u64 log_address
; /* Address of the event log area */
1198 /*******************************************************************************
1200 * UEFI - UEFI Boot optimization Table
1202 ******************************************************************************/
1204 struct acpi_table_uefi
{
1205 struct acpi_table_header header
; /* Common ACPI table header */
1206 u8 identifier
[16]; /* UUID identifier */
1207 u16 data_offset
; /* Offset of remaining data in table */
1211 /*******************************************************************************
1213 * WDAT - Watchdog Action Table
1215 ******************************************************************************/
1217 struct acpi_table_wdat
{
1218 struct acpi_table_header header
; /* Common ACPI table header */
1219 u32 header_length
; /* Watchdog Header Length */
1220 u16 pci_segment
; /* PCI Segment number */
1221 u8 pci_bus
; /* PCI Bus number */
1222 u8 pci_device
; /* PCI Device number */
1223 u8 pci_function
; /* PCI Function number */
1225 u32 timer_period
; /* Period of one timer count (msec) */
1226 u32 max_count
; /* Maximum counter value supported */
1227 u32 min_count
; /* Minimum counter value */
1230 u32 entries
; /* Number of watchdog entries that follow */
1233 /* WDAT Instruction Entries (actions) */
1235 struct acpi_wdat_entry
{
1236 struct acpi_whea_header whea_header
; /* Common header for WHEA tables */
1239 /* Values for Action field above */
1241 enum acpi_wdat_actions
{
1242 ACPI_WDAT_RESET
= 1,
1243 ACPI_WDAT_GET_CURRENT_COUNTDOWN
= 4,
1244 ACPI_WDAT_GET_COUNTDOWN
= 5,
1245 ACPI_WDAT_SET_COUNTDOWN
= 6,
1246 ACPI_WDAT_GET_RUNNING_STATE
= 8,
1247 ACPI_WDAT_SET_RUNNING_STATE
= 9,
1248 ACPI_WDAT_GET_STOPPED_STATE
= 10,
1249 ACPI_WDAT_SET_STOPPED_STATE
= 11,
1250 ACPI_WDAT_GET_REBOOT
= 16,
1251 ACPI_WDAT_SET_REBOOT
= 17,
1252 ACPI_WDAT_GET_SHUTDOWN
= 18,
1253 ACPI_WDAT_SET_SHUTDOWN
= 19,
1254 ACPI_WDAT_GET_STATUS
= 32,
1255 ACPI_WDAT_SET_STATUS
= 33,
1256 ACPI_WDAT_ACTION_RESERVED
= 34 /* 34 and greater are reserved */
1259 /* Values for Instruction field above */
1261 enum acpi_wdat_instructions
{
1262 ACPI_WDAT_READ_VALUE
= 0,
1263 ACPI_WDAT_READ_COUNTDOWN
= 1,
1264 ACPI_WDAT_WRITE_VALUE
= 2,
1265 ACPI_WDAT_WRITE_COUNTDOWN
= 3,
1266 ACPI_WDAT_INSTRUCTION_RESERVED
= 4, /* 4 and greater are reserved */
1267 ACPI_WDAT_PRESERVE_REGISTER
= 0x80 /* Except for this value */
1270 /*******************************************************************************
1272 * WDRT - Watchdog Resource Table
1274 ******************************************************************************/
1276 struct acpi_table_wdrt
{
1277 struct acpi_table_header header
; /* Common ACPI table header */
1278 u32 header_length
; /* Watchdog Header Length */
1279 u8 pci_segment
; /* PCI Segment number */
1280 u8 pci_bus
; /* PCI Bus number */
1281 u8 pci_device
; /* PCI Device number */
1282 u8 pci_function
; /* PCI Function number */
1283 u32 timer_period
; /* Period of one timer count (msec) */
1284 u32 max_count
; /* Maximum counter value supported */
1285 u32 min_count
; /* Minimum counter value */
1288 u32 entries
; /* Number of watchdog entries that follow */
1293 #define ACPI_WDRT_TIMER_ENABLED (1) /* 00: Timer enabled */
1295 /* Reset to default packing */
1299 #endif /* __ACTBL1_H__ */