11da177e4SLinus Torvalds /* 21da177e4SLinus Torvalds * acpi_drivers.h ($Revision: 31 $) 31da177e4SLinus Torvalds * 41da177e4SLinus Torvalds * Copyright (C) 2001, 2002 Andy Grover <andrew.grover@intel.com> 51da177e4SLinus Torvalds * Copyright (C) 2001, 2002 Paul Diefenbaugh <paul.s.diefenbaugh@intel.com> 61da177e4SLinus Torvalds * 71da177e4SLinus Torvalds * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 81da177e4SLinus Torvalds * 91da177e4SLinus Torvalds * This program is free software; you can redistribute it and/or modify 101da177e4SLinus Torvalds * it under the terms of the GNU General Public License as published by 111da177e4SLinus Torvalds * the Free Software Foundation; either version 2 of the License, or (at 121da177e4SLinus Torvalds * your option) any later version. 131da177e4SLinus Torvalds * 141da177e4SLinus Torvalds * This program is distributed in the hope that it will be useful, but 151da177e4SLinus Torvalds * WITHOUT ANY WARRANTY; without even the implied warranty of 161da177e4SLinus Torvalds * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 171da177e4SLinus Torvalds * General Public License for more details. 181da177e4SLinus Torvalds * 191da177e4SLinus Torvalds * You should have received a copy of the GNU General Public License along 201da177e4SLinus Torvalds * with this program; if not, write to the Free Software Foundation, Inc., 211da177e4SLinus Torvalds * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. 221da177e4SLinus Torvalds * 231da177e4SLinus Torvalds * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 241da177e4SLinus Torvalds */ 251da177e4SLinus Torvalds 261da177e4SLinus Torvalds #ifndef __ACPI_DRIVERS_H__ 271da177e4SLinus Torvalds #define __ACPI_DRIVERS_H__ 281da177e4SLinus Torvalds 291da177e4SLinus Torvalds #include <linux/acpi.h> 301da177e4SLinus Torvalds #include <acpi/acpi_bus.h> 311da177e4SLinus Torvalds 321da177e4SLinus Torvalds 331da177e4SLinus Torvalds #define ACPI_MAX_STRING 80 341da177e4SLinus Torvalds 351da177e4SLinus Torvalds #define ACPI_BUS_COMPONENT 0x00010000 361da177e4SLinus Torvalds #define ACPI_SYSTEM_COMPONENT 0x02000000 371da177e4SLinus Torvalds 381da177e4SLinus Torvalds /* _HID definitions */ 391da177e4SLinus Torvalds 401da177e4SLinus Torvalds #define ACPI_POWER_HID "ACPI_PWR" 411da177e4SLinus Torvalds #define ACPI_PROCESSOR_HID "ACPI_CPU" 421da177e4SLinus Torvalds #define ACPI_SYSTEM_HID "ACPI_SYS" 431da177e4SLinus Torvalds #define ACPI_THERMAL_HID "ACPI_THM" 441da177e4SLinus Torvalds #define ACPI_BUTTON_HID_POWERF "ACPI_FPB" 451da177e4SLinus Torvalds #define ACPI_BUTTON_HID_SLEEPF "ACPI_FSB" 461da177e4SLinus Torvalds 471da177e4SLinus Torvalds 481da177e4SLinus Torvalds /* -------------------------------------------------------------------------- 491da177e4SLinus Torvalds PCI 501da177e4SLinus Torvalds -------------------------------------------------------------------------- */ 511da177e4SLinus Torvalds 521da177e4SLinus Torvalds #ifdef CONFIG_ACPI_PCI 531da177e4SLinus Torvalds 541da177e4SLinus Torvalds #define ACPI_PCI_COMPONENT 0x00400000 551da177e4SLinus Torvalds 561da177e4SLinus Torvalds /* ACPI PCI Interrupt Link (pci_link.c) */ 571da177e4SLinus Torvalds 581da177e4SLinus Torvalds int acpi_irq_penalty_init (void); 59*87bec66bSDavid Shaohua Li int acpi_pci_link_allocate_irq (acpi_handle handle, int index, int *edge_level, 601da177e4SLinus Torvalds int *active_high_low, char **name); 61*87bec66bSDavid Shaohua Li int acpi_pci_link_free_irq(acpi_handle handle); 621da177e4SLinus Torvalds 631da177e4SLinus Torvalds /* ACPI PCI Interrupt Routing (pci_irq.c) */ 641da177e4SLinus Torvalds 651da177e4SLinus Torvalds int acpi_pci_irq_add_prt (acpi_handle handle, int segment, int bus); 661da177e4SLinus Torvalds void acpi_pci_irq_del_prt (int segment, int bus); 671da177e4SLinus Torvalds 681da177e4SLinus Torvalds /* ACPI PCI Device Binding (pci_bind.c) */ 691da177e4SLinus Torvalds 701da177e4SLinus Torvalds struct pci_bus; 711da177e4SLinus Torvalds 721da177e4SLinus Torvalds int acpi_pci_bind (struct acpi_device *device); 731da177e4SLinus Torvalds int acpi_pci_unbind (struct acpi_device *device); 741da177e4SLinus Torvalds int acpi_pci_bind_root (struct acpi_device *device, struct acpi_pci_id *id, struct pci_bus *bus); 751da177e4SLinus Torvalds 761da177e4SLinus Torvalds /* Arch-defined function to add a bus to the system */ 771da177e4SLinus Torvalds 781da177e4SLinus Torvalds struct pci_bus *pci_acpi_scan_root(struct acpi_device *device, int domain, int bus); 791da177e4SLinus Torvalds 801da177e4SLinus Torvalds #endif /*CONFIG_ACPI_PCI*/ 811da177e4SLinus Torvalds 821da177e4SLinus Torvalds 831da177e4SLinus Torvalds /* -------------------------------------------------------------------------- 841da177e4SLinus Torvalds Power Resource 851da177e4SLinus Torvalds -------------------------------------------------------------------------- */ 861da177e4SLinus Torvalds 871da177e4SLinus Torvalds #ifdef CONFIG_ACPI_POWER 881da177e4SLinus Torvalds int acpi_enable_wakeup_device_power (struct acpi_device *dev); 891da177e4SLinus Torvalds int acpi_disable_wakeup_device_power (struct acpi_device *dev); 901da177e4SLinus Torvalds int acpi_power_get_inferred_state (struct acpi_device *device); 911da177e4SLinus Torvalds int acpi_power_transition (struct acpi_device *device, int state); 921da177e4SLinus Torvalds #endif 931da177e4SLinus Torvalds 941da177e4SLinus Torvalds 951da177e4SLinus Torvalds /* -------------------------------------------------------------------------- 961da177e4SLinus Torvalds Embedded Controller 971da177e4SLinus Torvalds -------------------------------------------------------------------------- */ 981da177e4SLinus Torvalds #ifdef CONFIG_ACPI_EC 991da177e4SLinus Torvalds int acpi_ec_ecdt_probe (void); 1001da177e4SLinus Torvalds #endif 1011da177e4SLinus Torvalds 1021da177e4SLinus Torvalds /* -------------------------------------------------------------------------- 1031da177e4SLinus Torvalds Processor 1041da177e4SLinus Torvalds -------------------------------------------------------------------------- */ 1051da177e4SLinus Torvalds 1061da177e4SLinus Torvalds #define ACPI_PROCESSOR_LIMIT_NONE 0x00 1071da177e4SLinus Torvalds #define ACPI_PROCESSOR_LIMIT_INCREMENT 0x01 1081da177e4SLinus Torvalds #define ACPI_PROCESSOR_LIMIT_DECREMENT 0x02 1091da177e4SLinus Torvalds 1101da177e4SLinus Torvalds int acpi_processor_set_thermal_limit(acpi_handle handle, int type); 1111da177e4SLinus Torvalds 112fb9802faSLuming Yu /* -------------------------------------------------------------------------- 113fb9802faSLuming Yu Hot Keys 114fb9802faSLuming Yu -------------------------------------------------------------------------- */ 115fb9802faSLuming Yu 116fb9802faSLuming Yu extern int acpi_specific_hotkey_enabled; 1171da177e4SLinus Torvalds 1181da177e4SLinus Torvalds #endif /*__ACPI_DRIVERS_H__*/ 119