From gnb@itga.com.au  Mon Feb  1 22:59:56 1999
Received: from fw.bby.com.au (ns.bby.com.au [192.83.119.129])
          by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id WAA22640
          for <FreeBSD-gnats-submit@freebsd.org>; Mon, 1 Feb 1999 22:59:52 -0800 (PST)
          (envelope-from gnb@itga.com.au)
Received: (from daemon@localhost) by fw.bby.com.au (8.8.8/8.6.9) id RAA15955 for <FreeBSD-gnats-submit@freebsd.org>; Tue, 2 Feb 1999 17:59:43 +1100 (EST)
Received: from lightning.itga.com.au(192.168.71.20)
 via SMTP by fw.bby.com.au, id smtpd015953; Tue Feb  2 06:59:35 1999
Received: from hellcat.itga.com.au (hellcat.itga.com.au [192.168.71.163])
	by lightning.itga.com.au (8.9.1a/8.9.1) with ESMTP id RAA08375;
	Tue, 2 Feb 1999 17:59:34 +1100 (EST)
Received: (from gnb@localhost)
	by hellcat.itga.com.au (8.9.2/8.9.1) id RAA08829;
	Tue, 2 Feb 1999 17:59:34 +1100 (EST)
	(envelope-from gnb@itga.com.au)
Message-Id: <199902020659.RAA08829@hellcat.itga.com.au>
Date: Tue, 2 Feb 1999 17:59:34 +1100 (EST)
From: Gregory Bond <gnb@itga.com.au>
To: FreeBSD-gnats-submit@freebsd.org
Subject: [PATCH] minor kernel warning removal
X-Send-Pr-Version: 3.2

>Number:         9877
>Category:       kern
>Synopsis:       Patch to remove some kernel compile warnings
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Feb  1 23:00:02 PST 1999
>Closed-Date:    Mon Sep 20 01:39:04 PDT 1999
>Last-Modified:  Mon Sep 20 01:39:48 PDT 1999
>Originator:     Gregory Bond
>Release:        FreeBSD 3.0-STABLE i386
>Organization:
ITG Australia Ltd
>Environment:

FreeBSD hellcat.itga.com.au 3.0-STABLE FreeBSD 3.0-STABLE #7: Tue Feb  2 09:08:02 EST 1999     toor@hellcat.itga.com.au:/usr/src/sys/compile/Hellcat  i386

>Description:

	2 minor nits in the kernel that elicit warnings from the compiler:
	- if MFS is used without MFS_ROOT
	- if I586_CPU is not defined
	both are harmless, mainly declarations of stuff not protected by
	the relevent #ifdef

>How-To-Repeat:

	configure & build a kernel with "cpu I686_CPU" only
	configure & build a kernel with "options MFS" but not "options MFS_ROOT"

>Fix:
	
--- /sys/i386/isa/npx.c	Mon Jan 11 08:55:03 1999
+++ i386/isa/npx.c	Tue Feb  2 17:47:30 1999
@@ -122,8 +122,10 @@
 static	int	npxattach	__P((struct isa_device *dvp));
 static	int	npxprobe	__P((struct isa_device *dvp));
 static	int	npxprobe1	__P((struct isa_device *dvp));
+#ifdef I586_CPU
 static	long	timezero	__P((const char *funcname,
 				     void (*func)(void *buf, size_t len)));
+#endif
 
 struct	isa_driver npxdriver = {
 	npxprobe, npxattach, "npx",
--- /sys/ufs/mfs/mfs_vfsops.c	Mon Jan  4 10:17:43 1999
+++ ufs/mfs/mfs_vfsops.c	Tue Feb  2 17:45:16 1999
@@ -64,8 +64,10 @@
 
 u_char *	mfs_getimage __P((void));
 
+#ifdef MFS_ROOT
 static caddr_t	mfs_rootbase;	/* address of mini-root in kernel virtual memory */
 static u_long	mfs_rootsize;	/* size of mini-root in bytes */
+#endif
 
 static	int mfs_minor;	/* used for building internal dev_t */
 
@@ -178,7 +180,9 @@
 	struct mfs_args args;
 	struct ufsmount *ump;
 	struct fs *fs;
+#ifdef MFS_ROOT
 	u_char *base;
+#endif
 	struct mfsnode *mfsp;
 	u_int size;
 	int flags, err;
@@ -344,7 +348,9 @@
 		goto error_2;
 	}
 
+#if MFS_ROOT
 dostatfs:
+#endif
 	/*
 	 * Initialize FS stat information in mount struct; uses both
 	 * mp->mnt_stat.f_mntonname and mp->mnt_stat.f_mntfromname
>Release-Note:
>Audit-Trail:

From: Gregory Bond <gnb@itga.com.au>
To: freebsd-gnats-submit@freebsd.org
Cc:  
Subject: Re: kern/9877: Patch to remove some kernel compile warnings
Date: Mon, 20 Sep 1999 13:17:24 +1000

 Submitter reports: Subsumed by kern/13846; can be closed.
 
State-Changed-From-To: open->closed 
State-Changed-By: ru 
State-Changed-When: Mon Sep 20 01:39:04 PDT 1999 
State-Changed-Why:  
Superseded by PR kern/13846. 
>Unformatted:
