Skip to content

Commit

Permalink
drm/bochs: disable video before changing video mode
Browse files Browse the repository at this point in the history
qemu and simics simulators both seem to expect that video should be disabled
before changing the video mode.

references:
http://git.qemu.org/?p=qemu.git;a=blob;f=hw/display/vga.c;h=c0f7b343bbab586c8593d29c7a765f1e6ca3662c;hb=HEAD#l727
http://wiki.osdev.org/Bochs_VBE_Extensions#Setting_display_resolution_and_bit_depth

Signed-off-by: Chris Ruffin <chris.ruffin@intel.com>
Reviewed-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
  • Loading branch information
Chris Ruffin authored and Dave Airlie committed Mar 31, 2015
1 parent 53d8858 commit 564b687
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/gpu/drm/bochs/bochs_hw.c
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,7 @@ void bochs_hw_setmode(struct bochs_device *bochs,

bochs_vga_writeb(bochs, 0x3c0, 0x20); /* unblank */

bochs_dispi_write(bochs, VBE_DISPI_INDEX_ENABLE, 0);
bochs_dispi_write(bochs, VBE_DISPI_INDEX_BPP, bochs->bpp);
bochs_dispi_write(bochs, VBE_DISPI_INDEX_XRES, bochs->xres);
bochs_dispi_write(bochs, VBE_DISPI_INDEX_YRES, bochs->yres);
Expand Down

0 comments on commit 564b687

Please sign in to comment.