OSDN Git Service
(root)
/
qmiga
/
qemu.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6ada745
)
Implement ACPI specs 3.0, 4.7.2.5, by Michael Hanselmann.
author
ths
<ths@c046a42c-6fe2-441c-8c8c-71466251a162>
Tue, 31 Jul 2007 23:32:11 +0000
(23:32 +0000)
committer
ths
<ths@c046a42c-6fe2-441c-8c8c-71466251a162>
Tue, 31 Jul 2007 23:32:11 +0000
(23:32 +0000)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3103
c046a42c
-6fe2-441c-8c8c-
71466251a162
hw/acpi.c
patch
|
blob
|
history
diff --git
a/hw/acpi.c
b/hw/acpi.c
index
ce3f7f2
..
871a737
100644
(file)
--- a/
hw/acpi.c
+++ b/
hw/acpi.c
@@
-54,6
+54,9
@@
typedef struct PIIX4PMState {
#define SUS_EN (1 << 13)
+#define ACPI_ENABLE 0xf1
+#define ACPI_DISABLE 0xf0
+
#define SMBHSTSTS 0x00
#define SMBHSTCNT 0x02
#define SMBHSTCMD 0x03
@@
-216,6
+219,14
@@
static void pm_smi_writeb(void *opaque, uint32_t addr, uint32_t val)
#endif
if (addr == 0) {
s->apmc = val;
+
+ /* ACPI specs 3.0, 4.7.2.5 */
+ if (val == ACPI_ENABLE) {
+ s->pmcntrl |= SCI_EN;
+ } else if (val == ACPI_DISABLE) {
+ s->pmcntrl &= ~SCI_EN;
+ }
+
if (s->dev.config[0x5b] & (1 << 1)) {
cpu_interrupt(first_cpu, CPU_INTERRUPT_SMI);
}