apm.h (497B)
1#ifndef APM_H 2#define APM_H 3 4#include "exec/memory.h" 5 6#define APM_CNT_IOPORT 0xb2 7#define ACPI_PORT_SMI_CMD APM_CNT_IOPORT 8 9typedef void (*apm_ctrl_changed_t)(uint32_t val, void *arg); 10 11typedef struct APMState { 12 uint8_t apmc; 13 uint8_t apms; 14 15 apm_ctrl_changed_t callback; 16 void *arg; 17 MemoryRegion io; 18} APMState; 19 20void apm_init(PCIDevice *dev, APMState *s, apm_ctrl_changed_t callback, 21 void *arg); 22 23extern const VMStateDescription vmstate_apm; 24 25#endif /* APM_H */