1#pragma once
2
3#include <uacpi/types.h>
4#include <uacpi/status.h>
5
6#ifdef __cplusplus
7extern "C" {
8#endif
9
10/*
11 * Install an address space handler to a device node.
12 * The handler is recursively connected to all of the operation regions of
13 * type 'space' underneath 'device_node'. Note that this recursion stops as
14 * soon as another device node that already has an address space handler of
15 * this type installed is encountered.
16 */
17uacpi_status uacpi_install_address_space_handler(
18 uacpi_namespace_node *device_node, enum uacpi_address_space space,
19 uacpi_region_handler handler, uacpi_handle handler_context
20);
21
22/*
23 * Uninstall the handler of type 'space' from a given device node.
24 */
25uacpi_status uacpi_uninstall_address_space_handler(
26 uacpi_namespace_node *device_node,
27 enum uacpi_address_space space
28);
29
30/*
31 * Execute _REG(space, ACPI_REG_CONNECT) for all of the opregions with this
32 * address space underneath this device. This should only be called manually
33 * if you want to register an early handler that must be available before the
34 * call to uacpi_namespace_initialize().
35 */
36uacpi_status uacpi_reg_all_opregions(
37 uacpi_namespace_node *device_node,
38 enum uacpi_address_space space
39);
40
41#ifdef __cplusplus
42}
43#endif
44