]> git.proxmox.com Git - qemu.git/commitdiff
vga: fix bochs alignment issue
authorGerd Hoffmann <kraxel@redhat.com>
Mon, 12 Nov 2012 11:40:46 +0000 (12:40 +0100)
committerGerd Hoffmann <kraxel@redhat.com>
Fri, 16 Nov 2012 10:27:06 +0000 (11:27 +0100)
The bochs dispi interface traditionally uses port 0x1ce as 16bit index
register and port 0x1cf as 16bit data register.  The later is unaligned,
and probably for that reason the the data register was moved to 0x1d0
for non-x86 archs.

This patch makes the data register available at 0x1d0 on x86 too.  The
old x86 location is kept for compatibility reasons, so both 0x1cf and
0x1d0 can be used as data register on x86.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
docs/specs/standard-vga.txt
hw/vga.c

index 1cecccd46982179f6848116136bffe8d862e8a1e..8a4c1e93cd46f19d7ce3e66ab9a2e9fcb0f4963b 100644 (file)
@@ -36,7 +36,8 @@ IO ports used
 
 03c0 - 03df : standard vga ports
 01ce        : bochs vbe interface index port
-01cf        : bochs vbe interface data port
+01cf        : bochs vbe interface data port (x86 only)
+01d0        : bochs vbe interface data port
 
 
 Memory regions used
index 81aa76bef9b1694bd15bf19a05537d7a49808ff1..2b0200a164c3438fad73b4ca6f96b445501a5a33 100644 (file)
--- a/hw/vga.c
+++ b/hw/vga.c
@@ -2321,9 +2321,8 @@ static const MemoryRegionPortio vbe_portio_list[] = {
     { 0, 1, 2, .read = vbe_ioport_read_index, .write = vbe_ioport_write_index },
 # ifdef TARGET_I386
     { 1, 1, 2, .read = vbe_ioport_read_data, .write = vbe_ioport_write_data },
-# else
-    { 2, 1, 2, .read = vbe_ioport_read_data, .write = vbe_ioport_write_data },
 # endif
+    { 2, 1, 2, .read = vbe_ioport_read_data, .write = vbe_ioport_write_data },
     PORTIO_END_OF_LIST(),
 };