From: Alon Levy <alevy@redhat.com>
To: qemu-devel@nongnu.org
Cc: kraxel@redhat.com
Subject: [Qemu-devel] [RFC] reduce reported VGA framebuffer to 8 MiB
Date: Wed, 25 May 2011 16:53:49 +0300 [thread overview]
Message-ID: <1306331629-31041-1-git-send-email-alevy@redhat.com> (raw)
Without this windows xp guests set a 4 bits per pixel graphics mode.
With it we get the same behavior as with -vga std, that is a 32 bpp
graphics mode. This fits the size reported by hw/vga-pci.c .
---
Sending as RFC since I'm not sure if this is the right thing, nor that
it doesn't actually interfere with anything else. I did however do the testing
with and without mentioned in the patch comment and code comment.
---
hw/qxl.c | 9 ++++++++-
1 files changed, 8 insertions(+), 1 deletions(-)
diff --git a/hw/qxl.c b/hw/qxl.c
index 9a0f588..f6ff9f2 100644
--- a/hw/qxl.c
+++ b/hw/qxl.c
@@ -1332,7 +1332,14 @@ static int qxl_init_primary(PCIDevice *dev)
if (ram_size < 32 * 1024 * 1024) {
ram_size = 32 * 1024 * 1024;
}
- vga_common_init(vga, ram_size);
+ /*
+ * windows xp guests don't like larger then VGA_RAM_SIZE (8 MiB),
+ * wrongly setting the display to 4 bit color depth. This fix doesn't
+ * affect native mode, where we have modes that require larger amounts
+ * of ram. (The maximum that VBE reports is 1600x1200 32 bit color depth
+ * which fits)
+ */
+ vga_common_init(vga, VGA_RAM_SIZE);
vga_init(vga);
register_ioport_write(0x3c0, 16, 1, qxl_vga_ioport_write, vga);
register_ioport_write(0x3b4, 2, 1, qxl_vga_ioport_write, vga);
--
1.7.5.1
next reply other threads:[~2011-05-25 14:47 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-25 13:53 Alon Levy [this message]
2011-05-25 14:06 ` [Qemu-devel] [RFC] reduce reported VGA framebuffer to 8 MiB Gerd Hoffmann
2011-05-25 14:33 ` Alon Levy
2011-05-25 14:49 ` Alon Levy
2011-05-26 6:50 ` Gerd Hoffmann
2011-05-26 7:11 ` Alon Levy
2011-05-26 7:44 ` Gerd Hoffmann
2011-05-26 8:15 ` Alon Levy
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=1306331629-31041-1-git-send-email-alevy@redhat.com \
--to=alevy@redhat.com \
--cc=kraxel@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).