From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933028AbbCRQhv (ORCPT ); Wed, 18 Mar 2015 12:37:51 -0400 Received: from mga02.intel.com ([134.134.136.20]:36611 "EHLO mga02.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932849AbbCRQho (ORCPT ); Wed, 18 Mar 2015 12:37:44 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.11,423,1422950400"; d="scan'208";a="700534072" Date: Wed, 18 Mar 2015 12:37:43 -0400 From: Chris Ruffin To: linux-kernel@vger.kernel.org Cc: Gerd Hoffmann , Dave Airlie , cmruffin@gmail.com Subject: [PATCH] bochs-drm: disable video before changing video mode Message-ID: <20150318123743.000053f4@intel.com> X-Mailer: Claws Mail 3.10.1 (GTK+ 2.16.6; i586-pc-mingw32msvc) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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 --- drivers/gpu/drm/bochs/bochs_hw.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/bochs/bochs_hw.c b/drivers/gpu/drm/bochs/bochs_hw.c index 4603897..a39b034 100644 --- a/drivers/gpu/drm/bochs/bochs_hw.c +++ b/drivers/gpu/drm/bochs/bochs_hw.c @@ -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); -- 1.7.10.4