From: Cory Fields 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> References: <1233965825-17970-1-git-send-email-FOSS@AtlasTechnologiesInc.com> To: kvm@vger.kernel.org Return-path: 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 In-Reply-To: <1233965825-17970-1-git-send-email-FOSS@AtlasTechnologiesInc.com> Sender: kvm-owner@vger.kernel.org List-ID: 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 -- 1.6.0.6