Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20190201' into...
[qemu/kevin.git] / include / hw / isa / apm.h
blobb7098bf7caa8d242208f9508313bd35b8965df97
1 #ifndef APM_H
2 #define APM_H
4 #include "qemu-common.h"
5 #include "hw/hw.h"
6 #include "exec/memory.h"
8 #define APM_CNT_IOPORT 0xb2
9 #define ACPI_PORT_SMI_CMD APM_CNT_IOPORT
11 typedef void (*apm_ctrl_changed_t)(uint32_t val, void *arg);
13 typedef struct APMState {
14 uint8_t apmc;
15 uint8_t apms;
17 apm_ctrl_changed_t callback;
18 void *arg;
19 MemoryRegion io;
20 } APMState;
22 void apm_init(PCIDevice *dev, APMState *s, apm_ctrl_changed_t callback,
23 void *arg);
25 extern const VMStateDescription vmstate_apm;
27 #endif /* APM_H */