From patchwork Sat Feb 7 00:17:04 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Cory Fields X-Patchwork-Id: 5955 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n16NJVaQ022182 for ; Fri, 6 Feb 2009 23:19:31 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752995AbZBFXTY (ORCPT ); Fri, 6 Feb 2009 18:19:24 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752427AbZBFXTY (ORCPT ); Fri, 6 Feb 2009 18:19:24 -0500 Received: from mout.perfora.net ([74.208.4.194]:57784 "EHLO mout.perfora.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752853AbZBFXTX (ORCPT ); Fri, 6 Feb 2009 18:19:23 -0500 Received: from localhost.localdomain (c-24-30-35-55.hsd1.ga.comcast.net [24.30.35.55]) by mrelay.perfora.net (node=mrus1) with ESMTP (Nemesis) id 0MKpCa-1LVZyi2WsB-0007TW; Fri, 06 Feb 2009 18:19:21 -0500 From: Cory Fields To: kvm@vger.kernel.org Subject: [PATCH 3/4] probe for quietboot in vgabios Date: Fri, 6 Feb 2009 19:17:04 -0500 Message-Id: <1233965825-17970-4-git-send-email-FOSS@AtlasTechnologiesInc.com> X-Mailer: git-send-email 1.6.0.6 In-Reply-To: <1233965825-17970-1-git-send-email-FOSS@AtlasTechnologiesInc.com> References: <1233965825-17970-1-git-send-email-FOSS@AtlasTechnologiesInc.com> X-Provags-ID: V01U2FsdGVkX18DnmdJO8wdosHCpWbGhfOzCsja2mFVz39Dnol yd2/TV5k3BdSR+sjy+1jy21OQIZ+xlHA6XNUW/ZCta8wgYTVxx c2BSNJZphR/35gIgwVUH50AH3iiEabs2VPUT7OLFRE= Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org If quietboot is set disable all normal text output Errors should still be shown Signed-off-by: Cory Fields --- vgabios/vgabios.c | 17 ++++++++++++++++- 1 files changed, 16 insertions(+), 1 deletions(-) diff --git a/vgabios/vgabios.c b/vgabios/vgabios.c index e6fe2a0..923ea66 100644 --- a/vgabios/vgabios.c +++ b/vgabios/vgabios.c @@ -55,6 +55,10 @@ #endif #define USE_BX_INFO +#define BX_CFG_CTL_PORT 0x510 +#define BX_CFG_DATA_PORT 0x511 +#define BX_CFG_SIGNATURE 0x00 +#define BX_CFG_QUIETBOOT 0x08 /* Declares */ static Bit8u read_byte(); @@ -250,6 +254,10 @@ vgabios_init_func: call cirrus_init #endif + call _qemu_quietboot_probe + test al,al + jnz skip_display + ;; display splash screen call _display_splash_screen @@ -269,7 +277,7 @@ vgabios_init_func: ;; show cirrus info call cirrus_display_info #endif - +skip_display: retf ASM_END @@ -3839,6 +3847,13 @@ void printf(s) #endif // -------------------------------------------------------------------------------------------- +static int qemu_quietboot_probe() +{ + outw(BX_CFG_CTL_PORT, BX_CFG_QUIETBOOT); + + if (inb(BX_CFG_DATA_PORT)) return 1; + return 0; +} ASM_START ;; DATA_SEG_DEFS_HERE