From: Gleb Natapov <gleb@redhat.com>
To: qemu-devel@nongnu.org
Cc: lersek@redhat.com
Subject: [Qemu-devel] [PATCH] reset PMBA and PMREGMISC PIIX4 registers.
Date: Tue, 7 Aug 2012 15:52:03 +0300 [thread overview]
Message-ID: <20120807125203.GC3341@redhat.com> (raw)
The bug causes Windows + OVMF hang after reboot since OVMF
checks PMREGMISC to see if IO space is enabled and skip
configuration if it is.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
diff --git a/hw/acpi_piix4.c b/hw/acpi_piix4.c
index 0aace60..90b46b5 100644
--- a/hw/acpi_piix4.c
+++ b/hw/acpi_piix4.c
@@ -353,6 +353,9 @@ static void piix4_reset(void *opaque)
pci_conf[0x5a] = 0;
pci_conf[0x5b] = 0;
+ pci_conf[0x40] = 0x01; /* PM io base read only bit */
+ pci_conf[0x80] = 0;
+
if (s->kvm_enabled) {
/* Mark SMM as already inited (until KVM supports SMM). */
pci_conf[0x5B] = 0x02;
@@ -392,8 +395,6 @@ static int piix4_pm_initfn(PCIDevice *dev)
pci_conf[0x09] = 0x00;
pci_conf[0x3d] = 0x01; // interrupt pin 1
- pci_conf[0x40] = 0x01; /* PM io base read only bit */
-
/* APM */
apm_init(&s->apm, apm_ctrl_changed, s);
--
Gleb.
next reply other threads:[~2012-08-07 12:52 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-07 12:52 Gleb Natapov [this message]
2012-08-07 13:03 ` [Qemu-devel] [PATCH] reset PMBA and PMREGMISC PIIX4 registers Laszlo Ersek
2012-08-15 16:48 ` Gleb Natapov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20120807125203.GC3341@redhat.com \
--to=gleb@redhat.com \
--cc=lersek@redhat.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).