blob: f8ed870153b6d41e3e26984757a91c6e9d6127b8 [file] [log] [blame]
Kevin O'Connor276d4a92008-06-11 22:47:01 -04001#ifndef __ACPI_H
2#define __ACPI_H
3
4#include "types.h" // u32
5
6void acpi_bios_init(void);
Kevin O'Connor9967ab72008-12-18 21:57:33 -05007u32 find_resume_vector();
Kevin O'Connor276d4a92008-06-11 22:47:01 -04008
Kevin O'Connore10e6f82008-06-21 19:46:43 -04009#define RSDP_SIGNATURE 0x2052545020445352LL // "RSD PTR "
10
Kevin O'Connor276d4a92008-06-11 22:47:01 -040011struct rsdp_descriptor /* Root System Descriptor Pointer */
12{
Kevin O'Connor9967ab72008-12-18 21:57:33 -050013 u64 signature; /* ACPI signature, contains "RSD PTR " */
Kevin O'Connor276d4a92008-06-11 22:47:01 -040014 u8 checksum; /* To make sum of struct == 0 */
15 u8 oem_id [6]; /* OEM identification */
16 u8 revision; /* Must be 0 for 1.0, 2 for 2.0 */
17 u32 rsdt_physical_address; /* 32-bit physical address of RSDT */
18 u32 length; /* XSDT Length in bytes including hdr */
19 u64 xsdt_physical_address; /* 64-bit physical address of XSDT */
20 u8 extended_checksum; /* Checksum of entire table */
21 u8 reserved [3]; /* Reserved field must be 0 */
22};
23
Kevin O'Connor9967ab72008-12-18 21:57:33 -050024extern struct rsdp_descriptor *RsdpAddr;
25
Kevin O'Connore10e6f82008-06-21 19:46:43 -040026// XXX - not really part of acpi.
27struct mptable_floating_s {
28 u32 signature;
29 u32 physaddr;
30 u8 length;
31 u8 spec_rev;
32 u8 checksum;
33 u8 feature1;
34 u8 feature2;
35 u8 reserved[3];
36};
37
38#define MPTABLE_SIGNAURE 0x5f504d5f // "_MP_"
39
Kevin O'Connor276d4a92008-06-11 22:47:01 -040040#endif // acpi.h