x86/amd-iommu: Add per IOMMU reference counting
[linux/fpc-iii.git] / include / acpi / actbl2.h
blob6f3dce9991e1ec18a75d0cafe74e272c8d12992a
1 #ifndef __ACTBL2_H__
2 #define __ACTBL2_H__
4 /*******************************************************************************
6 * Additional ACPI Tables (2)
8 * These tables are not consumed directly by the ACPICA subsystem, but are
9 * included here to support device drivers and the AML disassembler.
11 * The tables in this file are defined by third-party specifications, and are
12 * not defined directly by the ACPI specification itself.
14 ******************************************************************************/
17 * Values for description table header signatures for tables defined in this
18 * file. Useful because they make it more difficult to inadvertently type in
19 * the wrong signature.
21 #define ACPI_SIG_ASF "ASF!" /* Alert Standard Format table */
22 #define ACPI_SIG_BOOT "BOOT" /* Simple Boot Flag Table */
23 #define ACPI_SIG_DBGP "DBGP" /* Debug Port table */
24 #define ACPI_SIG_DMAR "DMAR" /* DMA Remapping table */
25 #define ACPI_SIG_HPET "HPET" /* High Precision Event Timer table */
26 #define ACPI_SIG_IBFT "IBFT" /* i_sCSI Boot Firmware Table */
27 #define ACPI_SIG_IVRS "IVRS" /* I/O Virtualization Reporting Structure */
28 #define ACPI_SIG_MCFG "MCFG" /* PCI Memory Mapped Configuration table */
29 #define ACPI_SIG_SLIC "SLIC" /* Software Licensing Description Table */
30 #define ACPI_SIG_SPCR "SPCR" /* Serial Port Console Redirection table */
31 #define ACPI_SIG_SPMI "SPMI" /* Server Platform Management Interface table */
32 #define ACPI_SIG_TCPA "TCPA" /* Trusted Computing Platform Alliance table */
33 #define ACPI_SIG_UEFI "UEFI" /* Uefi Boot Optimization Table */
34 #define ACPI_SIG_WAET "WAET" /* Windows ACPI Emulated devices Table */
35 #define ACPI_SIG_WDAT "WDAT" /* Watchdog Action Table */
36 #define ACPI_SIG_WDRT "WDRT" /* Watchdog Resource Table */
39 * All tables must be byte-packed to match the ACPI specification, since
40 * the tables are provided by the system BIOS.
42 #pragma pack(1)
45 * Note about bitfields: The u8 type is used for bitfields in ACPI tables.
46 * This is the only type that is even remotely portable. Anything else is not
47 * portable, so do not use any other bitfield types.
50 /*******************************************************************************
52 * ASF - Alert Standard Format table (Signature "ASF!")
53 * Revision 0x10
55 * Conforms to the Alert Standard Format Specification V2.0, 23 April 2003
57 ******************************************************************************/
59 struct acpi_table_asf {
60 struct acpi_table_header header; /* Common ACPI table header */
63 /* ASF subtable header */
65 struct acpi_asf_header {
66 u8 type;
67 u8 reserved;
68 u16 length;
71 /* Values for Type field above */
73 enum acpi_asf_type {
74 ACPI_ASF_TYPE_INFO = 0,
75 ACPI_ASF_TYPE_ALERT = 1,
76 ACPI_ASF_TYPE_CONTROL = 2,
77 ACPI_ASF_TYPE_BOOT = 3,
78 ACPI_ASF_TYPE_ADDRESS = 4,
79 ACPI_ASF_TYPE_RESERVED = 5
83 * ASF subtables
86 /* 0: ASF Information */
88 struct acpi_asf_info {
89 struct acpi_asf_header header;
90 u8 min_reset_value;
91 u8 min_poll_interval;
92 u16 system_id;
93 u32 mfg_id;
94 u8 flags;
95 u8 reserved2[3];
98 /* Masks for Flags field above */
100 #define ACPI_ASF_SMBUS_PROTOCOLS (1)
102 /* 1: ASF Alerts */
104 struct acpi_asf_alert {
105 struct acpi_asf_header header;
106 u8 assert_mask;
107 u8 deassert_mask;
108 u8 alerts;
109 u8 data_length;
112 struct acpi_asf_alert_data {
113 u8 address;
114 u8 command;
115 u8 mask;
116 u8 value;
117 u8 sensor_type;
118 u8 type;
119 u8 offset;
120 u8 source_type;
121 u8 severity;
122 u8 sensor_number;
123 u8 entity;
124 u8 instance;
127 /* 2: ASF Remote Control */
129 struct acpi_asf_remote {
130 struct acpi_asf_header header;
131 u8 controls;
132 u8 data_length;
133 u16 reserved2;
136 struct acpi_asf_control_data {
137 u8 function;
138 u8 address;
139 u8 command;
140 u8 value;
143 /* 3: ASF RMCP Boot Options */
145 struct acpi_asf_rmcp {
146 struct acpi_asf_header header;
147 u8 capabilities[7];
148 u8 completion_code;
149 u32 enterprise_id;
150 u8 command;
151 u16 parameter;
152 u16 boot_options;
153 u16 oem_parameters;
156 /* 4: ASF Address */
158 struct acpi_asf_address {
159 struct acpi_asf_header header;
160 u8 eprom_address;
161 u8 devices;
164 /*******************************************************************************
166 * BOOT - Simple Boot Flag Table
167 * Version 1
169 * Conforms to the "Simple Boot Flag Specification", Version 2.1
171 ******************************************************************************/
173 struct acpi_table_boot {
174 struct acpi_table_header header; /* Common ACPI table header */
175 u8 cmos_index; /* Index in CMOS RAM for the boot register */
176 u8 reserved[3];
179 /*******************************************************************************
181 * DBGP - Debug Port table
182 * Version 1
184 * Conforms to the "Debug Port Specification", Version 1.00, 2/9/2000
186 ******************************************************************************/
188 struct acpi_table_dbgp {
189 struct acpi_table_header header; /* Common ACPI table header */
190 u8 type; /* 0=full 16550, 1=subset of 16550 */
191 u8 reserved[3];
192 struct acpi_generic_address debug_port;
195 /*******************************************************************************
197 * DMAR - DMA Remapping table
198 * Version 1
200 * Conforms to "Intel Virtualization Technology for Directed I/O",
201 * Version 1.2, Sept. 2008
203 ******************************************************************************/
205 struct acpi_table_dmar {
206 struct acpi_table_header header; /* Common ACPI table header */
207 u8 width; /* Host Address Width */
208 u8 flags;
209 u8 reserved[10];
212 /* Masks for Flags field above */
214 #define ACPI_DMAR_INTR_REMAP (1)
216 /* DMAR subtable header */
218 struct acpi_dmar_header {
219 u16 type;
220 u16 length;
223 /* Values for subtable type in struct acpi_dmar_header */
225 enum acpi_dmar_type {
226 ACPI_DMAR_TYPE_HARDWARE_UNIT = 0,
227 ACPI_DMAR_TYPE_RESERVED_MEMORY = 1,
228 ACPI_DMAR_TYPE_ATSR = 2,
229 ACPI_DMAR_HARDWARE_AFFINITY = 3,
230 ACPI_DMAR_TYPE_RESERVED = 4 /* 4 and greater are reserved */
233 /* DMAR Device Scope structure */
235 struct acpi_dmar_device_scope {
236 u8 entry_type;
237 u8 length;
238 u16 reserved;
239 u8 enumeration_id;
240 u8 bus;
243 /* Values for entry_type in struct acpi_dmar_device_scope */
245 enum acpi_dmar_scope_type {
246 ACPI_DMAR_SCOPE_TYPE_NOT_USED = 0,
247 ACPI_DMAR_SCOPE_TYPE_ENDPOINT = 1,
248 ACPI_DMAR_SCOPE_TYPE_BRIDGE = 2,
249 ACPI_DMAR_SCOPE_TYPE_IOAPIC = 3,
250 ACPI_DMAR_SCOPE_TYPE_HPET = 4,
251 ACPI_DMAR_SCOPE_TYPE_RESERVED = 5 /* 5 and greater are reserved */
254 struct acpi_dmar_pci_path {
255 u8 dev;
256 u8 fn;
260 * DMAR Sub-tables, correspond to Type in struct acpi_dmar_header
263 /* 0: Hardware Unit Definition */
265 struct acpi_dmar_hardware_unit {
266 struct acpi_dmar_header header;
267 u8 flags;
268 u8 reserved;
269 u16 segment;
270 u64 address; /* Register Base Address */
273 /* Masks for Flags field above */
275 #define ACPI_DMAR_INCLUDE_ALL (1)
277 /* 1: Reserved Memory Defininition */
279 struct acpi_dmar_reserved_memory {
280 struct acpi_dmar_header header;
281 u16 reserved;
282 u16 segment;
283 u64 base_address; /* 4_k aligned base address */
284 u64 end_address; /* 4_k aligned limit address */
287 /* Masks for Flags field above */
289 #define ACPI_DMAR_ALLOW_ALL (1)
291 /* 2: Root Port ATS Capability Reporting Structure */
293 struct acpi_dmar_atsr {
294 struct acpi_dmar_header header;
295 u8 flags;
296 u8 reserved;
297 u16 segment;
300 /* Masks for Flags field above */
302 #define ACPI_DMAR_ALL_PORTS (1)
304 /* 3: Remapping Hardware Static Affinity Structure */
306 struct acpi_dmar_rhsa {
307 struct acpi_dmar_header header;
308 u32 reserved;
309 u64 base_address;
310 u32 proximity_domain;
313 /*******************************************************************************
315 * HPET - High Precision Event Timer table
316 * Version 1
318 * Conforms to "IA-PC HPET (High Precision Event Timers) Specification",
319 * Version 1.0a, October 2004
321 ******************************************************************************/
323 struct acpi_table_hpet {
324 struct acpi_table_header header; /* Common ACPI table header */
325 u32 id; /* Hardware ID of event timer block */
326 struct acpi_generic_address address; /* Address of event timer block */
327 u8 sequence; /* HPET sequence number */
328 u16 minimum_tick; /* Main counter min tick, periodic mode */
329 u8 flags;
332 /* Masks for Flags field above */
334 #define ACPI_HPET_PAGE_PROTECT_MASK (3)
336 /* Values for Page Protect flags */
338 enum acpi_hpet_page_protect {
339 ACPI_HPET_NO_PAGE_PROTECT = 0,
340 ACPI_HPET_PAGE_PROTECT4 = 1,
341 ACPI_HPET_PAGE_PROTECT64 = 2
344 /*******************************************************************************
346 * IBFT - Boot Firmware Table
347 * Version 1
349 * Conforms to "iSCSI Boot Firmware Table (iBFT) as Defined in ACPI 3.0b
350 * Specification", Version 1.01, March 1, 2007
352 * Note: It appears that this table is not intended to appear in the RSDT/XSDT.
353 * Therefore, it is not currently supported by the disassembler.
355 ******************************************************************************/
357 struct acpi_table_ibft {
358 struct acpi_table_header header; /* Common ACPI table header */
359 u8 reserved[12];
362 /* IBFT common subtable header */
364 struct acpi_ibft_header {
365 u8 type;
366 u8 version;
367 u16 length;
368 u8 index;
369 u8 flags;
372 /* Values for Type field above */
374 enum acpi_ibft_type {
375 ACPI_IBFT_TYPE_NOT_USED = 0,
376 ACPI_IBFT_TYPE_CONTROL = 1,
377 ACPI_IBFT_TYPE_INITIATOR = 2,
378 ACPI_IBFT_TYPE_NIC = 3,
379 ACPI_IBFT_TYPE_TARGET = 4,
380 ACPI_IBFT_TYPE_EXTENSIONS = 5,
381 ACPI_IBFT_TYPE_RESERVED = 6 /* 6 and greater are reserved */
384 /* IBFT subtables */
386 struct acpi_ibft_control {
387 struct acpi_ibft_header header;
388 u16 extensions;
389 u16 initiator_offset;
390 u16 nic0_offset;
391 u16 target0_offset;
392 u16 nic1_offset;
393 u16 target1_offset;
396 struct acpi_ibft_initiator {
397 struct acpi_ibft_header header;
398 u8 sns_server[16];
399 u8 slp_server[16];
400 u8 primary_server[16];
401 u8 secondary_server[16];
402 u16 name_length;
403 u16 name_offset;
406 struct acpi_ibft_nic {
407 struct acpi_ibft_header header;
408 u8 ip_address[16];
409 u8 subnet_mask_prefix;
410 u8 origin;
411 u8 gateway[16];
412 u8 primary_dns[16];
413 u8 secondary_dns[16];
414 u8 dhcp[16];
415 u16 vlan;
416 u8 mac_address[6];
417 u16 pci_address;
418 u16 name_length;
419 u16 name_offset;
422 struct acpi_ibft_target {
423 struct acpi_ibft_header header;
424 u8 target_ip_address[16];
425 u16 target_ip_socket;
426 u8 target_boot_lun[8];
427 u8 chap_type;
428 u8 nic_association;
429 u16 target_name_length;
430 u16 target_name_offset;
431 u16 chap_name_length;
432 u16 chap_name_offset;
433 u16 chap_secret_length;
434 u16 chap_secret_offset;
435 u16 reverse_chap_name_length;
436 u16 reverse_chap_name_offset;
437 u16 reverse_chap_secret_length;
438 u16 reverse_chap_secret_offset;
441 /*******************************************************************************
443 * IVRS - I/O Virtualization Reporting Structure
444 * Version 1
446 * Conforms to "AMD I/O Virtualization Technology (IOMMU) Specification",
447 * Revision 1.26, February 2009.
449 ******************************************************************************/
451 struct acpi_table_ivrs {
452 struct acpi_table_header header; /* Common ACPI table header */
453 u32 info; /* Common virtualization info */
454 u64 reserved;
457 /* Values for Info field above */
459 #define ACPI_IVRS_PHYSICAL_SIZE 0x00007F00 /* 7 bits, physical address size */
460 #define ACPI_IVRS_VIRTUAL_SIZE 0x003F8000 /* 7 bits, virtual address size */
461 #define ACPI_IVRS_ATS_RESERVED 0x00400000 /* ATS address translation range reserved */
463 /* IVRS subtable header */
465 struct acpi_ivrs_header {
466 u8 type; /* Subtable type */
467 u8 flags;
468 u16 length; /* Subtable length */
469 u16 device_id; /* ID of IOMMU */
472 /* Values for subtable Type above */
474 enum acpi_ivrs_type {
475 ACPI_IVRS_TYPE_HARDWARE = 0x10,
476 ACPI_IVRS_TYPE_MEMORY1 = 0x20,
477 ACPI_IVRS_TYPE_MEMORY2 = 0x21,
478 ACPI_IVRS_TYPE_MEMORY3 = 0x22
481 /* Masks for Flags field above for IVHD subtable */
483 #define ACPI_IVHD_TT_ENABLE (1)
484 #define ACPI_IVHD_PASS_PW (1<<1)
485 #define ACPI_IVHD_RES_PASS_PW (1<<2)
486 #define ACPI_IVHD_ISOC (1<<3)
487 #define ACPI_IVHD_IOTLB (1<<4)
489 /* Masks for Flags field above for IVMD subtable */
491 #define ACPI_IVMD_UNITY (1)
492 #define ACPI_IVMD_READ (1<<1)
493 #define ACPI_IVMD_WRITE (1<<2)
494 #define ACPI_IVMD_EXCLUSION_RANGE (1<<3)
497 * IVRS subtables, correspond to Type in struct acpi_ivrs_header
500 /* 0x10: I/O Virtualization Hardware Definition Block (IVHD) */
502 struct acpi_ivrs_hardware {
503 struct acpi_ivrs_header header;
504 u16 capability_offset; /* Offset for IOMMU control fields */
505 u64 base_address; /* IOMMU control registers */
506 u16 pci_segment_group;
507 u16 info; /* MSI number and unit ID */
508 u32 reserved;
511 /* Masks for Info field above */
513 #define ACPI_IVHD_MSI_NUMBER_MASK 0x001F /* 5 bits, MSI message number */
514 #define ACPI_IVHD_UNIT_ID_MASK 0x1F00 /* 5 bits, unit_iD */
517 * Device Entries for IVHD subtable, appear after struct acpi_ivrs_hardware structure.
518 * Upper two bits of the Type field are the (encoded) length of the structure.
519 * Currently, only 4 and 8 byte entries are defined. 16 and 32 byte entries
520 * are reserved for future use but not defined.
522 struct acpi_ivrs_de_header {
523 u8 type;
524 u16 id;
525 u8 data_setting;
528 /* Length of device entry is in the top two bits of Type field above */
530 #define ACPI_IVHD_ENTRY_LENGTH 0xC0
532 /* Values for device entry Type field above */
534 enum acpi_ivrs_device_entry_type {
535 /* 4-byte device entries, all use struct acpi_ivrs_device4 */
537 ACPI_IVRS_TYPE_PAD4 = 0,
538 ACPI_IVRS_TYPE_ALL = 1,
539 ACPI_IVRS_TYPE_SELECT = 2,
540 ACPI_IVRS_TYPE_START = 3,
541 ACPI_IVRS_TYPE_END = 4,
543 /* 8-byte device entries */
545 ACPI_IVRS_TYPE_PAD8 = 64,
546 ACPI_IVRS_TYPE_NOT_USED = 65,
547 ACPI_IVRS_TYPE_ALIAS_SELECT = 66, /* Uses struct acpi_ivrs_device8a */
548 ACPI_IVRS_TYPE_ALIAS_START = 67, /* Uses struct acpi_ivrs_device8a */
549 ACPI_IVRS_TYPE_EXT_SELECT = 70, /* Uses struct acpi_ivrs_device8b */
550 ACPI_IVRS_TYPE_EXT_START = 71, /* Uses struct acpi_ivrs_device8b */
551 ACPI_IVRS_TYPE_SPECIAL = 72 /* Uses struct acpi_ivrs_device8c */
554 /* Values for Data field above */
556 #define ACPI_IVHD_INIT_PASS (1)
557 #define ACPI_IVHD_EINT_PASS (1<<1)
558 #define ACPI_IVHD_NMI_PASS (1<<2)
559 #define ACPI_IVHD_SYSTEM_MGMT (3<<4)
560 #define ACPI_IVHD_LINT0_PASS (1<<6)
561 #define ACPI_IVHD_LINT1_PASS (1<<7)
563 /* Types 0-4: 4-byte device entry */
565 struct acpi_ivrs_device4 {
566 struct acpi_ivrs_de_header header;
569 /* Types 66-67: 8-byte device entry */
571 struct acpi_ivrs_device8a {
572 struct acpi_ivrs_de_header header;
573 u8 reserved1;
574 u16 used_id;
575 u8 reserved2;
578 /* Types 70-71: 8-byte device entry */
580 struct acpi_ivrs_device8b {
581 struct acpi_ivrs_de_header header;
582 u32 extended_data;
585 /* Values for extended_data above */
587 #define ACPI_IVHD_ATS_DISABLED (1<<31)
589 /* Type 72: 8-byte device entry */
591 struct acpi_ivrs_device8c {
592 struct acpi_ivrs_de_header header;
593 u8 handle;
594 u16 used_id;
595 u8 variety;
598 /* Values for Variety field above */
600 #define ACPI_IVHD_IOAPIC 1
601 #define ACPI_IVHD_HPET 2
603 /* 0x20, 0x21, 0x22: I/O Virtualization Memory Definition Block (IVMD) */
605 struct acpi_ivrs_memory {
606 struct acpi_ivrs_header header;
607 u16 aux_data;
608 u64 reserved;
609 u64 start_address;
610 u64 memory_length;
613 /*******************************************************************************
615 * MCFG - PCI Memory Mapped Configuration table and sub-table
616 * Version 1
618 * Conforms to "PCI Firmware Specification", Revision 3.0, June 20, 2005
620 ******************************************************************************/
622 struct acpi_table_mcfg {
623 struct acpi_table_header header; /* Common ACPI table header */
624 u8 reserved[8];
627 /* Subtable */
629 struct acpi_mcfg_allocation {
630 u64 address; /* Base address, processor-relative */
631 u16 pci_segment; /* PCI segment group number */
632 u8 start_bus_number; /* Starting PCI Bus number */
633 u8 end_bus_number; /* Final PCI Bus number */
634 u32 reserved;
637 /*******************************************************************************
639 * SPCR - Serial Port Console Redirection table
640 * Version 1
642 * Conforms to "Serial Port Console Redirection Table",
643 * Version 1.00, January 11, 2002
645 ******************************************************************************/
647 struct acpi_table_spcr {
648 struct acpi_table_header header; /* Common ACPI table header */
649 u8 interface_type; /* 0=full 16550, 1=subset of 16550 */
650 u8 reserved[3];
651 struct acpi_generic_address serial_port;
652 u8 interrupt_type;
653 u8 pc_interrupt;
654 u32 interrupt;
655 u8 baud_rate;
656 u8 parity;
657 u8 stop_bits;
658 u8 flow_control;
659 u8 terminal_type;
660 u8 reserved1;
661 u16 pci_device_id;
662 u16 pci_vendor_id;
663 u8 pci_bus;
664 u8 pci_device;
665 u8 pci_function;
666 u32 pci_flags;
667 u8 pci_segment;
668 u32 reserved2;
671 /* Masks for pci_flags field above */
673 #define ACPI_SPCR_DO_NOT_DISABLE (1)
675 /*******************************************************************************
677 * SPMI - Server Platform Management Interface table
678 * Version 5
680 * Conforms to "Intelligent Platform Management Interface Specification
681 * Second Generation v2.0", Document Revision 1.0, February 12, 2004 with
682 * June 12, 2009 markup.
684 ******************************************************************************/
686 struct acpi_table_spmi {
687 struct acpi_table_header header; /* Common ACPI table header */
688 u8 interface_type;
689 u8 reserved; /* Must be 1 */
690 u16 spec_revision; /* Version of IPMI */
691 u8 interrupt_type;
692 u8 gpe_number; /* GPE assigned */
693 u8 reserved1;
694 u8 pci_device_flag;
695 u32 interrupt;
696 struct acpi_generic_address ipmi_register;
697 u8 pci_segment;
698 u8 pci_bus;
699 u8 pci_device;
700 u8 pci_function;
701 u8 reserved2;
704 /* Values for interface_type above */
706 enum acpi_spmi_interface_types {
707 ACPI_SPMI_NOT_USED = 0,
708 ACPI_SPMI_KEYBOARD = 1,
709 ACPI_SPMI_SMI = 2,
710 ACPI_SPMI_BLOCK_TRANSFER = 3,
711 ACPI_SPMI_SMBUS = 4,
712 ACPI_SPMI_RESERVED = 5 /* 5 and above are reserved */
715 /*******************************************************************************
717 * TCPA - Trusted Computing Platform Alliance table
718 * Version 1
720 * Conforms to "TCG PC Specific Implementation Specification",
721 * Version 1.1, August 18, 2003
723 ******************************************************************************/
725 struct acpi_table_tcpa {
726 struct acpi_table_header header; /* Common ACPI table header */
727 u16 reserved;
728 u32 max_log_length; /* Maximum length for the event log area */
729 u64 log_address; /* Address of the event log area */
732 /*******************************************************************************
734 * UEFI - UEFI Boot optimization Table
735 * Version 1
737 * Conforms to "Unified Extensible Firmware Interface Specification",
738 * Version 2.3, May 8, 2009
740 ******************************************************************************/
742 struct acpi_table_uefi {
743 struct acpi_table_header header; /* Common ACPI table header */
744 u8 identifier[16]; /* UUID identifier */
745 u16 data_offset; /* Offset of remaining data in table */
748 /*******************************************************************************
750 * WAET - Windows ACPI Emulated devices Table
751 * Version 1
753 * Conforms to "Windows ACPI Emulated Devices Table", version 1.0, April 6, 2009
755 ******************************************************************************/
757 struct acpi_table_waet {
758 struct acpi_table_header header; /* Common ACPI table header */
759 u32 flags;
762 /* Masks for Flags field above */
764 #define ACPI_WAET_RTC_NO_ACK (1) /* RTC requires no int acknowledge */
765 #define ACPI_WAET_TIMER_ONE_READ (1<<1) /* PM timer requires only one read */
767 /*******************************************************************************
769 * WDAT - Watchdog Action Table
770 * Version 1
772 * Conforms to "Hardware Watchdog Timers Design Specification",
773 * Copyright 2006 Microsoft Corporation.
775 ******************************************************************************/
777 struct acpi_table_wdat {
778 struct acpi_table_header header; /* Common ACPI table header */
779 u32 header_length; /* Watchdog Header Length */
780 u16 pci_segment; /* PCI Segment number */
781 u8 pci_bus; /* PCI Bus number */
782 u8 pci_device; /* PCI Device number */
783 u8 pci_function; /* PCI Function number */
784 u8 reserved[3];
785 u32 timer_period; /* Period of one timer count (msec) */
786 u32 max_count; /* Maximum counter value supported */
787 u32 min_count; /* Minimum counter value */
788 u8 flags;
789 u8 reserved2[3];
790 u32 entries; /* Number of watchdog entries that follow */
793 /* Masks for Flags field above */
795 #define ACPI_WDAT_ENABLED (1)
796 #define ACPI_WDAT_STOPPED 0x80
798 /* WDAT Instruction Entries (actions) */
800 struct acpi_wdat_entry {
801 u8 action;
802 u8 instruction;
803 u16 reserved;
804 struct acpi_generic_address register_region;
805 u32 value; /* Value used with Read/Write register */
806 u32 mask; /* Bitmask required for this register instruction */
809 /* Values for Action field above */
811 enum acpi_wdat_actions {
812 ACPI_WDAT_RESET = 1,
813 ACPI_WDAT_GET_CURRENT_COUNTDOWN = 4,
814 ACPI_WDAT_GET_COUNTDOWN = 5,
815 ACPI_WDAT_SET_COUNTDOWN = 6,
816 ACPI_WDAT_GET_RUNNING_STATE = 8,
817 ACPI_WDAT_SET_RUNNING_STATE = 9,
818 ACPI_WDAT_GET_STOPPED_STATE = 10,
819 ACPI_WDAT_SET_STOPPED_STATE = 11,
820 ACPI_WDAT_GET_REBOOT = 16,
821 ACPI_WDAT_SET_REBOOT = 17,
822 ACPI_WDAT_GET_SHUTDOWN = 18,
823 ACPI_WDAT_SET_SHUTDOWN = 19,
824 ACPI_WDAT_GET_STATUS = 32,
825 ACPI_WDAT_SET_STATUS = 33,
826 ACPI_WDAT_ACTION_RESERVED = 34 /* 34 and greater are reserved */
829 /* Values for Instruction field above */
831 enum acpi_wdat_instructions {
832 ACPI_WDAT_READ_VALUE = 0,
833 ACPI_WDAT_READ_COUNTDOWN = 1,
834 ACPI_WDAT_WRITE_VALUE = 2,
835 ACPI_WDAT_WRITE_COUNTDOWN = 3,
836 ACPI_WDAT_INSTRUCTION_RESERVED = 4, /* 4 and greater are reserved */
837 ACPI_WDAT_PRESERVE_REGISTER = 0x80 /* Except for this value */
840 /*******************************************************************************
842 * WDRT - Watchdog Resource Table
843 * Version 1
845 * Conforms to "Watchdog Timer Hardware Requirements for Windows Server 2003",
846 * Version 1.01, August 28, 2006
848 ******************************************************************************/
850 struct acpi_table_wdrt {
851 struct acpi_table_header header; /* Common ACPI table header */
852 struct acpi_generic_address control_register;
853 struct acpi_generic_address count_register;
854 u16 pci_device_id;
855 u16 pci_vendor_id;
856 u8 pci_bus; /* PCI Bus number */
857 u8 pci_device; /* PCI Device number */
858 u8 pci_function; /* PCI Function number */
859 u8 pci_segment; /* PCI Segment number */
860 u16 max_count; /* Maximum counter value supported */
861 u8 units;
864 /* Reset to default packing */
866 #pragma pack()
868 #endif /* __ACTBL2_H__ */