From nobody@FreeBSD.org  Mon Aug 30 01:12:40 2004
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 2CB7616A4CE
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 30 Aug 2004 01:12:40 +0000 (GMT)
Received: from www.freebsd.org (www.freebsd.org [216.136.204.117])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 088D643D49
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 30 Aug 2004 01:12:40 +0000 (GMT)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.12.11/8.12.11) with ESMTP id i7U1CdZN034569
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 30 Aug 2004 01:12:39 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.12.11/8.12.11/Submit) id i7U1CdP8034568;
	Mon, 30 Aug 2004 01:12:39 GMT
	(envelope-from nobody)
Message-Id: <200408300112.i7U1CdP8034568@www.freebsd.org>
Date: Mon, 30 Aug 2004 01:12:39 GMT
From: Clement Moulin <freebsd@simplerezo.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: Kernel compilation failed with VGA_NO_MODE_CHANGE
X-Send-Pr-Version: www-2.3

>Number:         71130
>Category:       kern
>Synopsis:       [patch] Kernel compilation failed with VGA_NO_MODE_CHANGE [5.2.1]
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    ru
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Aug 30 01:20:18 GMT 2004
>Closed-Date:    Wed Dec 15 13:57:08 GMT 2004
>Last-Modified:  Wed Dec 15 13:57:08 GMT 2004
>Originator:     Clement Moulin
>Release:        5.2.1-p9-RELEASE
>Organization:
SimpleRezo
>Environment:
FreeBSD ---.simplerezo.net 5.2.1-RELEASE FreeBSD 5.2.1-RELEASE #0: Mon Feb 23 20:45:55 GMT 2004     root@wv1u.btc.adaptec.com:/usr/obj/usr/src/sys/GENERIC  i386
>Description:
"make buildkernel" failed like that:

cc -c -O -pipe -march=pentium4 -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes  -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual  -fformat-extensions -std=c99  -nostdinc -I-  -I. -I/usr/src/sys -I/usr/src/sys/contrib/dev/acpica -I/usr/src/sys/contrib/ipfilter -I/usr/src/sys/contrib/dev/ath -I/usr/src/sys/contrib/dev/ath/freebsd -I/usr/src/sys/contrib/ngatm -D_KERNEL -include opt_global.h -fno-common -finline-limit=15000 -fno-strict-aliasing -fno-builtin -mno-align-long-strings -mpreferred-stack-boundary=2 -ffreestanding -Werror  /usr/src/sys/dev/fb/vga.c
/usr/src/sys/dev/fb/vga.c:1346: warning: `filll_io' defined but not used
/usr/src/sys/dev/fb/vga.c:1336: warning: `fill' defined but not used
*** Error code 1

Stop in /usr/obj/usr/src/sys/KERNEL.
*** Error code 1

Stop in /usr/src.
*** Error code 1

Stop in /usr/src.

>How-To-Repeat:
Enable "option VGA_NO_MODE_CHANGE" in kernel configuration.
>Fix:
Apply this patch to sys/dev/fb/vga.c

--- vga.c.orig  Mon Aug 30 03:11:37 2004
+++ vga.c       Mon Aug 30 03:03:07 2004
@@ -471,7 +471,6 @@
 static int probe_adapters(void);
 static int set_line_length(video_adapter_t *adp, int pixel);
 static int set_display_start(video_adapter_t *adp, int x, int y);
-static void filll_io(int val, vm_offset_t d, size_t size);

 #ifndef VGA_NO_MODE_CHANGE
 #ifdef VGA_WIDTH90
@@ -500,6 +499,7 @@
                               int cx, int cy);
 static void direct_fill_rect32(video_adapter_t *adp, int val, int x, int y,
                               int cx, int cy);
+static void filll_io(int val, vm_offset_t d, size_t size);
 #endif /* notyet */
 #endif /* !VGA_NO_MODE_CHANGE */

@@ -1330,6 +1330,7 @@
     return 0;
 }

+#ifndef VGA_NO_MODE_CHANGE
 #if defined(__i386__) || defined(__amd64__)    /* XXX */
 static void
 fill(int val, void *d, size_t size)
@@ -1349,6 +1350,7 @@
        d += sizeof(u_int32_t);
     }
 }
+#endif /* VGA_NO_MODE_CHANGE */

 /* entry points */

>Release-Note:
>Audit-Trail:

From: <freebsd@simplerezo.com>
To: <freebsd-gnats-submit@FreeBSD.org>
Cc:  
Subject: Re: kern/71130: [patch] Kernel compilation failed with VGA_NO_MODE_CHANGE [5.2.1]
Date: Mon, 22 Nov 2004 16:29:13 +0100

 Still present in 5.3-RELEASE !
 
 
State-Changed-From-To: open->closed 
State-Changed-By: ru 
State-Changed-When: Wed Dec 15 13:55:51 GMT 2004 
State-Changed-Why:  
An equivalent patch committed to both HEAD and RELENG_5. 


Responsible-Changed-From-To: freebsd-bugs->ru 
Responsible-Changed-By: ru 
Responsible-Changed-When: Wed Dec 15 13:55:51 GMT 2004 
Responsible-Changed-Why:  

http://www.freebsd.org/cgi/query-pr.cgi?pr=71130 
>Unformatted:
