Module Name:    src
Committed By:   jmcneill
Date:           Mon Aug 24 10:16:12 UTC 2009

Modified Files:
        src/sys/arch/amd64/acpi: acpi_wakecode.S
        src/sys/arch/i386/acpi: acpi_wakecode.S

Log Message:
Ensure that the VBE mode is only restored when machdep.acpi_vbios_reset=1


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/amd64/acpi/acpi_wakecode.S
cvs rdiff -u -r1.13 -r1.14 src/sys/arch/i386/acpi/acpi_wakecode.S

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/amd64/acpi/acpi_wakecode.S
diff -u src/sys/arch/amd64/acpi/acpi_wakecode.S:1.8 src/sys/arch/amd64/acpi/acpi_wakecode.S:1.9
--- src/sys/arch/amd64/acpi/acpi_wakecode.S:1.8	Mon Aug 24 02:15:46 2009
+++ src/sys/arch/amd64/acpi/acpi_wakecode.S	Mon Aug 24 10:16:12 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: acpi_wakecode.S,v 1.8 2009/08/24 02:15:46 jmcneill Exp $	*/
+/*	$NetBSD: acpi_wakecode.S,v 1.9 2009/08/24 10:16:12 jmcneill Exp $	*/
 
 /*-
  * Copyright (c) 2007 Joerg Sonnenberger <jo...@netbsd.org>
@@ -115,15 +115,6 @@
 	movw	%cs,%ax
 	movw	%ax,%ds
 	movw	%ax,%ss
-1:
-
-	/* Disable beep again if machdep.acpi_beep_on_reset=1 */
-	cmpb	$1,WAKEUP_beep_on_reset
-	jne	1f
-	inb	$0x61,%al
-	andb	$0xfc,%al
-	outb	%al,$0x61
-1:
 
 	/* If we need to restore a VESA VBE mode, do it now */
 	cmpb	$0,WAKEUP_vesa_modenum
@@ -133,12 +124,19 @@
 	movw	$0x4f02,%ax
 	int	$0x10
 
-	/* paranoia */
 	movw	%cs,%ax
 	movw	%ax,%ds
 	movw	%ax,%ss
 1:
 
+	/* Disable beep again if machdep.acpi_beep_on_reset=1 */
+	cmpb	$1,WAKEUP_beep_on_reset
+	jne	1f
+	inb	$0x61,%al
+	andb	$0xfc,%al
+	outb	%al,$0x61
+1:
+
 	/* Load temporary 32bit GDT */
 	data32 addr32 lgdt	tmp_gdt
 

Index: src/sys/arch/i386/acpi/acpi_wakecode.S
diff -u src/sys/arch/i386/acpi/acpi_wakecode.S:1.13 src/sys/arch/i386/acpi/acpi_wakecode.S:1.14
--- src/sys/arch/i386/acpi/acpi_wakecode.S:1.13	Mon Aug 24 02:15:46 2009
+++ src/sys/arch/i386/acpi/acpi_wakecode.S	Mon Aug 24 10:16:12 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: acpi_wakecode.S,v 1.13 2009/08/24 02:15:46 jmcneill Exp $	*/
+/*	$NetBSD: acpi_wakecode.S,v 1.14 2009/08/24 10:16:12 jmcneill Exp $	*/
 
 /*-
  * Copyright (c) 2002 The NetBSD Foundation, Inc.
@@ -111,15 +111,6 @@
 	movw	%cs,%ax
 	movw	%ax,%ds
 	movw	%ax,%ss
-1:
-
-	/* Disable beep again if machdep.acpi_beep_on_reset=1 */
-	cmpb	$1,WAKEUP_beep_on_reset
-	jne	1f
-	inb	$0x61,%al
-	andb	$0xfc,%al
-	outb	%al,$0x61
-1:
 
 	/* If we need to restore a VESA VBE mode, do it now */
 	cmpb	$0,WAKEUP_vesa_modenum
@@ -129,12 +120,19 @@
 	movw	$0x4f02,%ax
 	int	$0x10
 
-	/* paranoia */
 	movw	%cs,%ax
 	movw	%ax,%ds
 	movw	%ax,%ss
 1:
 
+	/* Disable beep again if machdep.acpi_beep_on_reset=1 */
+	cmpb	$1,WAKEUP_beep_on_reset
+	jne	1f
+	inb	$0x61,%al
+	andb	$0xfc,%al
+	outb	%al,$0x61
+1:
+
 	/* Load GDT while non-paging */
 	lgdt	tmp_gdt
 

Reply via email to