actbl1.h 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727
  1. /******************************************************************************
  2. *
  3. * Name: actbl1.h - Additional ACPI table definitions
  4. *
  5. *****************************************************************************/
  6. /*
  7. * Copyright (C) 2000 - 2007, R. Byron Moore
  8. * All rights reserved.
  9. *
  10. * Redistribution and use in source and binary forms, with or without
  11. * modification, are permitted provided that the following conditions
  12. * are met:
  13. * 1. Redistributions of source code must retain the above copyright
  14. * notice, this list of conditions, and the following disclaimer,
  15. * without modification.
  16. * 2. Redistributions in binary form must reproduce at minimum a disclaimer
  17. * substantially similar to the "NO WARRANTY" disclaimer below
  18. * ("Disclaimer") and any redistribution must be conditioned upon
  19. * including a substantially similar Disclaimer requirement for further
  20. * binary redistribution.
  21. * 3. Neither the names of the above-listed copyright holders nor the names
  22. * of any contributors may be used to endorse or promote products derived
  23. * from this software without specific prior written permission.
  24. *
  25. * Alternatively, this software may be distributed under the terms of the
  26. * GNU General Public License ("GPL") version 2 as published by the Free
  27. * Software Foundation.
  28. *
  29. * NO WARRANTY
  30. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  31. * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  32. * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR
  33. * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
  34. * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  35. * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  36. * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  37. * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
  38. * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
  39. * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  40. * POSSIBILITY OF SUCH DAMAGES.
  41. */
  42. #ifndef __ACTBL1_H__
  43. #define __ACTBL1_H__
  44. /*******************************************************************************
  45. *
  46. * Additional ACPI Tables
  47. *
  48. * These tables are not consumed directly by the ACPICA subsystem, but are
  49. * included here to support device drivers and the AML disassembler.
  50. *
  51. ******************************************************************************/
  52. /*
  53. * Values for description table header signatures. Useful because they make
  54. * it more difficult to inadvertently type in the wrong signature.
  55. */
  56. #define ACPI_SIG_ASF "ASF!" /* Alert Standard Format table */
  57. #define ACPI_SIG_BOOT "BOOT" /* Simple Boot Flag Table */
  58. #define ACPI_SIG_CPEP "CPEP" /* Corrected Platform Error Polling table */
  59. #define ACPI_SIG_DBGP "DBGP" /* Debug Port table */
  60. #define ACPI_SIG_DMAR "DMAR" /* DMA Remapping table */
  61. #define ACPI_SIG_ECDT "ECDT" /* Embedded Controller Boot Resources Table */
  62. #define ACPI_SIG_HPET "HPET" /* High Precision Event Timer table */
  63. #define ACPI_SIG_MADT "APIC" /* Multiple APIC Description Table */
  64. #define ACPI_SIG_MCFG "MCFG" /* PCI Memory Mapped Configuration table */
  65. #define ACPI_SIG_SBST "SBST" /* Smart Battery Specification Table */
  66. #define ACPI_SIG_SLIT "SLIT" /* System Locality Distance Information Table */
  67. #define ACPI_SIG_SPCR "SPCR" /* Serial Port Console Redirection table */
  68. #define ACPI_SIG_SPMI "SPMI" /* Server Platform Management Interface table */
  69. #define ACPI_SIG_SRAT "SRAT" /* System Resource Affinity Table */
  70. #define ACPI_SIG_TCPA "TCPA" /* Trusted Computing Platform Alliance table */
  71. #define ACPI_SIG_WDRT "WDRT" /* Watchdog Resource Table */
  72. /*
  73. * All tables must be byte-packed to match the ACPI specification, since
  74. * the tables are provided by the system BIOS.
  75. */
  76. #pragma pack(1)
  77. /*
  78. * Note about bitfields: The u8 type is used for bitfields in ACPI tables.
  79. * This is the only type that is even remotely portable. Anything else is not
  80. * portable, so do not use any other bitfield types.
  81. */
  82. /* Common Sub-table header (used in MADT, SRAT, etc.) */
  83. struct acpi_subtable_header {
  84. u8 type;
  85. u8 length;
  86. };
  87. /*******************************************************************************
  88. *
  89. * ASF - Alert Standard Format table (Signature "ASF!")
  90. *
  91. * Conforms to the Alert Standard Format Specification V2.0, 23 April 2003
  92. *
  93. ******************************************************************************/
  94. struct acpi_table_asf {
  95. struct acpi_table_header header; /* Common ACPI table header */
  96. };
  97. /* ASF subtable header */
  98. struct acpi_asf_header {
  99. u8 type;
  100. u8 reserved;
  101. u16 length;
  102. };
  103. /* Values for Type field above */
  104. enum acpi_asf_type {
  105. ACPI_ASF_TYPE_INFO = 0,
  106. ACPI_ASF_TYPE_ALERT = 1,
  107. ACPI_ASF_TYPE_CONTROL = 2,
  108. ACPI_ASF_TYPE_BOOT = 3,
  109. ACPI_ASF_TYPE_ADDRESS = 4,
  110. ACPI_ASF_TYPE_RESERVED = 5
  111. };
  112. /*
  113. * ASF subtables
  114. */
  115. /* 0: ASF Information */
  116. struct acpi_asf_info {
  117. struct acpi_asf_header header;
  118. u8 min_reset_value;
  119. u8 min_poll_interval;
  120. u16 system_id;
  121. u32 mfg_id;
  122. u8 flags;
  123. u8 reserved2[3];
  124. };
  125. /* 1: ASF Alerts */
  126. struct acpi_asf_alert {
  127. struct acpi_asf_header header;
  128. u8 assert_mask;
  129. u8 deassert_mask;
  130. u8 alerts;
  131. u8 data_length;
  132. };
  133. struct acpi_asf_alert_data {
  134. u8 address;
  135. u8 command;
  136. u8 mask;
  137. u8 value;
  138. u8 sensor_type;
  139. u8 type;
  140. u8 offset;
  141. u8 source_type;
  142. u8 severity;
  143. u8 sensor_number;
  144. u8 entity;
  145. u8 instance;
  146. };
  147. /* 2: ASF Remote Control */
  148. struct acpi_asf_remote {
  149. struct acpi_asf_header header;
  150. u8 controls;
  151. u8 data_length;
  152. u16 reserved2;
  153. };
  154. struct acpi_asf_control_data {
  155. u8 function;
  156. u8 address;
  157. u8 command;
  158. u8 value;
  159. };
  160. /* 3: ASF RMCP Boot Options */
  161. struct acpi_asf_rmcp {
  162. struct acpi_asf_header header;
  163. u8 capabilities[7];
  164. u8 completion_code;
  165. u32 enterprise_id;
  166. u8 command;
  167. u16 parameter;
  168. u16 boot_options;
  169. u16 oem_parameters;
  170. };
  171. /* 4: ASF Address */
  172. struct acpi_asf_address {
  173. struct acpi_asf_header header;
  174. u8 eprom_address;
  175. u8 devices;
  176. };
  177. /*******************************************************************************
  178. *
  179. * BOOT - Simple Boot Flag Table
  180. *
  181. ******************************************************************************/
  182. struct acpi_table_boot {
  183. struct acpi_table_header header; /* Common ACPI table header */
  184. u8 cmos_index; /* Index in CMOS RAM for the boot register */
  185. u8 reserved[3];
  186. };
  187. /*******************************************************************************
  188. *
  189. * CPEP - Corrected Platform Error Polling table
  190. *
  191. ******************************************************************************/
  192. struct acpi_table_cpep {
  193. struct acpi_table_header header; /* Common ACPI table header */
  194. u64 reserved;
  195. };
  196. /* Subtable */
  197. struct acpi_cpep_polling {
  198. u8 type;
  199. u8 length;
  200. u8 id; /* Processor ID */
  201. u8 eid; /* Processor EID */
  202. u32 interval; /* Polling interval (msec) */
  203. };
  204. /*******************************************************************************
  205. *
  206. * DBGP - Debug Port table
  207. *
  208. ******************************************************************************/
  209. struct acpi_table_dbgp {
  210. struct acpi_table_header header; /* Common ACPI table header */
  211. u8 type; /* 0=full 16550, 1=subset of 16550 */
  212. u8 reserved[3];
  213. struct acpi_generic_address debug_port;
  214. };
  215. /*******************************************************************************
  216. *
  217. * DMAR - DMA Remapping table
  218. *
  219. ******************************************************************************/
  220. struct acpi_table_dmar {
  221. struct acpi_table_header header; /* Common ACPI table header */
  222. u8 width; /* Host Address Width */
  223. u8 flags;
  224. u8 reserved[10];
  225. };
  226. /* DMAR subtable header */
  227. struct acpi_dmar_header {
  228. u16 type;
  229. u16 length;
  230. };
  231. /* Values for subtable type in struct acpi_dmar_header */
  232. enum acpi_dmar_type {
  233. ACPI_DMAR_TYPE_HARDWARE_UNIT = 0,
  234. ACPI_DMAR_TYPE_RESERVED_MEMORY = 1,
  235. ACPI_DMAR_TYPE_ATSR = 2,
  236. ACPI_DMAR_TYPE_RESERVED = 3 /* 3 and greater are reserved */
  237. };
  238. struct acpi_dmar_device_scope {
  239. u8 entry_type;
  240. u8 length;
  241. u16 reserved;
  242. u8 enumeration_id;
  243. u8 bus;
  244. };
  245. /* Values for entry_type in struct acpi_dmar_device_scope */
  246. enum acpi_dmar_scope_type {
  247. ACPI_DMAR_SCOPE_TYPE_NOT_USED = 0,
  248. ACPI_DMAR_SCOPE_TYPE_ENDPOINT = 1,
  249. ACPI_DMAR_SCOPE_TYPE_BRIDGE = 2,
  250. ACPI_DMAR_SCOPE_TYPE_IOAPIC = 3,
  251. ACPI_DMAR_SCOPE_TYPE_HPET = 4,
  252. ACPI_DMAR_SCOPE_TYPE_RESERVED = 5 /* 5 and greater are reserved */
  253. };
  254. struct acpi_dmar_pci_path {
  255. u8 dev;
  256. u8 fn;
  257. };
  258. /*
  259. * DMAR Sub-tables, correspond to Type in struct acpi_dmar_header
  260. */
  261. /* 0: Hardware Unit Definition */
  262. struct acpi_dmar_hardware_unit {
  263. struct acpi_dmar_header header;
  264. u8 flags;
  265. u8 reserved;
  266. u16 segment;
  267. u64 address; /* Register Base Address */
  268. };
  269. /* Flags */
  270. #define ACPI_DMAR_INCLUDE_ALL (1)
  271. /* 1: Reserved Memory Defininition */
  272. struct acpi_dmar_reserved_memory {
  273. struct acpi_dmar_header header;
  274. u16 reserved;
  275. u16 segment;
  276. u64 base_address; /* 4_k aligned base address */
  277. u64 end_address; /* 4_k aligned limit address */
  278. };
  279. /* Flags */
  280. #define ACPI_DMAR_ALLOW_ALL (1)
  281. /*******************************************************************************
  282. *
  283. * ECDT - Embedded Controller Boot Resources Table
  284. *
  285. ******************************************************************************/
  286. struct acpi_table_ecdt {
  287. struct acpi_table_header header; /* Common ACPI table header */
  288. struct acpi_generic_address control; /* Address of EC command/status register */
  289. struct acpi_generic_address data; /* Address of EC data register */
  290. u32 uid; /* Unique ID - must be same as the EC _UID method */
  291. u8 gpe; /* The GPE for the EC */
  292. u8 id[1]; /* Full namepath of the EC in the ACPI namespace */
  293. };
  294. /*******************************************************************************
  295. *
  296. * HPET - High Precision Event Timer table
  297. *
  298. ******************************************************************************/
  299. struct acpi_table_hpet {
  300. struct acpi_table_header header; /* Common ACPI table header */
  301. u32 id; /* Hardware ID of event timer block */
  302. struct acpi_generic_address address; /* Address of event timer block */
  303. u8 sequence; /* HPET sequence number */
  304. u16 minimum_tick; /* Main counter min tick, periodic mode */
  305. u8 flags;
  306. };
  307. /*! Flags */
  308. #define ACPI_HPET_PAGE_PROTECT (1) /* 00: No page protection */
  309. #define ACPI_HPET_PAGE_PROTECT_4 (1<<1) /* 01: 4KB page protected */
  310. #define ACPI_HPET_PAGE_PROTECT_64 (1<<2) /* 02: 64KB page protected */
  311. /*! [End] no source code translation !*/
  312. /*******************************************************************************
  313. *
  314. * MADT - Multiple APIC Description Table
  315. *
  316. ******************************************************************************/
  317. struct acpi_table_madt {
  318. struct acpi_table_header header; /* Common ACPI table header */
  319. u32 address; /* Physical address of local APIC */
  320. u32 flags;
  321. };
  322. /* Flags */
  323. #define ACPI_MADT_PCAT_COMPAT (1) /* 00: System also has dual 8259s */
  324. /* Values for PCATCompat flag */
  325. #define ACPI_MADT_DUAL_PIC 0
  326. #define ACPI_MADT_MULTIPLE_APIC 1
  327. /* Values for subtable type in struct acpi_subtable_header */
  328. enum acpi_madt_type {
  329. ACPI_MADT_TYPE_LOCAL_APIC = 0,
  330. ACPI_MADT_TYPE_IO_APIC = 1,
  331. ACPI_MADT_TYPE_INTERRUPT_OVERRIDE = 2,
  332. ACPI_MADT_TYPE_NMI_SOURCE = 3,
  333. ACPI_MADT_TYPE_LOCAL_APIC_NMI = 4,
  334. ACPI_MADT_TYPE_LOCAL_APIC_OVERRIDE = 5,
  335. ACPI_MADT_TYPE_IO_SAPIC = 6,
  336. ACPI_MADT_TYPE_LOCAL_SAPIC = 7,
  337. ACPI_MADT_TYPE_INTERRUPT_SOURCE = 8,
  338. ACPI_MADT_TYPE_RESERVED = 9 /* 9 and greater are reserved */
  339. };
  340. /*
  341. * MADT Sub-tables, correspond to Type in struct acpi_subtable_header
  342. */
  343. /* 0: Processor Local APIC */
  344. struct acpi_madt_local_apic {
  345. struct acpi_subtable_header header;
  346. u8 processor_id; /* ACPI processor id */
  347. u8 id; /* Processor's local APIC id */
  348. u32 lapic_flags;
  349. };
  350. /* 1: IO APIC */
  351. struct acpi_madt_io_apic {
  352. struct acpi_subtable_header header;
  353. u8 id; /* I/O APIC ID */
  354. u8 reserved; /* Reserved - must be zero */
  355. u32 address; /* APIC physical address */
  356. u32 global_irq_base; /* Global system interrupt where INTI lines start */
  357. };
  358. /* 2: Interrupt Override */
  359. struct acpi_madt_interrupt_override {
  360. struct acpi_subtable_header header;
  361. u8 bus; /* 0 - ISA */
  362. u8 source_irq; /* Interrupt source (IRQ) */
  363. u32 global_irq; /* Global system interrupt */
  364. u16 inti_flags;
  365. };
  366. /* 3: NMI Source */
  367. struct acpi_madt_nmi_source {
  368. struct acpi_subtable_header header;
  369. u16 inti_flags;
  370. u32 global_irq; /* Global system interrupt */
  371. };
  372. /* 4: Local APIC NMI */
  373. struct acpi_madt_local_apic_nmi {
  374. struct acpi_subtable_header header;
  375. u8 processor_id; /* ACPI processor id */
  376. u16 inti_flags;
  377. u8 lint; /* LINTn to which NMI is connected */
  378. };
  379. /* 5: Address Override */
  380. struct acpi_madt_local_apic_override {
  381. struct acpi_subtable_header header;
  382. u16 reserved; /* Reserved, must be zero */
  383. u64 address; /* APIC physical address */
  384. };
  385. /* 6: I/O Sapic */
  386. struct acpi_madt_io_sapic {
  387. struct acpi_subtable_header header;
  388. u8 id; /* I/O SAPIC ID */
  389. u8 reserved; /* Reserved, must be zero */
  390. u32 global_irq_base; /* Global interrupt for SAPIC start */
  391. u64 address; /* SAPIC physical address */
  392. };
  393. /* 7: Local Sapic */
  394. struct acpi_madt_local_sapic {
  395. struct acpi_subtable_header header;
  396. u8 processor_id; /* ACPI processor id */
  397. u8 id; /* SAPIC ID */
  398. u8 eid; /* SAPIC EID */
  399. u8 reserved[3]; /* Reserved, must be zero */
  400. u32 lapic_flags;
  401. u32 uid; /* Numeric UID - ACPI 3.0 */
  402. char uid_string[1]; /* String UID - ACPI 3.0 */
  403. };
  404. /* 8: Platform Interrupt Source */
  405. struct acpi_madt_interrupt_source {
  406. struct acpi_subtable_header header;
  407. u16 inti_flags;
  408. u8 type; /* 1=PMI, 2=INIT, 3=corrected */
  409. u8 id; /* Processor ID */
  410. u8 eid; /* Processor EID */
  411. u8 io_sapic_vector; /* Vector value for PMI interrupts */
  412. u32 global_irq; /* Global system interrupt */
  413. u32 flags; /* Interrupt Source Flags */
  414. };
  415. /* Flags field above */
  416. #define ACPI_MADT_CPEI_OVERRIDE (1)
  417. /*
  418. * Common flags fields for MADT subtables
  419. */
  420. /* MADT Local APIC flags (lapic_flags) */
  421. #define ACPI_MADT_ENABLED (1) /* 00: Processor is usable if set */
  422. /* MADT MPS INTI flags (inti_flags) */
  423. #define ACPI_MADT_POLARITY_MASK (3) /* 00-01: Polarity of APIC I/O input signals */
  424. #define ACPI_MADT_TRIGGER_MASK (3<<2) /* 02-03: Trigger mode of APIC input signals */
  425. /* Values for MPS INTI flags */
  426. #define ACPI_MADT_POLARITY_CONFORMS 0
  427. #define ACPI_MADT_POLARITY_ACTIVE_HIGH 1
  428. #define ACPI_MADT_POLARITY_RESERVED 2
  429. #define ACPI_MADT_POLARITY_ACTIVE_LOW 3
  430. #define ACPI_MADT_TRIGGER_CONFORMS (0)
  431. #define ACPI_MADT_TRIGGER_EDGE (1<<2)
  432. #define ACPI_MADT_TRIGGER_RESERVED (2<<2)
  433. #define ACPI_MADT_TRIGGER_LEVEL (3<<2)
  434. /*******************************************************************************
  435. *
  436. * MCFG - PCI Memory Mapped Configuration table and sub-table
  437. *
  438. ******************************************************************************/
  439. struct acpi_table_mcfg {
  440. struct acpi_table_header header; /* Common ACPI table header */
  441. u8 reserved[8];
  442. };
  443. /* Subtable */
  444. struct acpi_mcfg_allocation {
  445. u64 address; /* Base address, processor-relative */
  446. u16 pci_segment; /* PCI segment group number */
  447. u8 start_bus_number; /* Starting PCI Bus number */
  448. u8 end_bus_number; /* Final PCI Bus number */
  449. u32 reserved;
  450. };
  451. /*******************************************************************************
  452. *
  453. * SBST - Smart Battery Specification Table
  454. *
  455. ******************************************************************************/
  456. struct acpi_table_sbst {
  457. struct acpi_table_header header; /* Common ACPI table header */
  458. u32 warning_level;
  459. u32 low_level;
  460. u32 critical_level;
  461. };
  462. /*******************************************************************************
  463. *
  464. * SLIT - System Locality Distance Information Table
  465. *
  466. ******************************************************************************/
  467. struct acpi_table_slit {
  468. struct acpi_table_header header; /* Common ACPI table header */
  469. u64 locality_count;
  470. u8 entry[1]; /* Real size = localities^2 */
  471. };
  472. /*******************************************************************************
  473. *
  474. * SPCR - Serial Port Console Redirection table
  475. *
  476. ******************************************************************************/
  477. struct acpi_table_spcr {
  478. struct acpi_table_header header; /* Common ACPI table header */
  479. u8 interface_type; /* 0=full 16550, 1=subset of 16550 */
  480. u8 reserved[3];
  481. struct acpi_generic_address serial_port;
  482. u8 interrupt_type;
  483. u8 pc_interrupt;
  484. u32 interrupt;
  485. u8 baud_rate;
  486. u8 parity;
  487. u8 stop_bits;
  488. u8 flow_control;
  489. u8 terminal_type;
  490. u8 reserved1;
  491. u16 pci_device_id;
  492. u16 pci_vendor_id;
  493. u8 pci_bus;
  494. u8 pci_device;
  495. u8 pci_function;
  496. u32 pci_flags;
  497. u8 pci_segment;
  498. u32 reserved2;
  499. };
  500. /*******************************************************************************
  501. *
  502. * SPMI - Server Platform Management Interface table
  503. *
  504. ******************************************************************************/
  505. struct acpi_table_spmi {
  506. struct acpi_table_header header; /* Common ACPI table header */
  507. u8 reserved;
  508. u8 interface_type;
  509. u16 spec_revision; /* Version of IPMI */
  510. u8 interrupt_type;
  511. u8 gpe_number; /* GPE assigned */
  512. u8 reserved1;
  513. u8 pci_device_flag;
  514. u32 interrupt;
  515. struct acpi_generic_address ipmi_register;
  516. u8 pci_segment;
  517. u8 pci_bus;
  518. u8 pci_device;
  519. u8 pci_function;
  520. };
  521. /*******************************************************************************
  522. *
  523. * SRAT - System Resource Affinity Table
  524. *
  525. ******************************************************************************/
  526. struct acpi_table_srat {
  527. struct acpi_table_header header; /* Common ACPI table header */
  528. u32 table_revision; /* Must be value '1' */
  529. u64 reserved; /* Reserved, must be zero */
  530. };
  531. /* Values for subtable type in struct acpi_subtable_header */
  532. enum acpi_srat_type {
  533. ACPI_SRAT_TYPE_CPU_AFFINITY = 0,
  534. ACPI_SRAT_TYPE_MEMORY_AFFINITY = 1,
  535. ACPI_SRAT_TYPE_RESERVED = 2
  536. };
  537. /* SRAT sub-tables */
  538. struct acpi_srat_cpu_affinity {
  539. struct acpi_subtable_header header;
  540. u8 proximity_domain_lo;
  541. u8 apic_id;
  542. u32 flags;
  543. u8 local_sapic_eid;
  544. u8 proximity_domain_hi[3];
  545. u32 reserved; /* Reserved, must be zero */
  546. };
  547. /* Flags */
  548. #define ACPI_SRAT_CPU_ENABLED (1) /* 00: Use affinity structure */
  549. struct acpi_srat_mem_affinity {
  550. struct acpi_subtable_header header;
  551. u32 proximity_domain;
  552. u16 reserved; /* Reserved, must be zero */
  553. u64 base_address;
  554. u64 length;
  555. u32 memory_type; /* See acpi_address_range_id */
  556. u32 flags;
  557. u64 reserved1; /* Reserved, must be zero */
  558. };
  559. /* Flags */
  560. #define ACPI_SRAT_MEM_ENABLED (1) /* 00: Use affinity structure */
  561. #define ACPI_SRAT_MEM_HOT_PLUGGABLE (1<<1) /* 01: Memory region is hot pluggable */
  562. #define ACPI_SRAT_MEM_NON_VOLATILE (1<<2) /* 02: Memory region is non-volatile */
  563. /*******************************************************************************
  564. *
  565. * TCPA - Trusted Computing Platform Alliance table
  566. *
  567. ******************************************************************************/
  568. struct acpi_table_tcpa {
  569. struct acpi_table_header header; /* Common ACPI table header */
  570. u16 reserved;
  571. u32 max_log_length; /* Maximum length for the event log area */
  572. u64 log_address; /* Address of the event log area */
  573. };
  574. /*******************************************************************************
  575. *
  576. * WDRT - Watchdog Resource Table
  577. *
  578. ******************************************************************************/
  579. struct acpi_table_wdrt {
  580. struct acpi_table_header header; /* Common ACPI table header */
  581. u32 header_length; /* Watchdog Header Length */
  582. u8 pci_segment; /* PCI Segment number */
  583. u8 pci_bus; /* PCI Bus number */
  584. u8 pci_device; /* PCI Device number */
  585. u8 pci_function; /* PCI Function number */
  586. u32 timer_period; /* Period of one timer count (msec) */
  587. u32 max_count; /* Maximum counter value supported */
  588. u32 min_count; /* Minimum counter value */
  589. u8 flags;
  590. u8 reserved[3];
  591. u32 entries; /* Number of watchdog entries that follow */
  592. };
  593. /* Flags */
  594. #define ACPI_WDRT_TIMER_ENABLED (1) /* 00: Timer enabled */
  595. /* Reset to default packing */
  596. #pragma pack()
  597. #endif /* __ACTBL1_H__ */