Module Name: src Committed By: jruoho Date: Tue Jun 8 16:55:02 UTC 2010
Modified Files: src/sys/dev/acpi: acpivar.h Log Message: Add and organize some comments. Add also ACPI_DEVICE_EJECT constant to indicate "ejectable" devices such as docking stations. To generate a diff of this commit: cvs rdiff -u -r1.56 -r1.57 src/sys/dev/acpi/acpivar.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/dev/acpi/acpivar.h diff -u src/sys/dev/acpi/acpivar.h:1.56 src/sys/dev/acpi/acpivar.h:1.57 --- src/sys/dev/acpi/acpivar.h:1.56 Mon Jun 7 01:45:27 2010 +++ src/sys/dev/acpi/acpivar.h Tue Jun 8 16:55:02 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: acpivar.h,v 1.56 2010/06/07 01:45:27 pgoyette Exp $ */ +/* $NetBSD: acpivar.h,v 1.57 2010/06/08 16:55:02 jruoho Exp $ */ /* * Copyright 2001 Wasabi Systems, Inc. @@ -57,20 +57,14 @@ * This structure is used to attach the ACPI "bus". */ struct acpibus_attach_args { - bus_space_tag_t aa_iot; /* PCI I/O space tag */ - bus_space_tag_t aa_memt; /* PCI MEM space tag */ - pci_chipset_tag_t aa_pc; /* PCI chipset */ - int aa_pciflags; /* PCI bus flags */ - isa_chipset_tag_t aa_ic; /* ISA chipset */ + bus_space_tag_t aa_iot; /* PCI I/O space tag */ + bus_space_tag_t aa_memt; /* PCI MEM space tag */ + pci_chipset_tag_t aa_pc; /* PCI chipset */ + int aa_pciflags; /* PCI bus flags */ + isa_chipset_tag_t aa_ic; /* ISA chipset */ }; /* - * ACPI driver capabilities. - */ -#define ACPI_DEVICE_POWER __BIT(0) -#define ACPI_DEVICE_WAKEUP __BIT(1) - -/* * PCI information for ACPI device nodes that correspond to PCI devices. */ struct acpi_pci_info { @@ -94,6 +88,9 @@ * ad_notify NULL if there is no notify handler * ad_devinfo never NULL * ad_handle never NULL + * + * Each ACPI device node is associated with its handle. The function + * acpi_get_node() can be used to get the node structure from a handle. */ struct acpi_devnode { device_t ad_device; /* Device */ @@ -115,6 +112,13 @@ }; /* + * ACPI driver capabilities. + */ +#define ACPI_DEVICE_POWER __BIT(0) /* Support for D-states */ +#define ACPI_DEVICE_WAKEUP __BIT(1) /* Support for wake-up */ +#define ACPI_DEVICE_EJECT __BIT(2) /* Support for "ejection" */ + +/* * Software state of the ACPI subsystem. */ struct acpi_softc { @@ -166,7 +170,6 @@ * acpi_irq Interrupt Request * acpi_drq DMA request */ - struct acpi_io { SIMPLEQ_ENTRY(acpi_io) ar_list; int ar_index;