Module Name:    src
Committed By:   dsl
Date:           Mon Aug  3 20:15:14 UTC 2009

Modified Files:
        src/sys/arch/x86/x86: x86_autoconf.c

Log Message:
Only define x86_genfb_set_mapreg() and found_console when NPCI > 0
Fixes PR/41451


To generate a diff of this commit:
cvs rdiff -u -r1.40 -r1.41 src/sys/arch/x86/x86/x86_autoconf.c

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/x86/x86/x86_autoconf.c
diff -u src/sys/arch/x86/x86/x86_autoconf.c:1.40 src/sys/arch/x86/x86/x86_autoconf.c:1.41
--- src/sys/arch/x86/x86/x86_autoconf.c:1.40	Mon May  4 12:48:26 2009
+++ src/sys/arch/x86/x86/x86_autoconf.c	Mon Aug  3 20:15:14 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: x86_autoconf.c,v 1.40 2009/05/04 12:48:26 cegger Exp $	*/
+/*	$NetBSD: x86_autoconf.c,v 1.41 2009/08/03 20:15:14 dsl Exp $	*/
 
 /*-
  * Copyright (c) 1990 The Regents of the University of California.
@@ -35,7 +35,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: x86_autoconf.c,v 1.40 2009/05/04 12:48:26 cegger Exp $");
+__KERNEL_RCSID(0, "$NetBSD: x86_autoconf.c,v 1.41 2009/08/03 20:15:14 dsl Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -69,6 +69,7 @@
 struct disklist *x86_alldisks;
 int x86_ndisks;
 
+#if NPCI > 0
 static void
 x86_genfb_set_mapreg(void *opaque, int index, int r, int g, int b)
 {
@@ -77,6 +78,7 @@
 	outb(0x3c0 + VGA_DAC_PALETTE, (uint8_t)g >> 2);
 	outb(0x3c0 + VGA_DAC_PALETTE, (uint8_t)b >> 2);
 }
+#endif
 
 static void
 handle_wedges(device_t dv, int par)
@@ -502,7 +504,9 @@
 void
 device_register(device_t dev, void *aux)
 {
+#if NPCI > 0
 	static bool found_console = false;
+#endif
 
 	/*
 	 * Handle network interfaces here, the attachment information is

Reply via email to