summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbde <bde@FreeBSD.org>1995-03-16 18:17:34 +0000
committerbde <bde@FreeBSD.org>1995-03-16 18:17:34 +0000
commit289f11acb49b6dbb3081e09bf94a86f008f55814 (patch)
treee4952f18ac85eccbbd3d9b0f010098732d07fe6d
parent4c4945abee9eabe3a2be340ba973ae861c21a3c6 (diff)
downloadFreeBSD-src-289f11acb49b6dbb3081e09bf94a86f008f55814.zip
FreeBSD-src-289f11acb49b6dbb3081e09bf94a86f008f55814.tar.gz
Add and move declarations to fix all of the warnings from `gcc -Wimplicit'
(except in netccitt, netiso and netns) and most of the warnings from `gcc -Wnested-externs'. Fix all the bugs found. There were no serious ones.
-rw-r--r--sys/amd64/amd64/autoconf.c9
-rw-r--r--sys/amd64/amd64/db_interface.c4
-rw-r--r--sys/amd64/amd64/db_trace.c5
-rw-r--r--sys/amd64/amd64/machdep.c40
-rw-r--r--sys/amd64/amd64/pmap.c6
-rw-r--r--sys/amd64/amd64/trap.c7
-rw-r--r--sys/amd64/amd64/tsc.c13
-rw-r--r--sys/amd64/amd64/vm_machdep.c5
-rw-r--r--sys/amd64/include/clock.h7
-rw-r--r--sys/amd64/include/frame.h8
-rw-r--r--sys/amd64/include/md_var.h68
-rw-r--r--sys/amd64/include/pmap.h11
-rw-r--r--sys/amd64/isa/clock.c13
-rw-r--r--sys/ddb/db_command.c13
-rw-r--r--sys/ddb/db_sym.h3
-rw-r--r--sys/ddb/ddb.h5
-rw-r--r--sys/dev/ed/if_ed.c4
-rw-r--r--sys/dev/fdc/fdc.c17
-rw-r--r--sys/dev/sio/sio.c7
-rw-r--r--sys/dev/speaker/spkr.c4
-rw-r--r--sys/fs/cd9660/cd9660_node.c7
-rw-r--r--sys/fs/cd9660/cd9660_node.h5
-rw-r--r--sys/fs/fdescfs/fdesc_vfsops.c3
-rw-r--r--sys/fs/fifofs/fifo.h4
-rw-r--r--sys/fs/fifofs/fifo_vnops.c3
-rw-r--r--sys/fs/msdosfs/denode.h4
-rw-r--r--sys/fs/msdosfs/msdosfs_denode.c5
-rw-r--r--sys/fs/nullfs/null_vfsops.c3
-rw-r--r--sys/fs/portalfs/portal_vfsops.c3
-rw-r--r--sys/fs/procfs/procfs.h4
-rw-r--r--sys/fs/procfs/procfs_ctl.c9
-rw-r--r--sys/fs/procfs/procfs_vfsops.c3
-rw-r--r--sys/fs/umapfs/umap_vfsops.c3
-rw-r--r--sys/fs/unionfs/union.h5
-rw-r--r--sys/fs/unionfs/union_vfsops.c6
-rw-r--r--sys/gnu/i386/fpemul/errors.c3
-rw-r--r--sys/gnu/i386/fpemul/fpu_proto.h4
-rw-r--r--sys/i386/i386/autoconf.c9
-rw-r--r--sys/i386/i386/db_interface.c4
-rw-r--r--sys/i386/i386/db_trace.c5
-rw-r--r--sys/i386/i386/machdep.c40
-rw-r--r--sys/i386/i386/pmap.c6
-rw-r--r--sys/i386/i386/procfs_machdep.c6
-rw-r--r--sys/i386/i386/swapgeneric.c4
-rw-r--r--sys/i386/i386/trap.c7
-rw-r--r--sys/i386/i386/tsc.c13
-rw-r--r--sys/i386/i386/userconfig.c4
-rw-r--r--sys/i386/i386/vm_machdep.c5
-rw-r--r--sys/i386/include/clock.h7
-rw-r--r--sys/i386/include/frame.h8
-rw-r--r--sys/i386/include/md_var.h68
-rw-r--r--sys/i386/include/pmap.h11
-rw-r--r--sys/i386/isa/bt742a.c6
-rw-r--r--sys/i386/isa/clock.c13
-rw-r--r--sys/i386/isa/fd.c17
-rw-r--r--sys/i386/isa/if_ed.c4
-rw-r--r--sys/i386/isa/lpt.c3
-rw-r--r--sys/i386/isa/sio.c7
-rw-r--r--sys/i386/isa/spkr.c4
-rw-r--r--sys/i386/isa/ultra14f.c6
-rw-r--r--sys/i386/isa/wd.c6
-rw-r--r--sys/isa/atrtc.c13
-rw-r--r--sys/isa/fd.c17
-rw-r--r--sys/isa/sio.c7
-rw-r--r--sys/isofs/cd9660/cd9660_node.c7
-rw-r--r--sys/isofs/cd9660/cd9660_node.h5
-rw-r--r--sys/kern/imgact_aout.c3
-rw-r--r--sys/kern/imgact_gzip.c4
-rw-r--r--sys/kern/init_main.c12
-rw-r--r--sys/kern/init_sysent.c3
-rw-r--r--sys/kern/kern_clock.c4
-rw-r--r--sys/kern/kern_exec.c3
-rw-r--r--sys/kern/kern_exit.c12
-rw-r--r--sys/kern/kern_fork.c5
-rw-r--r--sys/kern/kern_lkm.c3
-rw-r--r--sys/kern/kern_physio.c4
-rw-r--r--sys/kern/kern_sig.c3
-rw-r--r--sys/kern/kern_synch.c7
-rw-r--r--sys/kern/kern_sysctl.c6
-rw-r--r--sys/kern/kern_tc.c4
-rw-r--r--sys/kern/kern_time.c3
-rw-r--r--sys/kern/kern_timeout.c4
-rw-r--r--sys/kern/makesyscalls.sh3
-rw-r--r--sys/kern/subr_prf.c3
-rw-r--r--sys/kern/subr_prof.c5
-rw-r--r--sys/kern/subr_rlist.c6
-rw-r--r--sys/kern/subr_trap.c7
-rw-r--r--sys/kern/sys_process.c4
-rw-r--r--sys/kern/syscalls.c2
-rw-r--r--sys/kern/tty.c5
-rw-r--r--sys/kern/uipc_syscalls.c3
-rw-r--r--sys/kern/vfs_bio.c6
-rw-r--r--sys/kern/vfs_cluster.c7
-rw-r--r--sys/kern/vfs_export.c4
-rw-r--r--sys/kern/vfs_extattr.c13
-rw-r--r--sys/kern/vfs_subr.c4
-rw-r--r--sys/kern/vfs_syscalls.c13
-rw-r--r--sys/libkern/libkern.h4
-rw-r--r--sys/miscfs/fdesc/fdesc_vfsops.c3
-rw-r--r--sys/miscfs/fifofs/fifo.h4
-rw-r--r--sys/miscfs/fifofs/fifo_vnops.c3
-rw-r--r--sys/miscfs/kernfs/kernfs_vfsops.c3
-rw-r--r--sys/miscfs/nullfs/null_vfsops.c3
-rw-r--r--sys/miscfs/portal/portal_vfsops.c3
-rw-r--r--sys/miscfs/procfs/procfs.h4
-rw-r--r--sys/miscfs/procfs/procfs_ctl.c9
-rw-r--r--sys/miscfs/procfs/procfs_vfsops.c3
-rw-r--r--sys/miscfs/umapfs/umap_vfsops.c3
-rw-r--r--sys/miscfs/union/union.h5
-rw-r--r--sys/miscfs/union/union_vfsops.c6
-rw-r--r--sys/msdosfs/denode.h4
-rw-r--r--sys/msdosfs/msdosfs_denode.c5
-rw-r--r--sys/net/if.h3
-rw-r--r--sys/net/if_ethersubr.c3
-rw-r--r--sys/net/if_fddisubr.c3
-rw-r--r--sys/net/if_sl.c4
-rw-r--r--sys/net/if_tun.c1
-rw-r--r--sys/net/radix.h5
-rw-r--r--sys/net/route.c4
-rw-r--r--sys/net/rtsock.c3
-rw-r--r--sys/netccitt/pk_var.h3
-rw-r--r--sys/netinet/if_ether.c3
-rw-r--r--sys/netinet/igmp.c4
-rw-r--r--sys/netinet/in.c3
-rw-r--r--sys/netinet/in_pcb.c3
-rw-r--r--sys/netinet/in_pcb.h4
-rw-r--r--sys/netinet/in_var.h7
-rw-r--r--sys/netinet/ip_icmp.c8
-rw-r--r--sys/netinet/ip_input.c9
-rw-r--r--sys/netinet/ip_mroute.c2
-rw-r--r--sys/netinet/ip_mroute.h3
-rw-r--r--sys/netinet/ip_output.c4
-rw-r--r--sys/netinet/ip_var.h4
-rw-r--r--sys/netinet/tcp_input.c5
-rw-r--r--sys/netinet/tcp_reass.c5
-rw-r--r--sys/netinet/tcp_subr.c5
-rw-r--r--sys/netinet/tcp_timewait.c5
-rw-r--r--sys/netinet/tcp_usrreq.c10
-rw-r--r--sys/netinet/tcp_var.h6
-rw-r--r--sys/netinet/udp_usrreq.c7
-rw-r--r--sys/netiso/clnp_input.c5
-rw-r--r--sys/netiso/iso_var.h5
-rw-r--r--sys/netns/ns_if.h3
-rw-r--r--sys/netns/ns_input.c3
-rw-r--r--sys/nfs/nfs_common.c4
-rw-r--r--sys/nfs/nfs_node.c5
-rw-r--r--sys/nfs/nfs_socket.c4
-rw-r--r--sys/nfs/nfs_subs.c4
-rw-r--r--sys/nfs/nfs_vfsops.c5
-rw-r--r--sys/nfs/nfs_vnops.c5
-rw-r--r--sys/nfs/nfsnode.h6
-rw-r--r--sys/nfsclient/nfs_node.c5
-rw-r--r--sys/nfsclient/nfs_socket.c4
-rw-r--r--sys/nfsclient/nfs_subs.c4
-rw-r--r--sys/nfsclient/nfs_vfsops.c5
-rw-r--r--sys/nfsclient/nfs_vnops.c5
-rw-r--r--sys/nfsclient/nfsnode.h6
-rw-r--r--sys/nfsserver/nfs_srvsock.c4
-rw-r--r--sys/nfsserver/nfs_srvsubs.c4
-rw-r--r--sys/scsi/scsi_driver.c4
-rw-r--r--sys/scsi/scsiconf.c11
-rw-r--r--sys/scsi/scsiconf.h6
-rw-r--r--sys/scsi/sd.c17
-rw-r--r--sys/sys/bio.h13
-rw-r--r--sys/sys/buf.h13
-rw-r--r--sys/sys/conf.h3
-rw-r--r--sys/sys/disklabel.h4
-rw-r--r--sys/sys/diskmbr.h4
-rw-r--r--sys/sys/diskpc98.h4
-rw-r--r--sys/sys/exec.h11
-rw-r--r--sys/sys/file.h3
-rw-r--r--sys/sys/filedesc.h3
-rw-r--r--sys/sys/gmon.h6
-rw-r--r--sys/sys/kernel.h7
-rw-r--r--sys/sys/ktrace.h4
-rw-r--r--sys/sys/libkern.h4
-rw-r--r--sys/sys/linedisc.h3
-rw-r--r--sys/sys/mount.h8
-rw-r--r--sys/sys/msgbuf.h3
-rw-r--r--sys/sys/proc.h4
-rw-r--r--sys/sys/ptrace.h5
-rw-r--r--sys/sys/signalvar.h3
-rw-r--r--sys/sys/syscall-hide.h2
-rw-r--r--sys/sys/syscall.h2
-rw-r--r--sys/sys/sysctl.h10
-rw-r--r--sys/sys/sysent.h3
-rw-r--r--sys/sys/systm.h40
-rw-r--r--sys/sys/tty.h5
-rw-r--r--sys/sys/vnode.h3
-rw-r--r--sys/ufs/ffs/ffs_vfsops.c5
-rw-r--r--sys/ufs/lfs/lfs_vfsops.c3
-rw-r--r--sys/ufs/mfs/mfs_vfsops.c3
-rw-r--r--sys/ufs/ufs/ufs_vnops.c7
-rw-r--r--sys/vm/vm_extern.h8
-rw-r--r--sys/vm/vm_init.c5
-rw-r--r--sys/vm/vm_map.c4
-rw-r--r--sys/vm/vm_map.h5
-rw-r--r--sys/vm/vm_mmap.c4
-rw-r--r--sys/vm/vm_object.c3
-rw-r--r--sys/vm/vm_object.h8
-rw-r--r--sys/vm/vm_page.c8
-rw-r--r--sys/vm/vm_pageout.c4
-rw-r--r--sys/vm/vm_pageout.h4
-rw-r--r--sys/vm/vm_pager.h3
-rw-r--r--sys/vm/vm_swap.c4
-rw-r--r--sys/vm/vnode_pager.c3
206 files changed, 827 insertions, 536 deletions
diff --git a/sys/amd64/amd64/autoconf.c b/sys/amd64/amd64/autoconf.c
index 00d0fa9..8d3dba3 100644
--- a/sys/amd64/amd64/autoconf.c
+++ b/sys/amd64/amd64/autoconf.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* from: @(#)autoconf.c 7.1 (Berkeley) 5/9/91
- * $Id: autoconf.c,v 1.19 1995/02/01 23:11:38 se Exp $
+ * $Id: autoconf.c,v 1.20 1995/02/18 18:04:30 wpaul Exp $
*/
/*
@@ -54,6 +54,7 @@
#include <sys/reboot.h>
#include <sys/kernel.h>
+#include <machine/md_var.h>
#include <machine/pte.h>
static void swapconf(void);
@@ -65,7 +66,6 @@ static void setroot(void);
* the machine.
*/
int dkn; /* number of iostat dk numbers assigned so far */
-extern int cold; /* cold start flag initialized in locore.s */
extern int (*mountroot) __P((void));
#ifdef FFS
@@ -101,12 +101,8 @@ configure()
#endif
#ifdef NFS
- {
- extern int nfs_diskless_valid;
-
if (nfs_diskless_valid)
mountroot = nfs_mountroot;
- }
#endif /* NFS */
#ifdef FFS
if (!mountroot) {
@@ -143,7 +139,6 @@ swapconf()
{
register struct swdevt *swp;
register int nblks;
- extern int Maxmem;
for (swp = swdevt; swp->sw_dev > 0; swp++)
{
diff --git a/sys/amd64/amd64/db_interface.c b/sys/amd64/amd64/db_interface.c
index d47998a..4fe5033 100644
--- a/sys/amd64/amd64/db_interface.c
+++ b/sys/amd64/amd64/db_interface.c
@@ -23,7 +23,7 @@
* any improvements or extensions that they make and grant Carnegie the
* rights to redistribute these changes.
*
- * $Id: db_interface.c,v 1.10 1994/09/15 11:38:59 davidg Exp $
+ * $Id: db_interface.c,v 1.11 1995/01/14 10:24:48 bde Exp $
*/
/*
@@ -35,6 +35,7 @@
#include <sys/proc.h>
#include <sys/reboot.h>
+#include <machine/md_var.h>
#include <machine/segments.h>
#include <ddb/ddb.h>
@@ -192,7 +193,6 @@ db_write_bytes(addr, size, data)
vm_offset_t addr1;
register pt_entry_t *ptep1 = 0;
pt_entry_t oldmap1 = { 0 };
- extern char etext;
db_nofault = &db_jmpbuf;
diff --git a/sys/amd64/amd64/db_trace.c b/sys/amd64/amd64/db_trace.c
index 756114f..28c152f 100644
--- a/sys/amd64/amd64/db_trace.c
+++ b/sys/amd64/amd64/db_trace.c
@@ -23,13 +23,15 @@
* any improvements or extensions that they make and grant Carnegie the
* rights to redistribute these changes.
*
- * $Id: db_trace.c,v 1.8 1994/08/13 03:49:37 wollman Exp $
+ * $Id: db_trace.c,v 1.9 1995/03/01 21:37:44 davidg Exp $
*/
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/proc.h>
+#include <machine/md_var.h>
+
#include <vm/vm.h>
#include <vm/vm_param.h>
#include <vm/lock.h>
@@ -109,7 +111,6 @@ db_numargs(fp)
int *argp;
int inst;
int args;
- extern char etext[];
argp = (int *)db_get_value((int)&fp->f_retaddr, 4, FALSE);
if (argp < (int *)VM_MIN_KERNEL_ADDRESS || argp > (int *)etext)
diff --git a/sys/amd64/amd64/machdep.c b/sys/amd64/amd64/machdep.c
index 74bdfe8..0b0064c 100644
--- a/sys/amd64/amd64/machdep.c
+++ b/sys/amd64/amd64/machdep.c
@@ -35,7 +35,7 @@
* SUCH DAMAGE.
*
* from: @(#)machdep.c 7.4 (Berkeley) 6/3/91
- * $Id: machdep.c,v 1.112 1995/03/03 00:43:08 davidg Exp $
+ * $Id: machdep.c,v 1.113 1995/03/07 19:58:02 davidg Exp $
*/
#include "npx.h"
@@ -54,6 +54,7 @@
#include <sys/callout.h>
#include <sys/malloc.h>
#include <sys/mbuf.h>
+#include <sys/mount.h>
#include <sys/msgbuf.h>
#include <sys/ioctl.h>
#include <sys/sysent.h>
@@ -79,9 +80,31 @@
#include <sys/exec.h>
#include <sys/vnode.h>
+#include <ddb/ddb.h>
+
#include <net/netisr.h>
-extern vm_offset_t avail_start, avail_end;
+/* XXX correctly declaring all the netisr's is painful. */
+#include <net/if.h>
+#include <net/route.h>
+
+#include <netinet/in.h>
+#include <netinet/in_systm.h>
+#include <netinet/ip.h>
+#include <netinet/if_ether.h>
+#include <netinet/ip_var.h>
+
+#include <netns/ns.h>
+#include <netns/ns_if.h>
+
+#include <netiso/iso.h>
+#include <netiso/iso_var.h>
+
+#include <netccitt/dll.h>
+#include <netccitt/x25.h>
+#include <netccitt/pk.h>
+#include <sys/socketvar.h>
+#include <netccitt/pk_var.h>
#include "ether.h"
@@ -95,6 +118,7 @@ extern vm_offset_t avail_start, avail_end;
#include <machine/cons.h>
#include <machine/devconf.h>
#include <machine/bootinfo.h>
+#include <machine/md_var.h>
#include <i386/isa/isa.h>
#include <i386/isa/isa_device.h>
@@ -160,7 +184,6 @@ cpu_startup()
{
register unsigned i;
register caddr_t v;
- extern void (*netisrs[32])(void);
vm_offset_t maxaddr;
vm_size_t size = 0;
int firstaddr;
@@ -193,7 +216,7 @@ cpu_startup()
/*
* Quickly wire in netisrs.
*/
-#define DONET(isr, n) do { extern void isr(void); netisrs[n] = isr; } while(0)
+#define DONET(isr, n) do { netisrs[n] = isr; } while(0)
#ifdef INET
#if NETHER > 0
DONET(arpintr, NETISR_ARP);
@@ -377,8 +400,6 @@ struct cpu_nameclass i386_cpus[] = {
static void
identifycpu()
{
- extern u_long cpu_id, cpu_high, cpu_feature;
- extern char cpu_vendor[];
printf("CPU: ");
if (cpu >= 0
&& cpu < (sizeof i386_cpus/sizeof(struct cpu_nameclass))) {
@@ -482,8 +503,6 @@ identifycpu()
}
}
-extern char kstack[];
-
/*
* Send an interrupt to process.
*
@@ -726,7 +745,6 @@ boot(arghowto)
register long dummy; /* r12 is reserved */
register int howto; /* r11 == how to boot */
register int devtype; /* r10 == major of root dev */
- extern int cold;
if (cold) {
printf("hit reset please");
@@ -1161,18 +1179,14 @@ void
init386(first)
int first;
{
- extern char etext[];
int x;
unsigned biosbasemem, biosextmem;
struct gate_descriptor *gdp;
int gsel_tss;
- extern int sigcode,szsigcode;
/* table descriptors - used to load tables by microp */
struct region_descriptor r_gdt, r_idt;
int pagesinbase, pagesinext;
int target_page;
- extern struct pte *CMAP1;
- extern caddr_t CADDR1;
proc0.p_addr = proc0paddr;
diff --git a/sys/amd64/amd64/pmap.c b/sys/amd64/amd64/pmap.c
index 87e5f4f..52c1063f 100644
--- a/sys/amd64/amd64/pmap.c
+++ b/sys/amd64/amd64/pmap.c
@@ -39,7 +39,7 @@
* SUCH DAMAGE.
*
* from: @(#)pmap.c 7.7 (Berkeley) 5/12/91
- * $Id: pmap.c,v 1.51 1995/03/01 22:08:35 davidg Exp $
+ * $Id: pmap.c,v 1.52 1995/03/10 08:05:00 davidg Exp $
*/
/*
@@ -96,6 +96,7 @@
#include <vm/vm_page.h>
#include <machine/cputypes.h>
+#include <machine/md_var.h>
#include <i386/isa/isa.h>
@@ -159,6 +160,7 @@ extern int cpu_class;
* All those kernel PT submaps that BSD is so fond of
*/
pt_entry_t *CMAP1, *CMAP2, *ptmmap;
+pv_entry_t pv_table;
caddr_t CADDR1, CADDR2, ptvmmap;
pt_entry_t *msgbufmap;
struct msgbuf *msgbufp;
@@ -392,8 +394,6 @@ pmap_bootstrap(firstaddr, loadaddr)
* buffer (contiguous virtual *and* physical memory).
*/
{
- extern vm_offset_t isaphysmem;
-
isaphysmem = va;
virtual_avail = pmap_map(va, firstaddr,
diff --git a/sys/amd64/amd64/trap.c b/sys/amd64/amd64/trap.c
index f98022b..2e64edd 100644
--- a/sys/amd64/amd64/trap.c
+++ b/sys/amd64/amd64/trap.c
@@ -35,7 +35,7 @@
* SUCH DAMAGE.
*
* from: @(#)trap.c 7.4 (Berkeley) 5/13/91
- * $Id: trap.c,v 1.47 1995/02/10 06:43:47 davidg Exp $
+ * $Id: trap.c,v 1.48 1995/02/14 19:20:31 sos Exp $
*/
/*
@@ -56,10 +56,12 @@
#include <vm/vm_param.h>
#include <vm/pmap.h>
+#include <vm/vm_kern.h>
#include <vm/vm_map.h>
#include <vm/vm_page.h>
#include <machine/cpu.h>
+#include <machine/md_var.h>
#include <machine/psl.h>
#include <machine/reg.h>
#include <machine/trap.h>
@@ -302,8 +304,6 @@ trap(frame)
*/
#define MAYBE_DORETI_FAULT(where, whereto) \
do { \
- extern void where(void) __asm(__STRING(where)); \
- extern void whereto(void) __asm(__STRING(whereto)); \
if (frame.tf_eip == (int)where) { \
frame.tf_eip = (int)whereto; \
return; \
@@ -398,7 +398,6 @@ trap_pfault(frame, usermode)
vm_map_t map = 0;
int rv = 0;
vm_prot_t ftype;
- extern vm_map_t kernel_map;
int eva;
struct proc *p = curproc;
diff --git a/sys/amd64/amd64/tsc.c b/sys/amd64/amd64/tsc.c
index d3ca0f0..2676332 100644
--- a/sys/amd64/amd64/tsc.c
+++ b/sys/amd64/amd64/tsc.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* from: @(#)clock.c 7.2 (Berkeley) 5/12/91
- * $Id: clock.c,v 1.29 1994/12/30 12:43:34 bde Exp $
+ * $Id: clock.c,v 1.31 1995/01/19 22:05:27 ats Exp $
*/
/*
@@ -55,6 +55,7 @@
#include <machine/frame.h>
#include <i386/isa/icu.h>
#include <i386/isa/isa.h>
+#include <i386/isa/isa_device.h>
#include <i386/isa/rtc.h>
#include <i386/isa/timerreg.h>
@@ -558,8 +559,9 @@ cpu_initclocks()
profhz = RTC_PROFRATE;
/* Finish initializing 8253 timer 0. */
- register_intr(/* irq */ 0, /* XXX id */ 0, /* flags */ 0, clkintr,
- &clk_imask, /* unit */ 0);
+ register_intr(/* irq */ 0, /* XXX id */ 0, /* flags */ 0,
+ /* XXX */ (inthand2_t *)clkintr, &clk_imask,
+ /* unit */ 0);
INTREN(IRQ0);
/* Initialize RTC. */
@@ -568,8 +570,9 @@ cpu_initclocks()
diag = rtcin(RTC_DIAG);
if (diag != 0)
printf("RTC BIOS diagnostic error %b\n", diag, RTCDG_BITS);
- register_intr(/* irq */ 8, /* XXX id */ 1, /* flags */ 0, rtcintr,
- &stat_imask, /* unit */ 0);
+ register_intr(/* irq */ 8, /* XXX id */ 1, /* flags */ 0,
+ /* XXX */ (inthand2_t *)rtcintr, &stat_imask,
+ /* unit */ 0);
INTREN(IRQ8);
writertc(RTC_STATUSB, RTCSB_24HR | RTCSB_PINTR);
}
diff --git a/sys/amd64/amd64/vm_machdep.c b/sys/amd64/amd64/vm_machdep.c
index a444776..b4ae07c 100644
--- a/sys/amd64/amd64/vm_machdep.c
+++ b/sys/amd64/amd64/vm_machdep.c
@@ -38,7 +38,7 @@
*
* from: @(#)vm_machdep.c 7.3 (Berkeley) 5/13/91
* Utah $Hdr: vm_machdep.c 1.16.1.1 89/06/23$
- * $Id: vm_machdep.c,v 1.32 1995/02/20 22:23:31 davidg Exp $
+ * $Id: vm_machdep.c,v 1.33 1995/03/01 23:59:21 davidg Exp $
*/
#include "npx.h"
@@ -51,6 +51,7 @@
#include <sys/user.h>
#include <machine/cpu.h>
+#include <machine/md_var.h>
#include <vm/vm.h>
#include <vm/vm_kern.h>
@@ -546,8 +547,6 @@ cpu_fork(p1, p2)
{
register struct user *up = p2->p_addr;
int offset;
- extern char kstack[];
- extern int mvesp();
/*
* Copy pcb and stack from proc p1 to p2.
diff --git a/sys/amd64/include/clock.h b/sys/amd64/include/clock.h
index 33f8e74..3d87a07 100644
--- a/sys/amd64/include/clock.h
+++ b/sys/amd64/include/clock.h
@@ -49,13 +49,6 @@
#include <machine/frame.h>
/*
- * Kernel to clock driver interface.
- */
-void inittodr __P((time_t base));
-void resettodr __P((void));
-void startrtclock __P((void));
-
-/*
* i386 to clock driver interface.
* XXX almost all of it is misplaced. i586 stuff is done in isa/clock.c
* and isa stuff is done in i386/microtime.s and i386/support.s.
diff --git a/sys/amd64/include/frame.h b/sys/amd64/include/frame.h
index db2993e..9bee6ed 100644
--- a/sys/amd64/include/frame.h
+++ b/sys/amd64/include/frame.h
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* from: @(#)frame.h 5.2 (Berkeley) 1/18/91
- * $Id: frame.h,v 1.7 1994/01/03 07:55:32 davidg Exp $
+ * $Id: frame.h,v 1.9 1994/05/25 08:56:02 rgrimes Exp $
*/
#ifndef _MACHINE_FRAME_H_
@@ -72,8 +72,6 @@ struct trapframe {
int tf_ss;
};
-extern int kdb_trap(int, int, struct trapframe *);
-
/* Interrupt stack frame */
struct intrframe {
@@ -137,4 +135,8 @@ struct sigframe {
sig_t sf_handler;
struct sigcontext sf_sc;
};
+
+int kdb_trap __P((int, int, struct trapframe *));
+int math_emulate __P((struct trapframe * info));
+
#endif /* _MACHINE_FRAME_H_ */
diff --git a/sys/amd64/include/md_var.h b/sys/amd64/include/md_var.h
new file mode 100644
index 0000000..ad8ba37
--- /dev/null
+++ b/sys/amd64/include/md_var.h
@@ -0,0 +1,68 @@
+/*-
+ * Copyright (c) 1995 Bruce D. Evans.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. Neither the name of the author nor the names of contributors
+ * may be used to endorse or promote products derived from this software
+ * without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * $Id: $
+ */
+
+#ifndef _MACHINE_MD_VAR_H_
+#define _MACHINE_MD_VAR_H_
+
+/*
+ * Miscellaneous machine-dependent declarations.
+ */
+
+extern int Maxmem;
+extern u_long cpu_feature;
+extern u_long cpu_high;
+extern u_long cpu_id;
+extern char cpu_vendor[];
+extern char etext[];
+extern vm_offset_t isaphysmem;
+extern char kstack[];
+extern void (*netisrs[32]) __P((void));
+extern int nfs_diskless_valid;
+extern int sigcode;
+extern int szsigcode;
+
+struct proc;
+struct reg;
+
+void configure __P((void));
+void cpu_reset __P((void));
+void doreti_iret __P((void)) __asm(__STRING(doreti_iret));
+void doreti_iret_fault __P((void)) __asm(__STRING(doreti_iret_fault));
+void doreti_popl_ds __P((void)) __asm(__STRING(doreti_popl_ds));
+void doreti_popl_ds_fault __P((void)) __asm(__STRING(doreti_popl_ds_fault));
+void doreti_popl_es __P((void)) __asm(__STRING(doreti_popl_es));
+void doreti_popl_es_fault __P((void)) __asm(__STRING(doreti_popl_es_fault));
+int fill_regs __P((struct proc *p, struct reg *regs));
+int mvesp __P((void));
+void setconf __P((void));
+void userconfig __P((void));
+
+#endif /* !_MACHINE_MD_VAR_H_ */
diff --git a/sys/amd64/include/pmap.h b/sys/amd64/include/pmap.h
index 694d5af..ece8588 100644
--- a/sys/amd64/include/pmap.h
+++ b/sys/amd64/include/pmap.h
@@ -42,7 +42,7 @@
*
* from: hp300: @(#)pmap.h 7.2 (Berkeley) 12/16/90
* from: @(#)pmap.h 7.4 (Berkeley) 5/12/91
- * $Id: pmap.h,v 1.22 1995/02/14 06:55:42 phk Exp $
+ * $Id: pmap.h,v 1.23 1995/02/14 06:57:45 phk Exp $
*/
#ifndef _MACHINE_PMAP_H_
@@ -190,7 +190,14 @@ typedef struct pv_entry {
#ifdef KERNEL
-pv_entry_t pv_table; /* array of entries, one per page */
+extern caddr_t CADDR1;
+extern pt_entry_t *CMAP1;
+extern vm_offset_t avail_end;
+extern vm_offset_t avail_start;
+extern vm_offset_t phys_avail[6];
+extern pv_entry_t pv_table; /* array of entries, one per page */
+extern vm_offset_t virtual_avail;
+extern vm_offset_t virtual_end;
#define pa_index(pa) atop(pa - vm_first_phys)
#define pa_to_pvh(pa) (&pv_table[pa_index(pa)])
diff --git a/sys/amd64/isa/clock.c b/sys/amd64/isa/clock.c
index d3ca0f0..2676332 100644
--- a/sys/amd64/isa/clock.c
+++ b/sys/amd64/isa/clock.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* from: @(#)clock.c 7.2 (Berkeley) 5/12/91
- * $Id: clock.c,v 1.29 1994/12/30 12:43:34 bde Exp $
+ * $Id: clock.c,v 1.31 1995/01/19 22:05:27 ats Exp $
*/
/*
@@ -55,6 +55,7 @@
#include <machine/frame.h>
#include <i386/isa/icu.h>
#include <i386/isa/isa.h>
+#include <i386/isa/isa_device.h>
#include <i386/isa/rtc.h>
#include <i386/isa/timerreg.h>
@@ -558,8 +559,9 @@ cpu_initclocks()
profhz = RTC_PROFRATE;
/* Finish initializing 8253 timer 0. */
- register_intr(/* irq */ 0, /* XXX id */ 0, /* flags */ 0, clkintr,
- &clk_imask, /* unit */ 0);
+ register_intr(/* irq */ 0, /* XXX id */ 0, /* flags */ 0,
+ /* XXX */ (inthand2_t *)clkintr, &clk_imask,
+ /* unit */ 0);
INTREN(IRQ0);
/* Initialize RTC. */
@@ -568,8 +570,9 @@ cpu_initclocks()
diag = rtcin(RTC_DIAG);
if (diag != 0)
printf("RTC BIOS diagnostic error %b\n", diag, RTCDG_BITS);
- register_intr(/* irq */ 8, /* XXX id */ 1, /* flags */ 0, rtcintr,
- &stat_imask, /* unit */ 0);
+ register_intr(/* irq */ 8, /* XXX id */ 1, /* flags */ 0,
+ /* XXX */ (inthand2_t *)rtcintr, &stat_imask,
+ /* unit */ 0);
INTREN(IRQ8);
writertc(RTC_STATUSB, RTCSB_24HR | RTCSB_PINTR);
}
diff --git a/sys/ddb/db_command.c b/sys/ddb/db_command.c
index 9cc2dbf..4aded1d 100644
--- a/sys/ddb/db_command.c
+++ b/sys/ddb/db_command.c
@@ -23,7 +23,7 @@
* any improvements or extensions that they make and grant Carnegie the
* rights to redistribute these changes.
*
- * $Id: db_command.c,v 1.9 1995/02/05 21:09:04 phk Exp $
+ * $Id: db_command.c,v 1.10 1995/03/05 22:56:21 joerg Exp $
*/
/*
@@ -62,6 +62,9 @@ db_addr_t db_next;
boolean_t db_ed_style = TRUE;
+void db_help_cmd __P((void));
+void db_fncall __P((void));
+
/*
* Utility routine - discard tokens through end-of-line.
*/
@@ -182,7 +185,6 @@ db_command(last_cmdp, cmd_table)
modif[0] = '\0';
}
else if (t == tEXCL) {
- void db_fncall();
db_fncall();
return;
}
@@ -308,7 +310,9 @@ extern void db_show_one_thread(), db_show_all_threads();
extern void vm_page_print();
extern void db_ps();
extern void ipc_port_print();
+#if 0
void db_show_help();
+#endif
void db_panic();
struct command db_show_all_cmds[] = {
@@ -338,9 +342,6 @@ struct command db_show_cmds[] = {
{ (char *)0, }
};
-void db_help_cmd();
-void db_fncall();
-
struct command db_command_table[] = {
{ "print", db_print_cmd, 0, 0 },
{ "p", db_print_cmd, 0, 0 },
@@ -372,6 +373,7 @@ struct command db_command_table[] = {
struct command *db_last_command = 0;
+#if 0
void
db_help_cmd()
{
@@ -383,6 +385,7 @@ db_help_cmd()
cmd++;
}
}
+#endif
void
db_panic()
diff --git a/sys/ddb/db_sym.h b/sys/ddb/db_sym.h
index 661f16b..88cd689 100644
--- a/sys/ddb/db_sym.h
+++ b/sys/ddb/db_sym.h
@@ -23,7 +23,7 @@
* any improvements or extensions that they make and grant Carnegie the
* rights to redistribute these changes.
*
- * $Id: db_sym.h,v 1.5 1994/08/20 03:48:27 davidg Exp $
+ * $Id: db_sym.h,v 1.6 1994/09/27 03:34:57 phk Exp $
*/
#ifndef _DDB_DB_SYM_H_
@@ -97,6 +97,7 @@ extern int db_eqname(/* char*, char*, char */);
extern void db_printsym(/* db_expr_t, db_strategy_t */);
/* print closest symbol to a value */
extern boolean_t db_line_at_pc(db_sym_t, char **, int *, db_expr_t);
+extern int db_sym_numargs(db_sym_t, int *, char **);
extern int X_db_sym_numargs(db_symtab_t *, db_sym_t, int *, char **);
#endif /* _DDB_DB_SYM_H_ */
diff --git a/sys/ddb/ddb.h b/sys/ddb/ddb.h
index a72b5ca..23cfc60 100644
--- a/sys/ddb/ddb.h
+++ b/sys/ddb/ddb.h
@@ -27,7 +27,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: ddb.h,v 1.3 1994/09/27 12:11:09 davidg Exp $
+ * $Id: ddb.h,v 1.4 1994/09/27 12:15:56 davidg Exp $
*/
/*
@@ -105,6 +105,9 @@ extern void db_single_step (db_regs_t *regs);
extern void db_trap (int type, int code);
+extern void cnpollc(int);
+
+extern void kdb_init(void);
extern void kdbprinttrap(int, int);
#endif /* __h_ddb_ddb */
diff --git a/sys/dev/ed/if_ed.c b/sys/dev/ed/if_ed.c
index 718c670..e4e71e2 100644
--- a/sys/dev/ed/if_ed.c
+++ b/sys/dev/ed/if_ed.c
@@ -13,7 +13,7 @@
* the SMC Elite Ultra (8216), the 3Com 3c503, the NE1000 and NE2000,
* and a variety of similar clones.
*
- * $Id: if_ed.c,v 1.66 1995/02/25 15:56:00 davidg Exp $
+ * $Id: if_ed.c,v 1.67 1995/02/26 20:03:53 davidg Exp $
*/
#include "ed.h"
@@ -50,6 +50,8 @@
#include <net/bpfdesc.h>
#endif
+#include <machine/clock.h>
+
#include <i386/isa/isa.h>
#include <i386/isa/isa_device.h>
#include <i386/isa/icu.h>
diff --git a/sys/dev/fdc/fdc.c b/sys/dev/fdc/fdc.c
index 94b0329..6ab787b 100644
--- a/sys/dev/fdc/fdc.c
+++ b/sys/dev/fdc/fdc.c
@@ -43,7 +43,7 @@
* SUCH DAMAGE.
*
* from: @(#)fd.c 7.4 (Berkeley) 5/25/91
- * $Id: fd.c,v 1.52 1995/02/26 01:37:51 bde Exp $
+ * $Id: fd.c,v 1.53 1995/03/12 22:40:56 joerg Exp $
*
*/
@@ -289,6 +289,7 @@ static timeout_t fd_turnoff;
static timeout_t fd_motor_on;
static void fd_turnon(fdu_t);
static void fdc_reset(fdc_p);
+static int fd_in(fdcu_t, int *);
static void fdstart(fdcu_t);
static timeout_t fd_timeout;
static timeout_t fd_pseudointr;
@@ -477,9 +478,19 @@ int
fd_read_status(fdc_p fdc, int fdsu)
{
int i, ret;
+
for (i = 0; i < 7; i++)
{
- if ((ret = fd_in(fdc->fdcu, fdc->status + i)))
+ /*
+ * XXX types are poorly chosen. Only bytes can by read
+ * from the hardware, but fdc_status wants u_longs and
+ * fd_in() gives ints.
+ */
+ int status;
+
+ ret = fd_in(fdc->fdcu, &status);
+ fdc->status[i] = status;
+ if (ret != 0)
break;
}
@@ -854,7 +865,7 @@ in_fdc(fdcu_t fdcu)
/*
* fd_in: Like in_fdc, but allows you to see if it worked.
*/
-int
+static int
fd_in(fdcu_t fdcu, int *ptr)
{
int baseport = fdc_data[fdcu].baseport;
diff --git a/sys/dev/sio/sio.c b/sys/dev/sio/sio.c
index 1d8bf01..565bb19 100644
--- a/sys/dev/sio/sio.c
+++ b/sys/dev/sio/sio.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* from: @(#)com.c 7.5 (Berkeley) 5/16/91
- * $Id: sio.c,v 1.69 1995/02/28 00:20:54 pst Exp $
+ * $Id: sio.c,v 1.70 1995/02/28 23:21:33 ache Exp $
*/
#include "sio.h"
@@ -313,10 +313,9 @@ struct tty *sio_tty[NSIO];
#else
struct tty sio_tty[NSIO];
#endif
-extern struct tty *constty; /* XXX */
#ifdef KGDB
-#include "machine/remote-sl.h"
+#include <machine/remote-sl.h>
extern int kgdb_dev;
extern int kgdb_rate;
@@ -1955,7 +1954,7 @@ comwakeup(chan)
/*
* Following are all routines needed for SIO to act as console
*/
-#include "i386/i386/cons.h"
+#include <i386/i386/cons.h>
struct siocnstate {
u_char dlbl;
diff --git a/sys/dev/speaker/spkr.c b/sys/dev/speaker/spkr.c
index 70e50a9..f9c72d6 100644
--- a/sys/dev/speaker/spkr.c
+++ b/sys/dev/speaker/spkr.c
@@ -4,7 +4,7 @@
* v1.4 by Eric S. Raymond (esr@snark.thyrsus.com) Aug 1993
* modified for FreeBSD by Andrew A. Chernov <ache@astral.msk.su>
*
- * $Id: spkr.c,v 1.10 1994/10/14 16:37:58 ache Exp $
+ * $Id: spkr.c,v 1.11 1995/02/03 10:19:38 ache Exp $
*/
#include "speaker.h"
@@ -16,9 +16,11 @@
#include <sys/kernel.h>
#include <sys/errno.h>
#include <sys/buf.h>
+#include <sys/proc.h>
#include <sys/uio.h>
#include <i386/isa/isa.h>
#include <i386/isa/timerreg.h>
+#include <machine/clock.h>
#include <machine/speaker.h>
/**************** MACHINE DEPENDENT PART STARTS HERE *************************
diff --git a/sys/fs/cd9660/cd9660_node.c b/sys/fs/cd9660/cd9660_node.c
index 080f342..a6292f3 100644
--- a/sys/fs/cd9660/cd9660_node.c
+++ b/sys/fs/cd9660/cd9660_node.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)cd9660_node.c 8.2 (Berkeley) 1/23/94
- * $Id: cd9660_node.c,v 1.8 1995/01/16 17:03:24 joerg Exp $
+ * $Id: cd9660_node.c,v 1.9 1995/02/21 18:41:30 bde Exp $
*/
#include <sys/param.h>
@@ -80,8 +80,6 @@ union iso_dhead {
} iso_dhead[DNOHSZ];
#endif
-int prtactive; /* 1 => print out reclaim of active vnodes */
-
/*
* Initialize hash links for inodes and dnodes.
*/
@@ -289,11 +287,8 @@ loop:
vp->v_type = IFTOVT(ip->inode.iso_mode);
if ( vp->v_type == VFIFO ) {
- extern int (**cd9660_fifoop_p)();
vp->v_op = cd9660_fifoop_p;
} else if ( vp->v_type == VCHR || vp->v_type == VBLK ) {
- extern int (**cd9660_specop_p)();
-
/*
* if device, look at device number table for translation
*/
diff --git a/sys/fs/cd9660/cd9660_node.h b/sys/fs/cd9660/cd9660_node.h
index ca7627e..1e593a2 100644
--- a/sys/fs/cd9660/cd9660_node.h
+++ b/sys/fs/cd9660/cd9660_node.h
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)cd9660_node.h 8.2 (Berkeley) 1/23/94
- * $Id: cd9660_node.h,v 1.3 1994/09/15 19:46:00 bde Exp $
+ * $Id: cd9660_node.h,v 1.4 1995/01/16 17:03:25 joerg Exp $
*/
/*
@@ -111,6 +111,9 @@ struct iso_node {
#define ISO_ILOCK(ip) iso_ilock(ip)
#define ISO_IUNLOCK(ip) iso_iunlock(ip)
+extern int (**cd9660_fifoop_p)();
+extern int (**cd9660_specop_p)();
+
/*
* Prototypes for ISOFS vnode operations
*/
diff --git a/sys/fs/fdescfs/fdesc_vfsops.c b/sys/fs/fdescfs/fdesc_vfsops.c
index d82f14d..e44c045 100644
--- a/sys/fs/fdescfs/fdesc_vfsops.c
+++ b/sys/fs/fdescfs/fdesc_vfsops.c
@@ -35,7 +35,7 @@
*
* @(#)fdesc_vfsops.c 8.4 (Berkeley) 1/21/94
*
- * $Id: fdesc_vfsops.c,v 1.1.1.1 1994/05/24 10:04:59 rgrimes Exp $
+ * $Id: fdesc_vfsops.c,v 1.2 1994/09/21 03:46:55 wollman Exp $
*/
/*
@@ -116,7 +116,6 @@ fdesc_unmount(mp, mntflags, p)
{
int error;
int flags = 0;
- extern int doforce;
struct vnode *rootvp = VFSTOFDESC(mp)->f_root;
if (mntflags & MNT_FORCE) {
diff --git a/sys/fs/fifofs/fifo.h b/sys/fs/fifofs/fifo.h
index 384b6c2..3f2d8ef 100644
--- a/sys/fs/fifofs/fifo.h
+++ b/sys/fs/fifofs/fifo.h
@@ -31,9 +31,11 @@
* SUCH DAMAGE.
*
* @(#)fifo.h 8.2 (Berkeley) 2/2/94
- * $Id: fifo.h,v 1.3 1994/09/22 19:38:05 wollman Exp $
+ * $Id: fifo.h,v 1.4 1995/02/14 06:30:18 phk Exp $
*/
+extern int (**fifo_vnodeop_p)();
+
/*
* Prototypes for fifo operations on vnodes.
*/
diff --git a/sys/fs/fifofs/fifo_vnops.c b/sys/fs/fifofs/fifo_vnops.c
index 78f6201..bf1ec82 100644
--- a/sys/fs/fifofs/fifo_vnops.c
+++ b/sys/fs/fifofs/fifo_vnops.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)fifo_vnops.c 8.2 (Berkeley) 1/4/94
- * $Id: fifo_vnops.c,v 1.6 1994/10/02 17:48:00 phk Exp $
+ * $Id: fifo_vnops.c,v 1.7 1995/02/03 06:46:13 davidg Exp $
*/
#include <sys/param.h>
@@ -48,6 +48,7 @@
#include <sys/file.h>
#include <sys/errno.h>
#include <sys/malloc.h>
+#include <sys/un.h>
#include <miscfs/fifofs/fifo.h>
/*
diff --git a/sys/fs/msdosfs/denode.h b/sys/fs/msdosfs/denode.h
index a45994b..b47196a 100644
--- a/sys/fs/msdosfs/denode.h
+++ b/sys/fs/msdosfs/denode.h
@@ -1,4 +1,4 @@
-/* $Id: denode.h,v 1.2 1994/12/12 12:35:40 bde Exp $ */
+/* $Id: denode.h,v 1.3 1994/12/27 12:37:33 bde Exp $ */
/* $NetBSD: denode.h,v 1.8 1994/08/21 18:43:49 ws Exp $ */
/*-
@@ -225,6 +225,8 @@ struct defid {
/* u_long defid_gen; generation number */
};
+extern int (**msdosfs_vnodeop_p)();
+
/*
* Prototypes for MSDOSFS vnode operations
*/
diff --git a/sys/fs/msdosfs/msdosfs_denode.c b/sys/fs/msdosfs/msdosfs_denode.c
index 2e03af6..1d08e42 100644
--- a/sys/fs/msdosfs/msdosfs_denode.c
+++ b/sys/fs/msdosfs/msdosfs_denode.c
@@ -1,4 +1,4 @@
-/* $Id: msdosfs_denode.c,v 1.7 1995/01/09 16:04:59 davidg Exp $ */
+/* $Id: msdosfs_denode.c,v 1.8 1995/01/29 01:27:58 ats Exp $ */
/* $NetBSD: msdosfs_denode.c,v 1.9 1994/08/21 18:44:00 ws Exp $ */
/*-
@@ -168,7 +168,6 @@ deget(pmp, dirclust, diroffset, direntptr, depp)
int error;
dev_t dev = pmp->pm_dev;
struct mount *mntp = pmp->pm_mountp;
- extern int (**msdosfs_vnodeop_p)();
struct denode *ldep;
struct vnode *nvp;
struct buf *bp;
@@ -614,7 +613,6 @@ msdosfs_reclaim(ap)
{
struct vnode *vp = ap->a_vp;
struct denode *dep = VTODE(vp);
- extern int prtactive;
#ifdef MSDOSFS_DEBUG
printf("msdosfs_reclaim(): dep %p, file %s, refcnt %ld\n",
@@ -655,7 +653,6 @@ msdosfs_inactive(ap)
struct vnode *vp = ap->a_vp;
struct denode *dep = VTODE(vp);
int error = 0;
- extern int prtactive;
struct timespec ts;
#ifdef MSDOSFS_DEBUG
diff --git a/sys/fs/nullfs/null_vfsops.c b/sys/fs/nullfs/null_vfsops.c
index 4e13fb2..f7656c4 100644
--- a/sys/fs/nullfs/null_vfsops.c
+++ b/sys/fs/nullfs/null_vfsops.c
@@ -36,7 +36,7 @@
* @(#)null_vfsops.c 8.2 (Berkeley) 1/21/94
*
* @(#)lofs_vfsops.c 1.2 (Berkeley) 6/18/92
- * $Id: null_vfsops.c,v 1.3 1994/09/22 19:38:14 wollman Exp $
+ * $Id: null_vfsops.c,v 1.4 1994/10/10 07:55:28 phk Exp $
*/
/*
@@ -186,7 +186,6 @@ nullfs_unmount(mp, mntflags, p)
struct vnode *nullm_rootvp = MOUNTTONULLMOUNT(mp)->nullm_rootvp;
int error;
int flags = 0;
- extern int doforce;
#ifdef NULLFS_DIAGNOSTIC
printf("nullfs_unmount(mp = %x)\n", mp);
diff --git a/sys/fs/portalfs/portal_vfsops.c b/sys/fs/portalfs/portal_vfsops.c
index 39d54c2..cad30bd 100644
--- a/sys/fs/portalfs/portal_vfsops.c
+++ b/sys/fs/portalfs/portal_vfsops.c
@@ -35,7 +35,7 @@
*
* @(#)portal_vfsops.c 8.6 (Berkeley) 1/21/94
*
- * $Id: portal_vfsops.c,v 1.4 1994/09/23 11:01:58 davidg Exp $
+ * $Id: portal_vfsops.c,v 1.5 1994/10/10 07:55:35 phk Exp $
*/
/*
@@ -155,7 +155,6 @@ portal_unmount(mp, mntflags, p)
int mntflags;
struct proc *p;
{
- extern int doforce;
struct vnode *rootvp = VFSTOPORTAL(mp)->pm_root;
int error, flags = 0;
diff --git a/sys/fs/procfs/procfs.h b/sys/fs/procfs/procfs.h
index 7a1bbb8..79a77da 100644
--- a/sys/fs/procfs/procfs.h
+++ b/sys/fs/procfs/procfs.h
@@ -36,7 +36,7 @@
*
* @(#)procfs.h 8.6 (Berkeley) 2/3/94
*
- * $Id: procfs.h,v 1.1.1.1 1994/05/24 10:05:07 rgrimes Exp $
+ * $Id: procfs.h,v 1.2 1994/08/02 07:45:08 davidg Exp $
*/
/*
@@ -139,6 +139,8 @@ extern int procfs_dostatus __P((struct proc *, struct proc *, struct pfsnode *pf
extern int (**procfs_vnodeop_p)();
extern struct vfsops procfs_vfsops;
+int procfs_root __P((struct mount *, struct vnode **));
+
/*
* Prototypes for procfs vnode ops
*/
diff --git a/sys/fs/procfs/procfs_ctl.c b/sys/fs/procfs/procfs_ctl.c
index 5902efd..5befe23 100644
--- a/sys/fs/procfs/procfs_ctl.c
+++ b/sys/fs/procfs/procfs_ctl.c
@@ -36,7 +36,7 @@
*
* @(#)procfs_ctl.c 8.3 (Berkeley) 1/21/94
*
- * $Id: procfs_ctl.c,v 1.3 1994/12/31 12:26:50 ache Exp $
+ * $Id: procfs_ctl.c,v 1.4 1995/02/20 15:53:32 davidg Exp $
*/
#include <sys/param.h>
@@ -47,10 +47,15 @@
#include <sys/vnode.h>
#include <sys/ioctl.h>
#include <sys/tty.h>
+#include <sys/ptrace.h>
#include <sys/resource.h>
#include <sys/resourcevar.h>
+#include <sys/signal.h>
+#include <sys/signalvar.h>
+
+#include <vm/vm.h>
+
#include <miscfs/procfs/procfs.h>
-#include <sys/signal.h> /* for sigmask() */
/*
* True iff process (p) is in trace wait state
diff --git a/sys/fs/procfs/procfs_vfsops.c b/sys/fs/procfs/procfs_vfsops.c
index e54d012..4379d0a 100644
--- a/sys/fs/procfs/procfs_vfsops.c
+++ b/sys/fs/procfs/procfs_vfsops.c
@@ -36,7 +36,7 @@
*
* @(#)procfs_vfsops.c 8.4 (Berkeley) 1/21/94
*
- * $Id: procfs_vfsops.c,v 1.6 1994/10/10 07:55:39 phk Exp $
+ * $Id: procfs_vfsops.c,v 1.7 1995/02/20 15:53:33 davidg Exp $
*/
/*
@@ -104,7 +104,6 @@ procfs_unmount(mp, mntflags, p)
struct proc *p;
{
int error;
- extern int doforce;
int flags = 0;
if (mntflags & MNT_FORCE) {
diff --git a/sys/fs/umapfs/umap_vfsops.c b/sys/fs/umapfs/umap_vfsops.c
index e0baf46..0eeab20 100644
--- a/sys/fs/umapfs/umap_vfsops.c
+++ b/sys/fs/umapfs/umap_vfsops.c
@@ -35,7 +35,7 @@
*
* @(#)umap_vfsops.c 8.3 (Berkeley) 1/21/94
*
- * $Id: umap_vfsops.c,v 1.4 1994/09/22 19:38:19 wollman Exp $
+ * $Id: umap_vfsops.c,v 1.5 1994/10/10 07:55:43 phk Exp $
*/
/*
@@ -227,7 +227,6 @@ umapfs_unmount(mp, mntflags, p)
struct vnode *umapm_rootvp = MOUNTTOUMAPMOUNT(mp)->umapm_rootvp;
int error;
int flags = 0;
- extern int doforce;
#ifdef UMAPFS_DIAGNOSTIC
printf("umapfs_unmount(mp = %x)\n", mp);
diff --git a/sys/fs/unionfs/union.h b/sys/fs/unionfs/union.h
index b66e17c..05fa481 100644
--- a/sys/fs/unionfs/union.h
+++ b/sys/fs/unionfs/union.h
@@ -35,7 +35,7 @@
* SUCH DAMAGE.
*
* @(#)union.h 8.2 (Berkeley) 2/17/94
- * $Id$
+ * $Id: union.h,v 1.2 1994/08/02 07:45:42 davidg Exp $
*/
struct union_args {
@@ -93,12 +93,15 @@ extern int union_allocvp __P((struct vnode **, struct mount *,
struct vnode *, struct vnode *,
struct componentname *, struct vnode *,
struct vnode *));
+extern int union_freevp __P((struct vnode *));
extern int union_copyfile __P((struct proc *, struct ucred *,
struct vnode *, struct vnode *));
extern int union_mkshadow __P((struct union_mount *, struct vnode *,
struct componentname *, struct vnode **));
extern int union_vn_create __P((struct vnode **, struct union_node *,
struct proc *));
+extern int union_vn_close __P((struct vnode *, int, struct ucred *,
+ struct proc *));
extern int union_cn_close __P((struct vnode *, int, struct ucred *,
struct proc *));
extern void union_removed_upper __P((struct union_node *un));
diff --git a/sys/fs/unionfs/union_vfsops.c b/sys/fs/unionfs/union_vfsops.c
index 393fe9d..4000f98 100644
--- a/sys/fs/unionfs/union_vfsops.c
+++ b/sys/fs/unionfs/union_vfsops.c
@@ -35,7 +35,7 @@
* SUCH DAMAGE.
*
* @(#)union_vfsops.c 8.7 (Berkeley) 3/5/94
- * $Id: union_vfsops.c,v 1.6 1994/10/10 07:55:47 phk Exp $
+ * $Id: union_vfsops.c,v 1.7 1994/11/04 14:41:43 davidg Exp $
*/
/*
@@ -56,6 +56,9 @@
#include <sys/queue.h>
#include <miscfs/union/union.h>
+int union_root __P((struct mount *, struct vnode **));
+int union_statfs __P((struct mount *, struct statfs *, struct proc *));
+
/*
* Mount union filesystem
*/
@@ -303,7 +306,6 @@ union_unmount(mp, mntflags, p)
struct vnode *um_rootvp;
int error;
int flags = 0;
- extern int doforce;
#ifdef UNION_DIAGNOSTIC
printf("union_unmount(mp = %x)\n", mp);
diff --git a/sys/gnu/i386/fpemul/errors.c b/sys/gnu/i386/fpemul/errors.c
index f9f6eb1..a303b34 100644
--- a/sys/gnu/i386/fpemul/errors.c
+++ b/sys/gnu/i386/fpemul/errors.c
@@ -56,7 +56,7 @@
* W. Metzenthen June 1994.
*
*
- * $Id: errors.c,v 1.2 1994/04/29 21:07:12 gclarkii Exp $
+ * $Id: errors.c,v 1.3 1994/06/10 07:44:10 rich Exp $
*
*/
@@ -72,6 +72,7 @@
#include "param.h"
+#include "systm.h"
#include "proc.h"
#include "machine/cpu.h"
#include "machine/pcb.h"
diff --git a/sys/gnu/i386/fpemul/fpu_proto.h b/sys/gnu/i386/fpemul/fpu_proto.h
index 255aa5d..c15c913 100644
--- a/sys/gnu/i386/fpemul/fpu_proto.h
+++ b/sys/gnu/i386/fpemul/fpu_proto.h
@@ -1,6 +1,6 @@
/*
*
- * $Id:$
+ * $Id: fpu_proto.h,v 1.2 1994/04/29 21:16:23 gclarkii Exp $
*
*/
@@ -53,7 +53,9 @@ extern void ffreep(void);
extern void fst_i_(void);
extern void fstp_i(void);
/* fpu_entry.c */
+#if 0
extern int math_emulate(struct trapframe * info);
+#endif
/* fpu_etc.c */
extern void fp_etc(void);
/* fpu_trig.c */
diff --git a/sys/i386/i386/autoconf.c b/sys/i386/i386/autoconf.c
index 00d0fa9..8d3dba3 100644
--- a/sys/i386/i386/autoconf.c
+++ b/sys/i386/i386/autoconf.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* from: @(#)autoconf.c 7.1 (Berkeley) 5/9/91
- * $Id: autoconf.c,v 1.19 1995/02/01 23:11:38 se Exp $
+ * $Id: autoconf.c,v 1.20 1995/02/18 18:04:30 wpaul Exp $
*/
/*
@@ -54,6 +54,7 @@
#include <sys/reboot.h>
#include <sys/kernel.h>
+#include <machine/md_var.h>
#include <machine/pte.h>
static void swapconf(void);
@@ -65,7 +66,6 @@ static void setroot(void);
* the machine.
*/
int dkn; /* number of iostat dk numbers assigned so far */
-extern int cold; /* cold start flag initialized in locore.s */
extern int (*mountroot) __P((void));
#ifdef FFS
@@ -101,12 +101,8 @@ configure()
#endif
#ifdef NFS
- {
- extern int nfs_diskless_valid;
-
if (nfs_diskless_valid)
mountroot = nfs_mountroot;
- }
#endif /* NFS */
#ifdef FFS
if (!mountroot) {
@@ -143,7 +139,6 @@ swapconf()
{
register struct swdevt *swp;
register int nblks;
- extern int Maxmem;
for (swp = swdevt; swp->sw_dev > 0; swp++)
{
diff --git a/sys/i386/i386/db_interface.c b/sys/i386/i386/db_interface.c
index d47998a..4fe5033 100644
--- a/sys/i386/i386/db_interface.c
+++ b/sys/i386/i386/db_interface.c
@@ -23,7 +23,7 @@
* any improvements or extensions that they make and grant Carnegie the
* rights to redistribute these changes.
*
- * $Id: db_interface.c,v 1.10 1994/09/15 11:38:59 davidg Exp $
+ * $Id: db_interface.c,v 1.11 1995/01/14 10:24:48 bde Exp $
*/
/*
@@ -35,6 +35,7 @@
#include <sys/proc.h>
#include <sys/reboot.h>
+#include <machine/md_var.h>
#include <machine/segments.h>
#include <ddb/ddb.h>
@@ -192,7 +193,6 @@ db_write_bytes(addr, size, data)
vm_offset_t addr1;
register pt_entry_t *ptep1 = 0;
pt_entry_t oldmap1 = { 0 };
- extern char etext;
db_nofault = &db_jmpbuf;
diff --git a/sys/i386/i386/db_trace.c b/sys/i386/i386/db_trace.c
index 756114f..28c152f 100644
--- a/sys/i386/i386/db_trace.c
+++ b/sys/i386/i386/db_trace.c
@@ -23,13 +23,15 @@
* any improvements or extensions that they make and grant Carnegie the
* rights to redistribute these changes.
*
- * $Id: db_trace.c,v 1.8 1994/08/13 03:49:37 wollman Exp $
+ * $Id: db_trace.c,v 1.9 1995/03/01 21:37:44 davidg Exp $
*/
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/proc.h>
+#include <machine/md_var.h>
+
#include <vm/vm.h>
#include <vm/vm_param.h>
#include <vm/lock.h>
@@ -109,7 +111,6 @@ db_numargs(fp)
int *argp;
int inst;
int args;
- extern char etext[];
argp = (int *)db_get_value((int)&fp->f_retaddr, 4, FALSE);
if (argp < (int *)VM_MIN_KERNEL_ADDRESS || argp > (int *)etext)
diff --git a/sys/i386/i386/machdep.c b/sys/i386/i386/machdep.c
index 74bdfe8..0b0064c 100644
--- a/sys/i386/i386/machdep.c
+++ b/sys/i386/i386/machdep.c
@@ -35,7 +35,7 @@
* SUCH DAMAGE.
*
* from: @(#)machdep.c 7.4 (Berkeley) 6/3/91
- * $Id: machdep.c,v 1.112 1995/03/03 00:43:08 davidg Exp $
+ * $Id: machdep.c,v 1.113 1995/03/07 19:58:02 davidg Exp $
*/
#include "npx.h"
@@ -54,6 +54,7 @@
#include <sys/callout.h>
#include <sys/malloc.h>
#include <sys/mbuf.h>
+#include <sys/mount.h>
#include <sys/msgbuf.h>
#include <sys/ioctl.h>
#include <sys/sysent.h>
@@ -79,9 +80,31 @@
#include <sys/exec.h>
#include <sys/vnode.h>
+#include <ddb/ddb.h>
+
#include <net/netisr.h>
-extern vm_offset_t avail_start, avail_end;
+/* XXX correctly declaring all the netisr's is painful. */
+#include <net/if.h>
+#include <net/route.h>
+
+#include <netinet/in.h>
+#include <netinet/in_systm.h>
+#include <netinet/ip.h>
+#include <netinet/if_ether.h>
+#include <netinet/ip_var.h>
+
+#include <netns/ns.h>
+#include <netns/ns_if.h>
+
+#include <netiso/iso.h>
+#include <netiso/iso_var.h>
+
+#include <netccitt/dll.h>
+#include <netccitt/x25.h>
+#include <netccitt/pk.h>
+#include <sys/socketvar.h>
+#include <netccitt/pk_var.h>
#include "ether.h"
@@ -95,6 +118,7 @@ extern vm_offset_t avail_start, avail_end;
#include <machine/cons.h>
#include <machine/devconf.h>
#include <machine/bootinfo.h>
+#include <machine/md_var.h>
#include <i386/isa/isa.h>
#include <i386/isa/isa_device.h>
@@ -160,7 +184,6 @@ cpu_startup()
{
register unsigned i;
register caddr_t v;
- extern void (*netisrs[32])(void);
vm_offset_t maxaddr;
vm_size_t size = 0;
int firstaddr;
@@ -193,7 +216,7 @@ cpu_startup()
/*
* Quickly wire in netisrs.
*/
-#define DONET(isr, n) do { extern void isr(void); netisrs[n] = isr; } while(0)
+#define DONET(isr, n) do { netisrs[n] = isr; } while(0)
#ifdef INET
#if NETHER > 0
DONET(arpintr, NETISR_ARP);
@@ -377,8 +400,6 @@ struct cpu_nameclass i386_cpus[] = {
static void
identifycpu()
{
- extern u_long cpu_id, cpu_high, cpu_feature;
- extern char cpu_vendor[];
printf("CPU: ");
if (cpu >= 0
&& cpu < (sizeof i386_cpus/sizeof(struct cpu_nameclass))) {
@@ -482,8 +503,6 @@ identifycpu()
}
}
-extern char kstack[];
-
/*
* Send an interrupt to process.
*
@@ -726,7 +745,6 @@ boot(arghowto)
register long dummy; /* r12 is reserved */
register int howto; /* r11 == how to boot */
register int devtype; /* r10 == major of root dev */
- extern int cold;
if (cold) {
printf("hit reset please");
@@ -1161,18 +1179,14 @@ void
init386(first)
int first;
{
- extern char etext[];
int x;
unsigned biosbasemem, biosextmem;
struct gate_descriptor *gdp;
int gsel_tss;
- extern int sigcode,szsigcode;
/* table descriptors - used to load tables by microp */
struct region_descriptor r_gdt, r_idt;
int pagesinbase, pagesinext;
int target_page;
- extern struct pte *CMAP1;
- extern caddr_t CADDR1;
proc0.p_addr = proc0paddr;
diff --git a/sys/i386/i386/pmap.c b/sys/i386/i386/pmap.c
index 87e5f4f..52c1063f 100644
--- a/sys/i386/i386/pmap.c
+++ b/sys/i386/i386/pmap.c
@@ -39,7 +39,7 @@
* SUCH DAMAGE.
*
* from: @(#)pmap.c 7.7 (Berkeley) 5/12/91
- * $Id: pmap.c,v 1.51 1995/03/01 22:08:35 davidg Exp $
+ * $Id: pmap.c,v 1.52 1995/03/10 08:05:00 davidg Exp $
*/
/*
@@ -96,6 +96,7 @@
#include <vm/vm_page.h>
#include <machine/cputypes.h>
+#include <machine/md_var.h>
#include <i386/isa/isa.h>
@@ -159,6 +160,7 @@ extern int cpu_class;
* All those kernel PT submaps that BSD is so fond of
*/
pt_entry_t *CMAP1, *CMAP2, *ptmmap;
+pv_entry_t pv_table;
caddr_t CADDR1, CADDR2, ptvmmap;
pt_entry_t *msgbufmap;
struct msgbuf *msgbufp;
@@ -392,8 +394,6 @@ pmap_bootstrap(firstaddr, loadaddr)
* buffer (contiguous virtual *and* physical memory).
*/
{
- extern vm_offset_t isaphysmem;
-
isaphysmem = va;
virtual_avail = pmap_map(va, firstaddr,
diff --git a/sys/i386/i386/procfs_machdep.c b/sys/i386/i386/procfs_machdep.c
index b22eef5..1b51d06 100644
--- a/sys/i386/i386/procfs_machdep.c
+++ b/sys/i386/i386/procfs_machdep.c
@@ -37,7 +37,7 @@
* @(#)procfs_machdep.c 8.3 (Berkeley) 1/27/94
*
* From:
- * $Id: procfs_machdep.c,v 1.2 1994/05/25 08:54:48 rgrimes Exp $
+ * $Id: procfs_machdep.c,v 1.3 1995/01/14 13:20:09 bde Exp $
*/
/*
@@ -71,15 +71,15 @@
#include <sys/time.h>
#include <sys/kernel.h>
#include <sys/proc.h>
+#include <sys/ptrace.h>
#include <sys/user.h>
#include <sys/vnode.h>
#include <machine/psl.h>
#include <machine/reg.h>
#include <machine/frame.h>
+#include <machine/md_var.h>
#include <miscfs/procfs/procfs.h>
-extern char kstack[]; /* XXX */
-
int
procfs_read_regs(p, regs)
struct proc *p;
diff --git a/sys/i386/i386/swapgeneric.c b/sys/i386/i386/swapgeneric.c
index ae4eab3..470132a 100644
--- a/sys/i386/i386/swapgeneric.c
+++ b/sys/i386/i386/swapgeneric.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* from: @(#)swapgeneric.c 5.5 (Berkeley) 5/9/91
- * $Id: swapgeneric.c,v 1.5 1994/12/31 17:11:59 jkh Exp $
+ * $Id: swapgeneric.c,v 1.6 1995/03/02 23:45:49 wpaul Exp $
*/
#include <sys/param.h>
@@ -45,6 +45,8 @@
#include <sys/disklabel.h>
#include <sys/devconf.h>
+#include <machine/md_var.h>
+
#include "wd.h"
#include "fd.h"
#include "sd.h"
diff --git a/sys/i386/i386/trap.c b/sys/i386/i386/trap.c
index f98022b..2e64edd 100644
--- a/sys/i386/i386/trap.c
+++ b/sys/i386/i386/trap.c
@@ -35,7 +35,7 @@
* SUCH DAMAGE.
*
* from: @(#)trap.c 7.4 (Berkeley) 5/13/91
- * $Id: trap.c,v 1.47 1995/02/10 06:43:47 davidg Exp $
+ * $Id: trap.c,v 1.48 1995/02/14 19:20:31 sos Exp $
*/
/*
@@ -56,10 +56,12 @@
#include <vm/vm_param.h>
#include <vm/pmap.h>
+#include <vm/vm_kern.h>
#include <vm/vm_map.h>
#include <vm/vm_page.h>
#include <machine/cpu.h>
+#include <machine/md_var.h>
#include <machine/psl.h>
#include <machine/reg.h>
#include <machine/trap.h>
@@ -302,8 +304,6 @@ trap(frame)
*/
#define MAYBE_DORETI_FAULT(where, whereto) \
do { \
- extern void where(void) __asm(__STRING(where)); \
- extern void whereto(void) __asm(__STRING(whereto)); \
if (frame.tf_eip == (int)where) { \
frame.tf_eip = (int)whereto; \
return; \
@@ -398,7 +398,6 @@ trap_pfault(frame, usermode)
vm_map_t map = 0;
int rv = 0;
vm_prot_t ftype;
- extern vm_map_t kernel_map;
int eva;
struct proc *p = curproc;
diff --git a/sys/i386/i386/tsc.c b/sys/i386/i386/tsc.c
index d3ca0f0..2676332 100644
--- a/sys/i386/i386/tsc.c
+++ b/sys/i386/i386/tsc.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* from: @(#)clock.c 7.2 (Berkeley) 5/12/91
- * $Id: clock.c,v 1.29 1994/12/30 12:43:34 bde Exp $
+ * $Id: clock.c,v 1.31 1995/01/19 22:05:27 ats Exp $
*/
/*
@@ -55,6 +55,7 @@
#include <machine/frame.h>
#include <i386/isa/icu.h>
#include <i386/isa/isa.h>
+#include <i386/isa/isa_device.h>
#include <i386/isa/rtc.h>
#include <i386/isa/timerreg.h>
@@ -558,8 +559,9 @@ cpu_initclocks()
profhz = RTC_PROFRATE;
/* Finish initializing 8253 timer 0. */
- register_intr(/* irq */ 0, /* XXX id */ 0, /* flags */ 0, clkintr,
- &clk_imask, /* unit */ 0);
+ register_intr(/* irq */ 0, /* XXX id */ 0, /* flags */ 0,
+ /* XXX */ (inthand2_t *)clkintr, &clk_imask,
+ /* unit */ 0);
INTREN(IRQ0);
/* Initialize RTC. */
@@ -568,8 +570,9 @@ cpu_initclocks()
diag = rtcin(RTC_DIAG);
if (diag != 0)
printf("RTC BIOS diagnostic error %b\n", diag, RTCDG_BITS);
- register_intr(/* irq */ 8, /* XXX id */ 1, /* flags */ 0, rtcintr,
- &stat_imask, /* unit */ 0);
+ register_intr(/* irq */ 8, /* XXX id */ 1, /* flags */ 0,
+ /* XXX */ (inthand2_t *)rtcintr, &stat_imask,
+ /* unit */ 0);
INTREN(IRQ8);
writertc(RTC_STATUSB, RTCSB_24HR | RTCSB_PINTR);
}
diff --git a/sys/i386/i386/userconfig.c b/sys/i386/i386/userconfig.c
index 792f901..5ce2410 100644
--- a/sys/i386/i386/userconfig.c
+++ b/sys/i386/i386/userconfig.c
@@ -38,13 +38,15 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: userconfig.c,v 1.20 1995/03/02 20:07:05 dufault Exp $
+ * $Id: userconfig.c,v 1.21 1995/03/12 13:25:51 ugen Exp $
*/
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/malloc.h>
+#include <machine/md_var.h>
+
#include <i386/i386/cons.h>
#include <i386/isa/isa_device.h>
diff --git a/sys/i386/i386/vm_machdep.c b/sys/i386/i386/vm_machdep.c
index a444776..b4ae07c 100644
--- a/sys/i386/i386/vm_machdep.c
+++ b/sys/i386/i386/vm_machdep.c
@@ -38,7 +38,7 @@
*
* from: @(#)vm_machdep.c 7.3 (Berkeley) 5/13/91
* Utah $Hdr: vm_machdep.c 1.16.1.1 89/06/23$
- * $Id: vm_machdep.c,v 1.32 1995/02/20 22:23:31 davidg Exp $
+ * $Id: vm_machdep.c,v 1.33 1995/03/01 23:59:21 davidg Exp $
*/
#include "npx.h"
@@ -51,6 +51,7 @@
#include <sys/user.h>
#include <machine/cpu.h>
+#include <machine/md_var.h>
#include <vm/vm.h>
#include <vm/vm_kern.h>
@@ -546,8 +547,6 @@ cpu_fork(p1, p2)
{
register struct user *up = p2->p_addr;
int offset;
- extern char kstack[];
- extern int mvesp();
/*
* Copy pcb and stack from proc p1 to p2.
diff --git a/sys/i386/include/clock.h b/sys/i386/include/clock.h
index 33f8e74..3d87a07 100644
--- a/sys/i386/include/clock.h
+++ b/sys/i386/include/clock.h
@@ -49,13 +49,6 @@
#include <machine/frame.h>
/*
- * Kernel to clock driver interface.
- */
-void inittodr __P((time_t base));
-void resettodr __P((void));
-void startrtclock __P((void));
-
-/*
* i386 to clock driver interface.
* XXX almost all of it is misplaced. i586 stuff is done in isa/clock.c
* and isa stuff is done in i386/microtime.s and i386/support.s.
diff --git a/sys/i386/include/frame.h b/sys/i386/include/frame.h
index db2993e..9bee6ed 100644
--- a/sys/i386/include/frame.h
+++ b/sys/i386/include/frame.h
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* from: @(#)frame.h 5.2 (Berkeley) 1/18/91
- * $Id: frame.h,v 1.7 1994/01/03 07:55:32 davidg Exp $
+ * $Id: frame.h,v 1.9 1994/05/25 08:56:02 rgrimes Exp $
*/
#ifndef _MACHINE_FRAME_H_
@@ -72,8 +72,6 @@ struct trapframe {
int tf_ss;
};
-extern int kdb_trap(int, int, struct trapframe *);
-
/* Interrupt stack frame */
struct intrframe {
@@ -137,4 +135,8 @@ struct sigframe {
sig_t sf_handler;
struct sigcontext sf_sc;
};
+
+int kdb_trap __P((int, int, struct trapframe *));
+int math_emulate __P((struct trapframe * info));
+
#endif /* _MACHINE_FRAME_H_ */
diff --git a/sys/i386/include/md_var.h b/sys/i386/include/md_var.h
new file mode 100644
index 0000000..ad8ba37
--- /dev/null
+++ b/sys/i386/include/md_var.h
@@ -0,0 +1,68 @@
+/*-
+ * Copyright (c) 1995 Bruce D. Evans.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. Neither the name of the author nor the names of contributors
+ * may be used to endorse or promote products derived from this software
+ * without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * $Id: $
+ */
+
+#ifndef _MACHINE_MD_VAR_H_
+#define _MACHINE_MD_VAR_H_
+
+/*
+ * Miscellaneous machine-dependent declarations.
+ */
+
+extern int Maxmem;
+extern u_long cpu_feature;
+extern u_long cpu_high;
+extern u_long cpu_id;
+extern char cpu_vendor[];
+extern char etext[];
+extern vm_offset_t isaphysmem;
+extern char kstack[];
+extern void (*netisrs[32]) __P((void));
+extern int nfs_diskless_valid;
+extern int sigcode;
+extern int szsigcode;
+
+struct proc;
+struct reg;
+
+void configure __P((void));
+void cpu_reset __P((void));
+void doreti_iret __P((void)) __asm(__STRING(doreti_iret));
+void doreti_iret_fault __P((void)) __asm(__STRING(doreti_iret_fault));
+void doreti_popl_ds __P((void)) __asm(__STRING(doreti_popl_ds));
+void doreti_popl_ds_fault __P((void)) __asm(__STRING(doreti_popl_ds_fault));
+void doreti_popl_es __P((void)) __asm(__STRING(doreti_popl_es));
+void doreti_popl_es_fault __P((void)) __asm(__STRING(doreti_popl_es_fault));
+int fill_regs __P((struct proc *p, struct reg *regs));
+int mvesp __P((void));
+void setconf __P((void));
+void userconfig __P((void));
+
+#endif /* !_MACHINE_MD_VAR_H_ */
diff --git a/sys/i386/include/pmap.h b/sys/i386/include/pmap.h
index 694d5af..ece8588 100644
--- a/sys/i386/include/pmap.h
+++ b/sys/i386/include/pmap.h
@@ -42,7 +42,7 @@
*
* from: hp300: @(#)pmap.h 7.2 (Berkeley) 12/16/90
* from: @(#)pmap.h 7.4 (Berkeley) 5/12/91
- * $Id: pmap.h,v 1.22 1995/02/14 06:55:42 phk Exp $
+ * $Id: pmap.h,v 1.23 1995/02/14 06:57:45 phk Exp $
*/
#ifndef _MACHINE_PMAP_H_
@@ -190,7 +190,14 @@ typedef struct pv_entry {
#ifdef KERNEL
-pv_entry_t pv_table; /* array of entries, one per page */
+extern caddr_t CADDR1;
+extern pt_entry_t *CMAP1;
+extern vm_offset_t avail_end;
+extern vm_offset_t avail_start;
+extern vm_offset_t phys_avail[6];
+extern pv_entry_t pv_table; /* array of entries, one per page */
+extern vm_offset_t virtual_avail;
+extern vm_offset_t virtual_end;
#define pa_index(pa) atop(pa - vm_first_phys)
#define pa_to_pvh(pa) (&pv_table[pa_index(pa)])
diff --git a/sys/i386/isa/bt742a.c b/sys/i386/isa/bt742a.c
index bf8b97e..4efb7c3 100644
--- a/sys/i386/isa/bt742a.c
+++ b/sys/i386/isa/bt742a.c
@@ -12,7 +12,7 @@
* on the understanding that TFS is not responsible for the correct
* functioning of this software in any circumstances.
*
- * $Id: bt742a.c,v 1.29 1994/10/23 21:27:10 wollman Exp $
+ * $Id: bt742a.c,v 1.30 1994/11/08 02:53:42 jkh Exp $
*/
/*
@@ -48,6 +48,8 @@
#include <sys/user.h>
#endif /* KERNEL */
+#include <machine/clock.h>
+
#include <i386/isa/isa_device.h>
#include <scsi/scsi_all.h>
#include <scsi/scsiconf.h>
@@ -395,7 +397,9 @@ int btprobe();
int btattach();
int btintr();
int32 bt_scsi_cmd();
+int bt_poll __P((int unit, struct scsi_xfer *xs, struct bt_ccb *ccb));
void bt_timeout(void *);
+int bt_init __P((int unit));
void bt_inquire_setup_information();
void bt_done();
void btminphys();
diff --git a/sys/i386/isa/clock.c b/sys/i386/isa/clock.c
index d3ca0f0..2676332 100644
--- a/sys/i386/isa/clock.c
+++ b/sys/i386/isa/clock.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* from: @(#)clock.c 7.2 (Berkeley) 5/12/91
- * $Id: clock.c,v 1.29 1994/12/30 12:43:34 bde Exp $
+ * $Id: clock.c,v 1.31 1995/01/19 22:05:27 ats Exp $
*/
/*
@@ -55,6 +55,7 @@
#include <machine/frame.h>
#include <i386/isa/icu.h>
#include <i386/isa/isa.h>
+#include <i386/isa/isa_device.h>
#include <i386/isa/rtc.h>
#include <i386/isa/timerreg.h>
@@ -558,8 +559,9 @@ cpu_initclocks()
profhz = RTC_PROFRATE;
/* Finish initializing 8253 timer 0. */
- register_intr(/* irq */ 0, /* XXX id */ 0, /* flags */ 0, clkintr,
- &clk_imask, /* unit */ 0);
+ register_intr(/* irq */ 0, /* XXX id */ 0, /* flags */ 0,
+ /* XXX */ (inthand2_t *)clkintr, &clk_imask,
+ /* unit */ 0);
INTREN(IRQ0);
/* Initialize RTC. */
@@ -568,8 +570,9 @@ cpu_initclocks()
diag = rtcin(RTC_DIAG);
if (diag != 0)
printf("RTC BIOS diagnostic error %b\n", diag, RTCDG_BITS);
- register_intr(/* irq */ 8, /* XXX id */ 1, /* flags */ 0, rtcintr,
- &stat_imask, /* unit */ 0);
+ register_intr(/* irq */ 8, /* XXX id */ 1, /* flags */ 0,
+ /* XXX */ (inthand2_t *)rtcintr, &stat_imask,
+ /* unit */ 0);
INTREN(IRQ8);
writertc(RTC_STATUSB, RTCSB_24HR | RTCSB_PINTR);
}
diff --git a/sys/i386/isa/fd.c b/sys/i386/isa/fd.c
index 94b0329..6ab787b 100644
--- a/sys/i386/isa/fd.c
+++ b/sys/i386/isa/fd.c
@@ -43,7 +43,7 @@
* SUCH DAMAGE.
*
* from: @(#)fd.c 7.4 (Berkeley) 5/25/91
- * $Id: fd.c,v 1.52 1995/02/26 01:37:51 bde Exp $
+ * $Id: fd.c,v 1.53 1995/03/12 22:40:56 joerg Exp $
*
*/
@@ -289,6 +289,7 @@ static timeout_t fd_turnoff;
static timeout_t fd_motor_on;
static void fd_turnon(fdu_t);
static void fdc_reset(fdc_p);
+static int fd_in(fdcu_t, int *);
static void fdstart(fdcu_t);
static timeout_t fd_timeout;
static timeout_t fd_pseudointr;
@@ -477,9 +478,19 @@ int
fd_read_status(fdc_p fdc, int fdsu)
{
int i, ret;
+
for (i = 0; i < 7; i++)
{
- if ((ret = fd_in(fdc->fdcu, fdc->status + i)))
+ /*
+ * XXX types are poorly chosen. Only bytes can by read
+ * from the hardware, but fdc_status wants u_longs and
+ * fd_in() gives ints.
+ */
+ int status;
+
+ ret = fd_in(fdc->fdcu, &status);
+ fdc->status[i] = status;
+ if (ret != 0)
break;
}
@@ -854,7 +865,7 @@ in_fdc(fdcu_t fdcu)
/*
* fd_in: Like in_fdc, but allows you to see if it worked.
*/
-int
+static int
fd_in(fdcu_t fdcu, int *ptr)
{
int baseport = fdc_data[fdcu].baseport;
diff --git a/sys/i386/isa/if_ed.c b/sys/i386/isa/if_ed.c
index 718c670..e4e71e2 100644
--- a/sys/i386/isa/if_ed.c
+++ b/sys/i386/isa/if_ed.c
@@ -13,7 +13,7 @@
* the SMC Elite Ultra (8216), the 3Com 3c503, the NE1000 and NE2000,
* and a variety of similar clones.
*
- * $Id: if_ed.c,v 1.66 1995/02/25 15:56:00 davidg Exp $
+ * $Id: if_ed.c,v 1.67 1995/02/26 20:03:53 davidg Exp $
*/
#include "ed.h"
@@ -50,6 +50,8 @@
#include <net/bpfdesc.h>
#endif
+#include <machine/clock.h>
+
#include <i386/isa/isa.h>
#include <i386/isa/isa_device.h>
#include <i386/isa/icu.h>
diff --git a/sys/i386/isa/lpt.c b/sys/i386/isa/lpt.c
index e789111..c0b7302 100644
--- a/sys/i386/isa/lpt.c
+++ b/sys/i386/isa/lpt.c
@@ -46,7 +46,7 @@
* SUCH DAMAGE.
*
* from: unknown origin, 386BSD 0.1
- * $Id: lpt.c,v 1.25 1995/02/26 05:14:50 bde Exp $
+ * $Id: lpt.c,v 1.26 1995/02/26 21:41:41 phk Exp $
*/
/*
@@ -114,6 +114,7 @@
#include <sys/syslog.h>
#include <sys/devconf.h>
+#include <machine/clock.h>
#include <machine/lpt.h>
#include <i386/isa/isa.h>
diff --git a/sys/i386/isa/sio.c b/sys/i386/isa/sio.c
index 1d8bf01..565bb19 100644
--- a/sys/i386/isa/sio.c
+++ b/sys/i386/isa/sio.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* from: @(#)com.c 7.5 (Berkeley) 5/16/91
- * $Id: sio.c,v 1.69 1995/02/28 00:20:54 pst Exp $
+ * $Id: sio.c,v 1.70 1995/02/28 23:21:33 ache Exp $
*/
#include "sio.h"
@@ -313,10 +313,9 @@ struct tty *sio_tty[NSIO];
#else
struct tty sio_tty[NSIO];
#endif
-extern struct tty *constty; /* XXX */
#ifdef KGDB
-#include "machine/remote-sl.h"
+#include <machine/remote-sl.h>
extern int kgdb_dev;
extern int kgdb_rate;
@@ -1955,7 +1954,7 @@ comwakeup(chan)
/*
* Following are all routines needed for SIO to act as console
*/
-#include "i386/i386/cons.h"
+#include <i386/i386/cons.h>
struct siocnstate {
u_char dlbl;
diff --git a/sys/i386/isa/spkr.c b/sys/i386/isa/spkr.c
index 70e50a9..f9c72d6 100644
--- a/sys/i386/isa/spkr.c
+++ b/sys/i386/isa/spkr.c
@@ -4,7 +4,7 @@
* v1.4 by Eric S. Raymond (esr@snark.thyrsus.com) Aug 1993
* modified for FreeBSD by Andrew A. Chernov <ache@astral.msk.su>
*
- * $Id: spkr.c,v 1.10 1994/10/14 16:37:58 ache Exp $
+ * $Id: spkr.c,v 1.11 1995/02/03 10:19:38 ache Exp $
*/
#include "speaker.h"
@@ -16,9 +16,11 @@
#include <sys/kernel.h>
#include <sys/errno.h>
#include <sys/buf.h>
+#include <sys/proc.h>
#include <sys/uio.h>
#include <i386/isa/isa.h>
#include <i386/isa/timerreg.h>
+#include <machine/clock.h>
#include <machine/speaker.h>
/**************** MACHINE DEPENDENT PART STARTS HERE *************************
diff --git a/sys/i386/isa/ultra14f.c b/sys/i386/isa/ultra14f.c
index 224b439..f990988 100644
--- a/sys/i386/isa/ultra14f.c
+++ b/sys/i386/isa/ultra14f.c
@@ -22,7 +22,7 @@
* today: Fri Jun 2 17:21:03 EST 1994
* added 24F support ++sg
*
- * $Id: ultra14f.c,v 1.26 1994/10/23 21:27:38 wollman Exp $
+ * $Id: ultra14f.c,v 1.27 1995/01/07 23:23:40 ats Exp $
*/
#include <sys/types.h>
@@ -40,6 +40,8 @@
#include <sys/user.h>
#include <sys/devconf.h>
+#include <machine/clock.h>
+
#include <i386/isa/isa_device.h>
#endif /*KERNEL */
#include <scsi/scsi_all.h>
@@ -271,6 +273,8 @@ void uhaminphys();
void uha_done();
u_int32 uha_adapter_info();
struct mscp *uha_mscp_phys_kv();
+int uha_init __P((int unit));
+int uha24_init __P((int unit));
struct mscp *cheat;
unsigned long int scratch;
diff --git a/sys/i386/isa/wd.c b/sys/i386/isa/wd.c
index 84a876c..96c0abb 100644
--- a/sys/i386/isa/wd.c
+++ b/sys/i386/isa/wd.c
@@ -37,7 +37,7 @@ static int wdtest = 0;
* SUCH DAMAGE.
*
* from: @(#)wd.c 7.2 (Berkeley) 5/9/91
- * $Id: wd.c,v 1.67 1995/02/27 06:42:35 davidg Exp $
+ * $Id: wd.c,v 1.68 1995/03/06 05:40:44 davidg Exp $
*/
/* TODO:
@@ -81,6 +81,8 @@ static int wdtest = 0;
#include <sys/devconf.h>
#include <machine/bootinfo.h>
#include <machine/clock.h>
+#include <machine/md_var.h>
+#include <i386/i386/cons.h>
#include <i386/isa/isa.h>
#include <i386/isa/isa_device.h>
#include <i386/isa/wdreg.h>
@@ -1616,9 +1618,7 @@ wddump(dev_t dev)
long cylin, head, sector;
long secpertrk, secpercyl, nblocks;
char *addr;
- extern int Maxmem;
static int wddoingadump = 0;
- extern caddr_t CADDR1;
/* Toss any characters present prior to dump. */
while (cncheckc())
diff --git a/sys/isa/atrtc.c b/sys/isa/atrtc.c
index d3ca0f0..2676332 100644
--- a/sys/isa/atrtc.c
+++ b/sys/isa/atrtc.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* from: @(#)clock.c 7.2 (Berkeley) 5/12/91
- * $Id: clock.c,v 1.29 1994/12/30 12:43:34 bde Exp $
+ * $Id: clock.c,v 1.31 1995/01/19 22:05:27 ats Exp $
*/
/*
@@ -55,6 +55,7 @@
#include <machine/frame.h>
#include <i386/isa/icu.h>
#include <i386/isa/isa.h>
+#include <i386/isa/isa_device.h>
#include <i386/isa/rtc.h>
#include <i386/isa/timerreg.h>
@@ -558,8 +559,9 @@ cpu_initclocks()
profhz = RTC_PROFRATE;
/* Finish initializing 8253 timer 0. */
- register_intr(/* irq */ 0, /* XXX id */ 0, /* flags */ 0, clkintr,
- &clk_imask, /* unit */ 0);
+ register_intr(/* irq */ 0, /* XXX id */ 0, /* flags */ 0,
+ /* XXX */ (inthand2_t *)clkintr, &clk_imask,
+ /* unit */ 0);
INTREN(IRQ0);
/* Initialize RTC. */
@@ -568,8 +570,9 @@ cpu_initclocks()
diag = rtcin(RTC_DIAG);
if (diag != 0)
printf("RTC BIOS diagnostic error %b\n", diag, RTCDG_BITS);
- register_intr(/* irq */ 8, /* XXX id */ 1, /* flags */ 0, rtcintr,
- &stat_imask, /* unit */ 0);
+ register_intr(/* irq */ 8, /* XXX id */ 1, /* flags */ 0,
+ /* XXX */ (inthand2_t *)rtcintr, &stat_imask,
+ /* unit */ 0);
INTREN(IRQ8);
writertc(RTC_STATUSB, RTCSB_24HR | RTCSB_PINTR);
}
diff --git a/sys/isa/fd.c b/sys/isa/fd.c
index 94b0329..6ab787b 100644
--- a/sys/isa/fd.c
+++ b/sys/isa/fd.c
@@ -43,7 +43,7 @@
* SUCH DAMAGE.
*
* from: @(#)fd.c 7.4 (Berkeley) 5/25/91
- * $Id: fd.c,v 1.52 1995/02/26 01:37:51 bde Exp $
+ * $Id: fd.c,v 1.53 1995/03/12 22:40:56 joerg Exp $
*
*/
@@ -289,6 +289,7 @@ static timeout_t fd_turnoff;
static timeout_t fd_motor_on;
static void fd_turnon(fdu_t);
static void fdc_reset(fdc_p);
+static int fd_in(fdcu_t, int *);
static void fdstart(fdcu_t);
static timeout_t fd_timeout;
static timeout_t fd_pseudointr;
@@ -477,9 +478,19 @@ int
fd_read_status(fdc_p fdc, int fdsu)
{
int i, ret;
+
for (i = 0; i < 7; i++)
{
- if ((ret = fd_in(fdc->fdcu, fdc->status + i)))
+ /*
+ * XXX types are poorly chosen. Only bytes can by read
+ * from the hardware, but fdc_status wants u_longs and
+ * fd_in() gives ints.
+ */
+ int status;
+
+ ret = fd_in(fdc->fdcu, &status);
+ fdc->status[i] = status;
+ if (ret != 0)
break;
}
@@ -854,7 +865,7 @@ in_fdc(fdcu_t fdcu)
/*
* fd_in: Like in_fdc, but allows you to see if it worked.
*/
-int
+static int
fd_in(fdcu_t fdcu, int *ptr)
{
int baseport = fdc_data[fdcu].baseport;
diff --git a/sys/isa/sio.c b/sys/isa/sio.c
index 1d8bf01..565bb19 100644
--- a/sys/isa/sio.c
+++ b/sys/isa/sio.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* from: @(#)com.c 7.5 (Berkeley) 5/16/91
- * $Id: sio.c,v 1.69 1995/02/28 00:20:54 pst Exp $
+ * $Id: sio.c,v 1.70 1995/02/28 23:21:33 ache Exp $
*/
#include "sio.h"
@@ -313,10 +313,9 @@ struct tty *sio_tty[NSIO];
#else
struct tty sio_tty[NSIO];
#endif
-extern struct tty *constty; /* XXX */
#ifdef KGDB
-#include "machine/remote-sl.h"
+#include <machine/remote-sl.h>
extern int kgdb_dev;
extern int kgdb_rate;
@@ -1955,7 +1954,7 @@ comwakeup(chan)
/*
* Following are all routines needed for SIO to act as console
*/
-#include "i386/i386/cons.h"
+#include <i386/i386/cons.h>
struct siocnstate {
u_char dlbl;
diff --git a/sys/isofs/cd9660/cd9660_node.c b/sys/isofs/cd9660/cd9660_node.c
index 080f342..a6292f3 100644
--- a/sys/isofs/cd9660/cd9660_node.c
+++ b/sys/isofs/cd9660/cd9660_node.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)cd9660_node.c 8.2 (Berkeley) 1/23/94
- * $Id: cd9660_node.c,v 1.8 1995/01/16 17:03:24 joerg Exp $
+ * $Id: cd9660_node.c,v 1.9 1995/02/21 18:41:30 bde Exp $
*/
#include <sys/param.h>
@@ -80,8 +80,6 @@ union iso_dhead {
} iso_dhead[DNOHSZ];
#endif
-int prtactive; /* 1 => print out reclaim of active vnodes */
-
/*
* Initialize hash links for inodes and dnodes.
*/
@@ -289,11 +287,8 @@ loop:
vp->v_type = IFTOVT(ip->inode.iso_mode);
if ( vp->v_type == VFIFO ) {
- extern int (**cd9660_fifoop_p)();
vp->v_op = cd9660_fifoop_p;
} else if ( vp->v_type == VCHR || vp->v_type == VBLK ) {
- extern int (**cd9660_specop_p)();
-
/*
* if device, look at device number table for translation
*/
diff --git a/sys/isofs/cd9660/cd9660_node.h b/sys/isofs/cd9660/cd9660_node.h
index ca7627e..1e593a2 100644
--- a/sys/isofs/cd9660/cd9660_node.h
+++ b/sys/isofs/cd9660/cd9660_node.h
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)cd9660_node.h 8.2 (Berkeley) 1/23/94
- * $Id: cd9660_node.h,v 1.3 1994/09/15 19:46:00 bde Exp $
+ * $Id: cd9660_node.h,v 1.4 1995/01/16 17:03:25 joerg Exp $
*/
/*
@@ -111,6 +111,9 @@ struct iso_node {
#define ISO_ILOCK(ip) iso_ilock(ip)
#define ISO_IUNLOCK(ip) iso_iunlock(ip)
+extern int (**cd9660_fifoop_p)();
+extern int (**cd9660_specop_p)();
+
/*
* Prototypes for ISOFS vnode operations
*/
diff --git a/sys/kern/imgact_aout.c b/sys/kern/imgact_aout.c
index bdce10d..003e9b2 100644
--- a/sys/kern/imgact_aout.c
+++ b/sys/kern/imgact_aout.c
@@ -28,7 +28,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: imgact_aout.c,v 1.10 1995/02/14 19:22:27 sos Exp $
+ * $Id: imgact_aout.c,v 1.11 1995/02/20 22:23:03 davidg Exp $
*/
#include <sys/param.h>
@@ -52,7 +52,6 @@ exec_aout_imgact(iparams)
unsigned long vmaddr, virtual_offset, file_offset;
unsigned long bss_size;
int error;
- extern struct sysentvec aout_sysvec;
#ifdef COMPAT_LINUX
/*
diff --git a/sys/kern/imgact_gzip.c b/sys/kern/imgact_gzip.c
index 3178d10..a7e5f3c 100644
--- a/sys/kern/imgact_gzip.c
+++ b/sys/kern/imgact_gzip.c
@@ -6,7 +6,7 @@
* this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp
* ----------------------------------------------------------------------------
*
- * $Id: imgact_gzip.c,v 1.11 1995/02/13 07:40:33 phk Exp $
+ * $Id: imgact_gzip.c,v 1.12 1995/02/20 22:23:07 davidg Exp $
*
* This module handles execution of a.out files which have been run through
* "gzip". This saves diskspace, but wastes cpu-cycles and VM.
@@ -52,8 +52,6 @@ static int NextByte __P((void *vp));
static int do_aout_hdr __P((struct imgact_gzip *));
static int Flush __P((void *vp, u_char *, u_long siz));
-extern struct sysentvec aout_sysvec;
-
int
exec_gzip_imgact(iparams)
struct image_params *iparams;
diff --git a/sys/kern/init_main.c b/sys/kern/init_main.c
index b882e88..b0efc5a 100644
--- a/sys/kern/init_main.c
+++ b/sys/kern/init_main.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)init_main.c 8.9 (Berkeley) 1/21/94
- * $Id: init_main.c,v 1.17 1994/11/25 07:58:16 davidg Exp $
+ * $Id: init_main.c,v 1.18 1995/02/20 22:23:09 davidg Exp $
*/
#include <sys/param.h>
@@ -44,6 +44,9 @@
#include <sys/errno.h>
#include <sys/exec.h>
#include <sys/kernel.h>
+#ifdef GPROF
+#include <sys/gmon.h>
+#endif
#include <sys/mount.h>
#include <sys/proc.h>
#include <sys/resourcevar.h>
@@ -64,6 +67,7 @@
#include <machine/cpu.h>
#include <vm/vm.h>
+#include <vm/vm_pageout.h>
#ifdef HPFPLIB
char copyright[] =
@@ -125,10 +129,6 @@ main(framep)
register struct filedesc0 *fdp;
register int i;
int s, rval[2];
- extern int (*mountroot) __P((void));
- extern void roundrobin __P((void *));
- extern void schedcpu __P((void *));
- extern struct sysentvec aout_sysvec;
/*
* Initialize the current process pointer (curproc) before
@@ -445,7 +445,7 @@ start_init(p, framep)
* Now try to exec the program. If can't for any reason
* other than it doesn't exist, complain.
*/
- if ((error = execve(p, &args, &retval)) == 0)
+ if ((error = execve(p, &args, &retval[0])) == 0)
return;
if (error != ENOENT)
printf("exec %s: error %d\n", path, error);
diff --git a/sys/kern/init_sysent.c b/sys/kern/init_sysent.c
index c8b23f0..4173a45 100644
--- a/sys/kern/init_sysent.c
+++ b/sys/kern/init_sysent.c
@@ -2,11 +2,10 @@
* System call switch table.
*
* DO NOT EDIT-- this file is automatically generated.
- * created from $Id: syscalls.master,v 1.12 1994/12/14 17:57:23 wollman Exp $
+ * created from $Id: syscalls.master,v 1.13 1995/03/04 03:24:26 davidg Exp $
*/
#include <sys/param.h>
-#include <sys/systm.h>
#include <sys/sysent.h>
int nosys();
diff --git a/sys/kern/kern_clock.c b/sys/kern/kern_clock.c
index c1ff1bd..62d2bcb 100644
--- a/sys/kern/kern_clock.c
+++ b/sys/kern/kern_clock.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)kern_clock.c 8.5 (Berkeley) 1/21/94
- * $Id: kern_clock.c,v 1.10 1994/10/16 03:52:12 wollman Exp $
+ * $Id: kern_clock.c,v 1.11 1994/12/12 11:58:46 bde Exp $
*/
/* Portions of this software are covered by the following: */
@@ -415,8 +415,6 @@ hardclock(frame)
register struct callout *p1;
register struct proc *p;
register int needsoft;
- extern int tickdelta;
- extern long timedelta;
/*
* Update real-time timeout queue.
diff --git a/sys/kern/kern_exec.c b/sys/kern/kern_exec.c
index 4057384..2d1593a 100644
--- a/sys/kern/kern_exec.c
+++ b/sys/kern/kern_exec.c
@@ -28,7 +28,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: kern_exec.c,v 1.14 1995/03/01 04:09:50 davidg Exp $
+ * $Id: kern_exec.c,v 1.15 1995/03/10 08:44:20 davidg Exp $
*/
#include <sys/param.h>
@@ -60,7 +60,6 @@ static int exec_check_permissions(struct image_params *);
* execsw_set is constructed for us by the linker. Each of the items
* is a pointer to a `const struct execsw', hence the double pointer here.
*/
-extern const struct linker_set execsw_set;
const struct execsw **execsw = (const struct execsw **)&execsw_set.ls_items[0];
/*
diff --git a/sys/kern/kern_exit.c b/sys/kern/kern_exit.c
index e3cee98..3a8102c 100644
--- a/sys/kern/kern_exit.c
+++ b/sys/kern/kern_exit.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)kern_exit.c 8.7 (Berkeley) 2/12/94
- * $Id: kern_exit.c,v 1.12 1994/10/27 05:21:39 phk Exp $
+ * $Id: kern_exit.c,v 1.13 1994/12/28 06:15:07 davidg Exp $
*/
#include <sys/param.h>
@@ -281,16 +281,6 @@ done:
cpu_exit(p);
}
-struct wait_args {
- int pid;
- int *status;
- int options;
- struct rusage *rusage;
-#if defined(COMPAT_43) || defined(COMPAT_IBCS2)
- int compat; /* pseudo */
-#endif
-};
-
#if defined(COMPAT_43) || defined(COMPAT_IBCS2)
#if defined(hp300) || defined(luna68k)
#include <machine/frame.h>
diff --git a/sys/kern/kern_fork.c b/sys/kern/kern_fork.c
index 4f5a754..0e2ba90 100644
--- a/sys/kern/kern_fork.c
+++ b/sys/kern/kern_fork.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)kern_fork.c 8.6 (Berkeley) 4/8/94
- * $Id: kern_fork.c,v 1.9 1994/10/10 01:00:43 phk Exp $
+ * $Id: kern_fork.c,v 1.10 1995/01/21 15:08:57 bde Exp $
*/
#include <sys/param.h>
@@ -55,9 +55,6 @@
static int fork1(struct proc *, int, int *);
-struct fork_args {
- int dummy;
-};
/* ARGSUSED */
int
fork(p, uap, retval)
diff --git a/sys/kern/kern_lkm.c b/sys/kern/kern_lkm.c
index 61aac0e..b2e568c 100644
--- a/sys/kern/kern_lkm.c
+++ b/sys/kern/kern_lkm.c
@@ -496,7 +496,6 @@ _lkm_syscall(lkmtp, cmd)
struct lkm_syscall *args = lkmtp->private.lkm_syscall;
int i;
int err = 0;
- extern struct sysentvec aout_sysvec;
switch(cmd) {
case LKM_E_LOAD:
@@ -566,7 +565,6 @@ _lkm_vfs(lkmtp, cmd)
{
struct lkm_vfs *args = lkmtp->private.lkm_vfs;
struct vfsconf *vfc = args->lkm_vfsconf;
- extern struct vfsconf void_vfsconf;
int i;
int err = 0;
@@ -791,7 +789,6 @@ _lkm_exec(lkmtp, cmd)
struct lkm_exec *args = lkmtp->private.lkm_exec;
int i;
int err = 0;
- extern const struct linker_set execsw_set;
const struct execsw **execsw =
(const struct execsw **)&execsw_set.ls_items[0];
diff --git a/sys/kern/kern_physio.c b/sys/kern/kern_physio.c
index ad88ab6..f8f4db8 100644
--- a/sys/kern/kern_physio.c
+++ b/sys/kern/kern_physio.c
@@ -16,7 +16,7 @@
* 4. Modifications may be freely made to this file if the above conditions
* are met.
*
- * $Id: kern_physio.c,v 1.8 1994/09/25 19:33:40 phk Exp $
+ * $Id: kern_physio.c,v 1.9 1995/01/09 16:04:51 davidg Exp $
*/
#include <sys/param.h>
@@ -30,7 +30,7 @@ static void physwakeup();
int
physio(strategy, bp, dev, rw, minp, uio)
- int (*strategy)();
+ d_strategy_t *strategy;
struct buf *bp;
dev_t dev;
int rw;
diff --git a/sys/kern/kern_sig.c b/sys/kern/kern_sig.c
index 7a59349..08ff425 100644
--- a/sys/kern/kern_sig.c
+++ b/sys/kern/kern_sig.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)kern_sig.c 8.7 (Berkeley) 4/18/94
- * $Id: kern_sig.c,v 1.8 1994/11/06 11:13:02 ache Exp $
+ * $Id: kern_sig.c,v 1.9 1995/01/29 01:19:12 ats Exp $
*/
#define SIGPROP /* include signal properties table */
@@ -65,7 +65,6 @@
void setsigvec __P((struct proc *, int, struct sigaction *));
void stop __P((struct proc *));
-void sigexit __P((struct proc *, int));
/*
* Can process p, with pcred pc, send the signal signum to process q?
diff --git a/sys/kern/kern_synch.c b/sys/kern/kern_synch.c
index f3724ff..4c977c7 100644
--- a/sys/kern/kern_synch.c
+++ b/sys/kern/kern_synch.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)kern_synch.c 8.6 (Berkeley) 1/21/94
- * $Id: kern_synch.c,v 1.8 1994/10/18 06:55:39 davidg Exp $
+ * $Id: kern_synch.c,v 1.9 1994/12/12 06:04:27 davidg Exp $
*/
#include <sys/param.h>
@@ -57,6 +57,8 @@
u_char curpriority; /* usrpri of curproc */
int lbolt; /* once a second sleep address */
+void endtsleep __P((void *));
+
/*
* Force switch among equal priority processes every 100ms.
*/
@@ -287,8 +289,6 @@ tsleep(ident, priority, wmesg, timo)
register struct slpque *qp;
register s;
int sig, catch = priority & PCATCH;
- extern int cold;
- void endtsleep __P((void *));
#ifdef KTRACE
if (KTRPOINT(p, KTR_CSW))
@@ -415,7 +415,6 @@ sleep(ident, priority)
register struct proc *p = curproc;
register struct slpque *qp;
register s;
- extern int cold;
#ifdef DIAGNOSTIC
if (priority > PZERO) {
diff --git a/sys/kern/kern_sysctl.c b/sys/kern/kern_sysctl.c
index 6143930..8d0e95b 100644
--- a/sys/kern/kern_sysctl.c
+++ b/sys/kern/kern_sysctl.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)kern_sysctl.c 8.4 (Berkeley) 4/14/94
- * $Id: kern_sysctl.c,v 1.21 1994/12/28 06:15:08 davidg Exp $
+ * $Id: kern_sysctl.c,v 1.22 1995/02/20 19:42:35 guido Exp $
*/
/*
@@ -192,7 +192,6 @@ kern_sysctl(name, namelen, oldp, oldlenp, newp, newlen, p)
struct proc *p;
{
int error, level, inthostid;
- extern char ostype[], osrelease[];
/* all sysctl names at this level are terminal */
if (namelen != 1 && !(name[0] == KERN_PROC || name[0] == KERN_PROF
@@ -313,9 +312,6 @@ hw_sysctl(name, namelen, oldp, oldlenp, newp, newlen, p)
size_t newlen;
struct proc *p;
{
- extern char machine[], cpu_model[];
- extern int hw_float;
-
/* almost all sysctl names at this level are terminal */
if (namelen != 1 && name[0] != HW_DEVCONF)
return (ENOTDIR); /* overloaded */
diff --git a/sys/kern/kern_tc.c b/sys/kern/kern_tc.c
index c1ff1bd..62d2bcb 100644
--- a/sys/kern/kern_tc.c
+++ b/sys/kern/kern_tc.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)kern_clock.c 8.5 (Berkeley) 1/21/94
- * $Id: kern_clock.c,v 1.10 1994/10/16 03:52:12 wollman Exp $
+ * $Id: kern_clock.c,v 1.11 1994/12/12 11:58:46 bde Exp $
*/
/* Portions of this software are covered by the following: */
@@ -415,8 +415,6 @@ hardclock(frame)
register struct callout *p1;
register struct proc *p;
register int needsoft;
- extern int tickdelta;
- extern long timedelta;
/*
* Update real-time timeout queue.
diff --git a/sys/kern/kern_time.c b/sys/kern/kern_time.c
index 4249ca8..5ab24de 100644
--- a/sys/kern/kern_time.c
+++ b/sys/kern/kern_time.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)kern_time.c 8.1 (Berkeley) 6/10/93
- * $Id: kern_time.c,v 1.5 1994/10/02 17:35:20 phk Exp $
+ * $Id: kern_time.c,v 1.6 1995/02/14 06:33:53 phk Exp $
*/
#include <sys/param.h>
@@ -43,7 +43,6 @@
#include <sys/vnode.h>
#include <machine/cpu.h>
-#include <machine/clock.h>
/*
* Time of day and interval timer support.
diff --git a/sys/kern/kern_timeout.c b/sys/kern/kern_timeout.c
index c1ff1bd..62d2bcb 100644
--- a/sys/kern/kern_timeout.c
+++ b/sys/kern/kern_timeout.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)kern_clock.c 8.5 (Berkeley) 1/21/94
- * $Id: kern_clock.c,v 1.10 1994/10/16 03:52:12 wollman Exp $
+ * $Id: kern_clock.c,v 1.11 1994/12/12 11:58:46 bde Exp $
*/
/* Portions of this software are covered by the following: */
@@ -415,8 +415,6 @@ hardclock(frame)
register struct callout *p1;
register struct proc *p;
register int needsoft;
- extern int tickdelta;
- extern long timedelta;
/*
* Update real-time timeout queue.
diff --git a/sys/kern/makesyscalls.sh b/sys/kern/makesyscalls.sh
index a4875fb..abe49ba 100644
--- a/sys/kern/makesyscalls.sh
+++ b/sys/kern/makesyscalls.sh
@@ -1,6 +1,6 @@
#! /bin/sh -
# @(#)makesyscalls.sh 8.1 (Berkeley) 6/10/93
-# $Id: makesyscalls.sh,v 1.10 1994/11/06 21:57:16 ats Exp $
+# $Id: makesyscalls.sh,v 1.11 1995/02/14 19:22:29 sos Exp $
set -e
@@ -55,7 +55,6 @@ awk < $1 "
NR == 1 {
printf " * created from%s\n */\n\n", $0 > sysdcl
printf "#include <sys/param.h>\n" > sysdcl
- printf "#include <sys/systm.h>\n" > sysdcl
printf "#include <sys/sysent.h>\n\n" > sysdcl
printf "struct sysent sysent[] = {\n" > sysent
diff --git a/sys/kern/subr_prf.c b/sys/kern/subr_prf.c
index db533db..d9ed51d 100644
--- a/sys/kern/subr_prf.c
+++ b/sys/kern/subr_prf.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)subr_prf.c 8.3 (Berkeley) 1/21/94
- * $Id: subr_prf.c,v 1.9 1994/12/30 12:17:42 bde Exp $
+ * $Id: subr_prf.c,v 1.10 1995/02/19 15:02:26 bde Exp $
*/
#include <sys/param.h>
@@ -491,7 +491,6 @@ putchar(c, flags, tp)
int flags;
struct tty *tp;
{
- extern int msgbufmapped;
register struct msgbuf *mbp;
if (panicstr)
diff --git a/sys/kern/subr_prof.c b/sys/kern/subr_prof.c
index e0cdb2f..3c8ef38 100644
--- a/sys/kern/subr_prof.c
+++ b/sys/kern/subr_prof.c
@@ -31,14 +31,17 @@
* SUCH DAMAGE.
*
* @(#)subr_prof.c 8.3 (Berkeley) 9/23/93
- * $Id: subr_prof.c,v 1.4 1994/09/21 21:58:39 bde Exp $
+ * $Id: subr_prof.c,v 1.5 1995/01/29 03:03:23 bde Exp $
*/
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/kernel.h>
#include <sys/proc.h>
+#include <vm/vm.h>
+#include <sys/sysctl.h>
#include <sys/user.h>
+
#include <machine/cpu.h>
#ifdef GPROF
diff --git a/sys/kern/subr_rlist.c b/sys/kern/subr_rlist.c
index ed4a5a9..c64b685 100644
--- a/sys/kern/subr_rlist.c
+++ b/sys/kern/subr_rlist.c
@@ -54,7 +54,7 @@
* functioning of this software, nor does the author assume any responsibility
* for damages incurred with its use.
*
- * $Id: subr_rlist.c,v 1.7 1994/10/02 17:35:23 phk Exp $
+ * $Id: subr_rlist.c,v 1.8 1995/01/31 06:48:53 davidg Exp $
*/
#include <sys/param.h>
@@ -64,10 +64,9 @@
#include <sys/rlist.h>
#include <sys/proc.h>
#include <vm/vm.h>
+#include <vm/vm_kern.h>
#include <vm/vm_map.h>
-extern vm_map_t kernel_map;
-
/*
* Resource lists.
*/
@@ -83,7 +82,6 @@ rlist_malloc()
struct rlist *rl;
int i;
while( rlist_count < RLIST_MIN) {
- extern vm_map_t kmem_map;
int s = splhigh();
rl = (struct rlist *)kmem_malloc(kmem_map, NBPG, M_WAITOK);
splx(s);
diff --git a/sys/kern/subr_trap.c b/sys/kern/subr_trap.c
index f98022b..2e64edd 100644
--- a/sys/kern/subr_trap.c
+++ b/sys/kern/subr_trap.c
@@ -35,7 +35,7 @@
* SUCH DAMAGE.
*
* from: @(#)trap.c 7.4 (Berkeley) 5/13/91
- * $Id: trap.c,v 1.47 1995/02/10 06:43:47 davidg Exp $
+ * $Id: trap.c,v 1.48 1995/02/14 19:20:31 sos Exp $
*/
/*
@@ -56,10 +56,12 @@
#include <vm/vm_param.h>
#include <vm/pmap.h>
+#include <vm/vm_kern.h>
#include <vm/vm_map.h>
#include <vm/vm_page.h>
#include <machine/cpu.h>
+#include <machine/md_var.h>
#include <machine/psl.h>
#include <machine/reg.h>
#include <machine/trap.h>
@@ -302,8 +304,6 @@ trap(frame)
*/
#define MAYBE_DORETI_FAULT(where, whereto) \
do { \
- extern void where(void) __asm(__STRING(where)); \
- extern void whereto(void) __asm(__STRING(whereto)); \
if (frame.tf_eip == (int)where) { \
frame.tf_eip = (int)whereto; \
return; \
@@ -398,7 +398,6 @@ trap_pfault(frame, usermode)
vm_map_t map = 0;
int rv = 0;
vm_prot_t ftype;
- extern vm_map_t kernel_map;
int eva;
struct proc *p = curproc;
diff --git a/sys/kern/sys_process.c b/sys/kern/sys_process.c
index 3d20a83..5221a7f 100644
--- a/sys/kern/sys_process.c
+++ b/sys/kern/sys_process.c
@@ -28,7 +28,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: sys_process.c,v 1.10 1995/02/16 00:41:16 davidg Exp $
+ * $Id: sys_process.c,v 1.11 1995/02/19 02:50:31 davidg Exp $
*/
#include <sys/param.h>
@@ -304,7 +304,7 @@ ptrace(curp, uap, retval)
if (uap->addr != (caddr_t)1) {
fill_eproc (p, &p->p_addr->u_kproc.kp_eproc);
- if ((error = ptrace_set_pc (p, uap->addr)))
+ if ((error = ptrace_set_pc (p, (u_int)uap->addr)))
return error;
}
diff --git a/sys/kern/syscalls.c b/sys/kern/syscalls.c
index 7bccb13..2f1a468 100644
--- a/sys/kern/syscalls.c
+++ b/sys/kern/syscalls.c
@@ -2,7 +2,7 @@
* System call names.
*
* DO NOT EDIT-- this file is automatically generated.
- * created from $Id: syscalls.master,v 1.12 1994/12/14 17:57:23 wollman Exp $
+ * created from $Id: syscalls.master,v 1.13 1995/03/04 03:24:26 davidg Exp $
*/
char *syscallnames[] = {
diff --git a/sys/kern/tty.c b/sys/kern/tty.c
index 9edf66a..ffef354 100644
--- a/sys/kern/tty.c
+++ b/sys/kern/tty.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)tty.c 8.8 (Berkeley) 1/21/94
- * $Id: tty.c,v 1.34 1995/02/28 00:21:03 pst Exp $
+ * $Id: tty.c,v 1.35 1995/02/28 23:20:11 ache Exp $
*/
#include "snp.h"
@@ -195,7 +195,6 @@ int
ttyclose(tp)
register struct tty *tp;
{
- extern struct tty *constty; /* Temporary virtual console. */
int s;
s = spltty();
@@ -662,8 +661,6 @@ ttioctl(tp, cmd, data, flag)
int cmd, flag;
void *data;
{
- extern struct tty *constty; /* Temporary virtual console. */
- extern int nlinesw;
register struct proc *p;
int s, error;
diff --git a/sys/kern/uipc_syscalls.c b/sys/kern/uipc_syscalls.c
index e2ad45a..d9a44e5 100644
--- a/sys/kern/uipc_syscalls.c
+++ b/sys/kern/uipc_syscalls.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)uipc_syscalls.c 8.4 (Berkeley) 2/21/94
- * $Id: uipc_syscalls.c,v 1.3 1994/08/02 07:43:10 davidg Exp $
+ * $Id: uipc_syscalls.c,v 1.4 1994/10/02 17:35:35 phk Exp $
*/
#include <sys/param.h>
@@ -47,6 +47,7 @@
#include <sys/socket.h>
#include <sys/socketvar.h>
#include <sys/signalvar.h>
+#include <sys/un.h>
#ifdef KTRACE
#include <sys/ktrace.h>
#endif
diff --git a/sys/kern/vfs_bio.c b/sys/kern/vfs_bio.c
index 5fb391a..5b7bc76 100644
--- a/sys/kern/vfs_bio.c
+++ b/sys/kern/vfs_bio.c
@@ -18,7 +18,7 @@
* 5. Modifications may be freely made to this file if the above conditions
* are met.
*
- * $Id: vfs_bio.c,v 1.34 1995/03/04 15:16:07 davidg Exp $
+ * $Id: vfs_bio.c,v 1.35 1995/03/07 19:53:27 davidg Exp $
*/
/*
@@ -39,6 +39,7 @@
#include <sys/proc.h>
#include <sys/vnode.h>
#include <vm/vm.h>
+#include <vm/vm_kern.h>
#include <vm/vm_pageout.h>
#include <vm/vm_page.h>
#include <vm/vm_object.h>
@@ -55,12 +56,9 @@ int nbuf; /* number of buffer headers calculated
* elsewhere */
struct swqueue bswlist;
-extern vm_map_t buffer_map, io_map, kernel_map, pager_map;
-
void vm_hold_free_pages(struct buf * bp, vm_offset_t from, vm_offset_t to);
void vm_hold_load_pages(struct buf * bp, vm_offset_t from, vm_offset_t to);
void vfs_dirty_pages(struct buf * bp);
-void vfs_busy_pages(struct buf *, int clear_modify);
int needsbuffer;
diff --git a/sys/kern/vfs_cluster.c b/sys/kern/vfs_cluster.c
index 881605d..39eab49 100644
--- a/sys/kern/vfs_cluster.c
+++ b/sys/kern/vfs_cluster.c
@@ -33,7 +33,7 @@
* SUCH DAMAGE.
*
* @(#)vfs_cluster.c 8.7 (Berkeley) 2/13/94
- * $Id: vfs_cluster.c,v 1.11 1995/03/02 19:36:50 davidg Exp $
+ * $Id: vfs_cluster.c,v 1.12 1995/03/04 03:24:28 davidg Exp $
*/
#include <sys/param.h>
@@ -65,7 +65,6 @@ struct ctldebug debug13 = {"doreallocblks", &doreallocblks};
*/
struct buf *cluster_rbuild __P((struct vnode *, u_quad_t, struct buf *,
daddr_t, daddr_t, long, int, long));
-void cluster_wbuild __P((struct vnode *, struct buf *, long, daddr_t, int, daddr_t));
struct cluster_save *cluster_collectbufs __P((struct vnode *, struct buf *));
int totreads;
@@ -508,7 +507,7 @@ redo:
--len;
}
- pb = (struct buf *) trypbuf();
+ pb = trypbuf();
/* Get more memory for current buffer */
if (len <= 1 || pb == 0) {
relpbuf(pb);
@@ -528,7 +527,7 @@ redo:
}
tbp->b_flags |= B_BUSY;
last_bp = 0;
- pb = (struct buf *) trypbuf();
+ pb = trypbuf();
if( pb == 0) {
bawrite(tbp);
return;
diff --git a/sys/kern/vfs_export.c b/sys/kern/vfs_export.c
index c46ec68..7be57e9 100644
--- a/sys/kern/vfs_export.c
+++ b/sys/kern/vfs_export.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)vfs_subr.c 8.13 (Berkeley) 4/18/94
- * $Id: vfs_subr.c,v 1.21 1995/03/10 21:18:24 davidg Exp $
+ * $Id: vfs_subr.c,v 1.22 1995/03/11 22:29:07 davidg Exp $
*/
/*
@@ -96,8 +96,6 @@ int desiredvnodes;
void
vntblinit()
{
- extern int vm_object_cache_max;
-
desiredvnodes = maxproc + vm_object_cache_max;
TAILQ_INIT(&vnode_free_list);
diff --git a/sys/kern/vfs_extattr.c b/sys/kern/vfs_extattr.c
index eef1fce..0596362 100644
--- a/sys/kern/vfs_extattr.c
+++ b/sys/kern/vfs_extattr.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)vfs_syscalls.c 8.13 (Berkeley) 4/15/94
- * $Id: vfs_syscalls.c,v 1.17 1995/02/13 13:45:04 davidg Exp $
+ * $Id: vfs_syscalls.c,v 1.18 1995/02/28 02:52:48 davidg Exp $
*/
#include <sys/param.h>
@@ -53,6 +53,10 @@
#include <sys/malloc.h>
#include <sys/dirent.h>
+#ifdef UNION
+#include <miscfs/union/union.h>
+#endif
+
#include <vm/vm.h>
#include <sys/sysctl.h>
@@ -308,9 +312,6 @@ int syncprt = 0;
struct ctldebug debug0 = { "syncprt", &syncprt };
#endif
-struct sync_args {
- int dummy;
-};
/* ARGSUSED */
int
sync(p, uap, retval)
@@ -622,7 +623,6 @@ open(p, uap, retval)
int type, indx, error;
struct flock lf;
struct nameidata nd;
- extern struct fileops vnops;
error = falloc(p, &nfp, &indx);
if (error)
@@ -2126,9 +2126,6 @@ unionread:
#ifdef UNION
{
- extern int (**union_vnodeop_p)();
- extern struct vnode *union_lowervp __P((struct vnode *));
-
if ((uap->count == auio.uio_resid) &&
(vp->v_op == union_vnodeop_p)) {
struct vnode *tvp = vp;
diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c
index c46ec68..7be57e9 100644
--- a/sys/kern/vfs_subr.c
+++ b/sys/kern/vfs_subr.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)vfs_subr.c 8.13 (Berkeley) 4/18/94
- * $Id: vfs_subr.c,v 1.21 1995/03/10 21:18:24 davidg Exp $
+ * $Id: vfs_subr.c,v 1.22 1995/03/11 22:29:07 davidg Exp $
*/
/*
@@ -96,8 +96,6 @@ int desiredvnodes;
void
vntblinit()
{
- extern int vm_object_cache_max;
-
desiredvnodes = maxproc + vm_object_cache_max;
TAILQ_INIT(&vnode_free_list);
diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c
index eef1fce..0596362 100644
--- a/sys/kern/vfs_syscalls.c
+++ b/sys/kern/vfs_syscalls.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)vfs_syscalls.c 8.13 (Berkeley) 4/15/94
- * $Id: vfs_syscalls.c,v 1.17 1995/02/13 13:45:04 davidg Exp $
+ * $Id: vfs_syscalls.c,v 1.18 1995/02/28 02:52:48 davidg Exp $
*/
#include <sys/param.h>
@@ -53,6 +53,10 @@
#include <sys/malloc.h>
#include <sys/dirent.h>
+#ifdef UNION
+#include <miscfs/union/union.h>
+#endif
+
#include <vm/vm.h>
#include <sys/sysctl.h>
@@ -308,9 +312,6 @@ int syncprt = 0;
struct ctldebug debug0 = { "syncprt", &syncprt };
#endif
-struct sync_args {
- int dummy;
-};
/* ARGSUSED */
int
sync(p, uap, retval)
@@ -622,7 +623,6 @@ open(p, uap, retval)
int type, indx, error;
struct flock lf;
struct nameidata nd;
- extern struct fileops vnops;
error = falloc(p, &nfp, &indx);
if (error)
@@ -2126,9 +2126,6 @@ unionread:
#ifdef UNION
{
- extern int (**union_vnodeop_p)();
- extern struct vnode *union_lowervp __P((struct vnode *));
-
if ((uap->count == auio.uio_resid) &&
(vp->v_op == union_vnodeop_p)) {
struct vnode *tvp = vp;
diff --git a/sys/libkern/libkern.h b/sys/libkern/libkern.h
index c53fcb3..e32f72d 100644
--- a/sys/libkern/libkern.h
+++ b/sys/libkern/libkern.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)libkern.h 8.1 (Berkeley) 6/10/93
- * $Id: libkern.h,v 1.4 1994/09/18 23:04:25 bde Exp $
+ * $Id: libkern.h,v 1.5 1994/11/14 14:56:46 bde Exp $
*/
#include <sys/types.h>
@@ -58,6 +58,8 @@ char *rindex __P((const char *, int));
int scanc __P((u_int, u_char *, u_char *, int));
int skpc __P((int, int, char *));
char *strcat __P((char *, const char *));
+int strcmp __P((const char *, const char *));
char *strcpy __P((char *, const char *));
size_t strlen __P((const char *));
+int strncmp __P((const char *, const char *, size_t));
char *strncpy __P((char *, const char *, size_t));
diff --git a/sys/miscfs/fdesc/fdesc_vfsops.c b/sys/miscfs/fdesc/fdesc_vfsops.c
index d82f14d..e44c045 100644
--- a/sys/miscfs/fdesc/fdesc_vfsops.c
+++ b/sys/miscfs/fdesc/fdesc_vfsops.c
@@ -35,7 +35,7 @@
*
* @(#)fdesc_vfsops.c 8.4 (Berkeley) 1/21/94
*
- * $Id: fdesc_vfsops.c,v 1.1.1.1 1994/05/24 10:04:59 rgrimes Exp $
+ * $Id: fdesc_vfsops.c,v 1.2 1994/09/21 03:46:55 wollman Exp $
*/
/*
@@ -116,7 +116,6 @@ fdesc_unmount(mp, mntflags, p)
{
int error;
int flags = 0;
- extern int doforce;
struct vnode *rootvp = VFSTOFDESC(mp)->f_root;
if (mntflags & MNT_FORCE) {
diff --git a/sys/miscfs/fifofs/fifo.h b/sys/miscfs/fifofs/fifo.h
index 384b6c2..3f2d8ef 100644
--- a/sys/miscfs/fifofs/fifo.h
+++ b/sys/miscfs/fifofs/fifo.h
@@ -31,9 +31,11 @@
* SUCH DAMAGE.
*
* @(#)fifo.h 8.2 (Berkeley) 2/2/94
- * $Id: fifo.h,v 1.3 1994/09/22 19:38:05 wollman Exp $
+ * $Id: fifo.h,v 1.4 1995/02/14 06:30:18 phk Exp $
*/
+extern int (**fifo_vnodeop_p)();
+
/*
* Prototypes for fifo operations on vnodes.
*/
diff --git a/sys/miscfs/fifofs/fifo_vnops.c b/sys/miscfs/fifofs/fifo_vnops.c
index 78f6201..bf1ec82 100644
--- a/sys/miscfs/fifofs/fifo_vnops.c
+++ b/sys/miscfs/fifofs/fifo_vnops.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)fifo_vnops.c 8.2 (Berkeley) 1/4/94
- * $Id: fifo_vnops.c,v 1.6 1994/10/02 17:48:00 phk Exp $
+ * $Id: fifo_vnops.c,v 1.7 1995/02/03 06:46:13 davidg Exp $
*/
#include <sys/param.h>
@@ -48,6 +48,7 @@
#include <sys/file.h>
#include <sys/errno.h>
#include <sys/malloc.h>
+#include <sys/un.h>
#include <miscfs/fifofs/fifo.h>
/*
diff --git a/sys/miscfs/kernfs/kernfs_vfsops.c b/sys/miscfs/kernfs/kernfs_vfsops.c
index eee76e7..e59d295 100644
--- a/sys/miscfs/kernfs/kernfs_vfsops.c
+++ b/sys/miscfs/kernfs/kernfs_vfsops.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)kernfs_vfsops.c 8.4 (Berkeley) 1/21/94
- * $Id: kernfs_vfsops.c,v 1.5 1994/09/22 19:38:11 wollman Exp $
+ * $Id: kernfs_vfsops.c,v 1.6 1994/10/02 17:48:08 phk Exp $
*/
/*
@@ -183,7 +183,6 @@ kernfs_unmount(mp, mntflags, p)
{
int error;
int flags = 0;
- extern int doforce;
struct vnode *rootvp = VFSTOKERNFS(mp)->kf_root;
#ifdef KERNFS_DIAGNOSTIC
diff --git a/sys/miscfs/nullfs/null_vfsops.c b/sys/miscfs/nullfs/null_vfsops.c
index 4e13fb2..f7656c4 100644
--- a/sys/miscfs/nullfs/null_vfsops.c
+++ b/sys/miscfs/nullfs/null_vfsops.c
@@ -36,7 +36,7 @@
* @(#)null_vfsops.c 8.2 (Berkeley) 1/21/94
*
* @(#)lofs_vfsops.c 1.2 (Berkeley) 6/18/92
- * $Id: null_vfsops.c,v 1.3 1994/09/22 19:38:14 wollman Exp $
+ * $Id: null_vfsops.c,v 1.4 1994/10/10 07:55:28 phk Exp $
*/
/*
@@ -186,7 +186,6 @@ nullfs_unmount(mp, mntflags, p)
struct vnode *nullm_rootvp = MOUNTTONULLMOUNT(mp)->nullm_rootvp;
int error;
int flags = 0;
- extern int doforce;
#ifdef NULLFS_DIAGNOSTIC
printf("nullfs_unmount(mp = %x)\n", mp);
diff --git a/sys/miscfs/portal/portal_vfsops.c b/sys/miscfs/portal/portal_vfsops.c
index 39d54c2..cad30bd 100644
--- a/sys/miscfs/portal/portal_vfsops.c
+++ b/sys/miscfs/portal/portal_vfsops.c
@@ -35,7 +35,7 @@
*
* @(#)portal_vfsops.c 8.6 (Berkeley) 1/21/94
*
- * $Id: portal_vfsops.c,v 1.4 1994/09/23 11:01:58 davidg Exp $
+ * $Id: portal_vfsops.c,v 1.5 1994/10/10 07:55:35 phk Exp $
*/
/*
@@ -155,7 +155,6 @@ portal_unmount(mp, mntflags, p)
int mntflags;
struct proc *p;
{
- extern int doforce;
struct vnode *rootvp = VFSTOPORTAL(mp)->pm_root;
int error, flags = 0;
diff --git a/sys/miscfs/procfs/procfs.h b/sys/miscfs/procfs/procfs.h
index 7a1bbb8..79a77da 100644
--- a/sys/miscfs/procfs/procfs.h
+++ b/sys/miscfs/procfs/procfs.h
@@ -36,7 +36,7 @@
*
* @(#)procfs.h 8.6 (Berkeley) 2/3/94
*
- * $Id: procfs.h,v 1.1.1.1 1994/05/24 10:05:07 rgrimes Exp $
+ * $Id: procfs.h,v 1.2 1994/08/02 07:45:08 davidg Exp $
*/
/*
@@ -139,6 +139,8 @@ extern int procfs_dostatus __P((struct proc *, struct proc *, struct pfsnode *pf
extern int (**procfs_vnodeop_p)();
extern struct vfsops procfs_vfsops;
+int procfs_root __P((struct mount *, struct vnode **));
+
/*
* Prototypes for procfs vnode ops
*/
diff --git a/sys/miscfs/procfs/procfs_ctl.c b/sys/miscfs/procfs/procfs_ctl.c
index 5902efd..5befe23 100644
--- a/sys/miscfs/procfs/procfs_ctl.c
+++ b/sys/miscfs/procfs/procfs_ctl.c
@@ -36,7 +36,7 @@
*
* @(#)procfs_ctl.c 8.3 (Berkeley) 1/21/94
*
- * $Id: procfs_ctl.c,v 1.3 1994/12/31 12:26:50 ache Exp $
+ * $Id: procfs_ctl.c,v 1.4 1995/02/20 15:53:32 davidg Exp $
*/
#include <sys/param.h>
@@ -47,10 +47,15 @@
#include <sys/vnode.h>
#include <sys/ioctl.h>
#include <sys/tty.h>
+#include <sys/ptrace.h>
#include <sys/resource.h>
#include <sys/resourcevar.h>
+#include <sys/signal.h>
+#include <sys/signalvar.h>
+
+#include <vm/vm.h>
+
#include <miscfs/procfs/procfs.h>
-#include <sys/signal.h> /* for sigmask() */
/*
* True iff process (p) is in trace wait state
diff --git a/sys/miscfs/procfs/procfs_vfsops.c b/sys/miscfs/procfs/procfs_vfsops.c
index e54d012..4379d0a 100644
--- a/sys/miscfs/procfs/procfs_vfsops.c
+++ b/sys/miscfs/procfs/procfs_vfsops.c
@@ -36,7 +36,7 @@
*
* @(#)procfs_vfsops.c 8.4 (Berkeley) 1/21/94
*
- * $Id: procfs_vfsops.c,v 1.6 1994/10/10 07:55:39 phk Exp $
+ * $Id: procfs_vfsops.c,v 1.7 1995/02/20 15:53:33 davidg Exp $
*/
/*
@@ -104,7 +104,6 @@ procfs_unmount(mp, mntflags, p)
struct proc *p;
{
int error;
- extern int doforce;
int flags = 0;
if (mntflags & MNT_FORCE) {
diff --git a/sys/miscfs/umapfs/umap_vfsops.c b/sys/miscfs/umapfs/umap_vfsops.c
index e0baf46..0eeab20 100644
--- a/sys/miscfs/umapfs/umap_vfsops.c
+++ b/sys/miscfs/umapfs/umap_vfsops.c
@@ -35,7 +35,7 @@
*
* @(#)umap_vfsops.c 8.3 (Berkeley) 1/21/94
*
- * $Id: umap_vfsops.c,v 1.4 1994/09/22 19:38:19 wollman Exp $
+ * $Id: umap_vfsops.c,v 1.5 1994/10/10 07:55:43 phk Exp $
*/
/*
@@ -227,7 +227,6 @@ umapfs_unmount(mp, mntflags, p)
struct vnode *umapm_rootvp = MOUNTTOUMAPMOUNT(mp)->umapm_rootvp;
int error;
int flags = 0;
- extern int doforce;
#ifdef UMAPFS_DIAGNOSTIC
printf("umapfs_unmount(mp = %x)\n", mp);
diff --git a/sys/miscfs/union/union.h b/sys/miscfs/union/union.h
index b66e17c..05fa481 100644
--- a/sys/miscfs/union/union.h
+++ b/sys/miscfs/union/union.h
@@ -35,7 +35,7 @@
* SUCH DAMAGE.
*
* @(#)union.h 8.2 (Berkeley) 2/17/94
- * $Id$
+ * $Id: union.h,v 1.2 1994/08/02 07:45:42 davidg Exp $
*/
struct union_args {
@@ -93,12 +93,15 @@ extern int union_allocvp __P((struct vnode **, struct mount *,
struct vnode *, struct vnode *,
struct componentname *, struct vnode *,
struct vnode *));
+extern int union_freevp __P((struct vnode *));
extern int union_copyfile __P((struct proc *, struct ucred *,
struct vnode *, struct vnode *));
extern int union_mkshadow __P((struct union_mount *, struct vnode *,
struct componentname *, struct vnode **));
extern int union_vn_create __P((struct vnode **, struct union_node *,
struct proc *));
+extern int union_vn_close __P((struct vnode *, int, struct ucred *,
+ struct proc *));
extern int union_cn_close __P((struct vnode *, int, struct ucred *,
struct proc *));
extern void union_removed_upper __P((struct union_node *un));
diff --git a/sys/miscfs/union/union_vfsops.c b/sys/miscfs/union/union_vfsops.c
index 393fe9d..4000f98 100644
--- a/sys/miscfs/union/union_vfsops.c
+++ b/sys/miscfs/union/union_vfsops.c
@@ -35,7 +35,7 @@
* SUCH DAMAGE.
*
* @(#)union_vfsops.c 8.7 (Berkeley) 3/5/94
- * $Id: union_vfsops.c,v 1.6 1994/10/10 07:55:47 phk Exp $
+ * $Id: union_vfsops.c,v 1.7 1994/11/04 14:41:43 davidg Exp $
*/
/*
@@ -56,6 +56,9 @@
#include <sys/queue.h>
#include <miscfs/union/union.h>
+int union_root __P((struct mount *, struct vnode **));
+int union_statfs __P((struct mount *, struct statfs *, struct proc *));
+
/*
* Mount union filesystem
*/
@@ -303,7 +306,6 @@ union_unmount(mp, mntflags, p)
struct vnode *um_rootvp;
int error;
int flags = 0;
- extern int doforce;
#ifdef UNION_DIAGNOSTIC
printf("union_unmount(mp = %x)\n", mp);
diff --git a/sys/msdosfs/denode.h b/sys/msdosfs/denode.h
index a45994b..b47196a 100644
--- a/sys/msdosfs/denode.h
+++ b/sys/msdosfs/denode.h
@@ -1,4 +1,4 @@
-/* $Id: denode.h,v 1.2 1994/12/12 12:35:40 bde Exp $ */
+/* $Id: denode.h,v 1.3 1994/12/27 12:37:33 bde Exp $ */
/* $NetBSD: denode.h,v 1.8 1994/08/21 18:43:49 ws Exp $ */
/*-
@@ -225,6 +225,8 @@ struct defid {
/* u_long defid_gen; generation number */
};
+extern int (**msdosfs_vnodeop_p)();
+
/*
* Prototypes for MSDOSFS vnode operations
*/
diff --git a/sys/msdosfs/msdosfs_denode.c b/sys/msdosfs/msdosfs_denode.c
index 2e03af6..1d08e42 100644
--- a/sys/msdosfs/msdosfs_denode.c
+++ b/sys/msdosfs/msdosfs_denode.c
@@ -1,4 +1,4 @@
-/* $Id: msdosfs_denode.c,v 1.7 1995/01/09 16:04:59 davidg Exp $ */
+/* $Id: msdosfs_denode.c,v 1.8 1995/01/29 01:27:58 ats Exp $ */
/* $NetBSD: msdosfs_denode.c,v 1.9 1994/08/21 18:44:00 ws Exp $ */
/*-
@@ -168,7 +168,6 @@ deget(pmp, dirclust, diroffset, direntptr, depp)
int error;
dev_t dev = pmp->pm_dev;
struct mount *mntp = pmp->pm_mountp;
- extern int (**msdosfs_vnodeop_p)();
struct denode *ldep;
struct vnode *nvp;
struct buf *bp;
@@ -614,7 +613,6 @@ msdosfs_reclaim(ap)
{
struct vnode *vp = ap->a_vp;
struct denode *dep = VTODE(vp);
- extern int prtactive;
#ifdef MSDOSFS_DEBUG
printf("msdosfs_reclaim(): dep %p, file %s, refcnt %ld\n",
@@ -655,7 +653,6 @@ msdosfs_inactive(ap)
struct vnode *vp = ap->a_vp;
struct denode *dep = VTODE(vp);
int error = 0;
- extern int prtactive;
struct timespec ts;
#ifdef MSDOSFS_DEBUG
diff --git a/sys/net/if.h b/sys/net/if.h
index 6d733b1..56a292d 100644
--- a/sys/net/if.h
+++ b/sys/net/if.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)if.h 8.1 (Berkeley) 6/10/93
- * $Id: if.h,v 1.14 1994/12/22 07:20:03 davidg Exp $
+ * $Id: if.h,v 1.15 1994/12/30 06:46:21 davidg Exp $
*/
#ifndef _NET_IF_H_
@@ -350,6 +350,7 @@ struct ifconf {
(ifa)->ifa_refcnt--;
extern struct ifnet *ifnet;
+extern struct ifnet loif;
void ether_ifattach __P((struct ifnet *));
void ether_input __P((struct ifnet *, struct ether_header *, struct mbuf *));
diff --git a/sys/net/if_ethersubr.c b/sys/net/if_ethersubr.c
index 978557b..1fce9d4 100644
--- a/sys/net/if_ethersubr.c
+++ b/sys/net/if_ethersubr.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)if_ethersubr.c 8.1 (Berkeley) 6/10/93
- * $Id: if_ethersubr.c,v 1.4 1994/11/24 14:29:38 davidg Exp $
+ * $Id: if_ethersubr.c,v 1.5 1994/12/13 22:31:45 wollman Exp $
*/
#include <sys/param.h>
@@ -82,7 +82,6 @@ extern struct ifqueue pkintrq;
#endif
u_char etherbroadcastaddr[6] = { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff };
-extern struct ifnet loif;
#define senderr(e) { error = (e); goto bad;}
/*
diff --git a/sys/net/if_fddisubr.c b/sys/net/if_fddisubr.c
index 9442b88..430dc6e 100644
--- a/sys/net/if_fddisubr.c
+++ b/sys/net/if_fddisubr.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* from: if_ethersubr.c,v 1.5 1994/12/13 22:31:45 wollman Exp
- * $Id$
+ * $Id: if_fddisubr.c,v 1.2 1995/03/14 22:15:36 davidg Exp $
*/
#include <sys/param.h>
@@ -88,7 +88,6 @@
extern struct ifqueue pkintrq;
#endif
-extern struct ifnet loif;
#define senderr(e) { error = (e); goto bad;}
/*
diff --git a/sys/net/if_sl.c b/sys/net/if_sl.c
index 323d52c..6a92ff5 100644
--- a/sys/net/if_sl.c
+++ b/sys/net/if_sl.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)if_sl.c 8.6 (Berkeley) 2/1/94
- * $Id: if_sl.c,v 1.11 1994/11/27 15:29:57 bde Exp $
+ * $Id: if_sl.c,v 1.12 1995/02/13 02:09:14 ache Exp $
*/
/*
@@ -80,6 +80,7 @@
#include <sys/ioctl.h>
#include <sys/file.h>
#include <sys/tty.h>
+#include <sys/clist.h>
#include <sys/kernel.h>
#include <sys/conf.h>
@@ -439,7 +440,6 @@ slstart(tp)
u_char bpfbuf[SLTMAX + SLIP_HDRLEN];
register int len = 0;
#endif
- extern int cfreecount;
for (;;) {
/*
diff --git a/sys/net/if_tun.c b/sys/net/if_tun.c
index 413d1e9..97a56da 100644
--- a/sys/net/if_tun.c
+++ b/sys/net/if_tun.c
@@ -29,6 +29,7 @@
#include <sys/syslog.h>
#include <sys/select.h>
#include <sys/file.h>
+#include <sys/signalvar.h>
#ifdef __FreeBSD__
#include <sys/kernel.h>
#endif
diff --git a/sys/net/radix.h b/sys/net/radix.h
index b389596..9d44941 100644
--- a/sys/net/radix.h
+++ b/sys/net/radix.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)radix.h 8.1 (Berkeley) 6/10/93
- * $Id: radix.h,v 1.4 1994/11/02 04:41:23 wollman Exp $
+ * $Id: radix.h,v 1.5 1994/11/14 14:06:06 bde Exp $
*/
#ifndef _NET_RADIX_H_
@@ -125,7 +125,6 @@ struct radix_node_head {
struct radix_node rnh_nodes[3]; /* empty tree for common case */
};
-
#ifndef KERNEL
#define Bcmp(a, b, n) bcmp(((char *)(a)), ((char *)(b)), (n))
#define Bzero(p, n) bzero((char *)(p), (int)(n));
@@ -138,6 +137,8 @@ struct radix_node_head {
#define R_Malloc(p, t, n) (p = (t) malloc((unsigned long)(n), M_RTABLE, M_DONTWAIT))
#define Free(p) free((caddr_t)p, M_RTABLE);
+extern struct radix_node_head *mask_rnhead;
+
void rn_init __P((void));
int rn_inithead __P((void **, int));
int rn_refines __P((void *, void *));
diff --git a/sys/net/route.c b/sys/net/route.c
index 6c01a92..510a085 100644
--- a/sys/net/route.c
+++ b/sys/net/route.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)route.c 8.2 (Berkeley) 11/15/93
- * $Id: route.c,v 1.14 1995/01/23 02:00:34 wollman Exp $
+ * $Id: route.c,v 1.15 1995/01/23 17:53:21 davidg Exp $
*/
#include <sys/param.h>
@@ -51,6 +51,7 @@
#include <netinet/in.h>
#include <netinet/in_var.h>
+#include <netinet/ip_mroute.h>
#ifdef NS
#include <netns/ns.h>
@@ -293,7 +294,6 @@ rtioctl(req, data, p)
struct proc *p;
{
#ifdef INET
- extern int (*mrt_ioctl)(int, caddr_t, struct proc *);
/* Multicast goop, grrr... */
return mrt_ioctl(req, data, p);
#else /* INET */
diff --git a/sys/net/rtsock.c b/sys/net/rtsock.c
index d73604e..7c5056f 100644
--- a/sys/net/rtsock.c
+++ b/sys/net/rtsock.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)rtsock.c 8.3 (Berkeley) 1/4/94
- * $Id: rtsock.c,v 1.7 1994/10/11 23:16:29 wollman Exp $
+ * $Id: rtsock.c,v 1.8 1994/12/13 22:31:49 wollman Exp $
*/
#include <sys/param.h>
@@ -201,7 +201,6 @@ route_output(m, so)
senderr(ESRCH);
if (rtm->rtm_type != RTM_GET) {/* XXX: too grotty */
struct radix_node *rn;
- extern struct radix_node_head *mask_rnhead;
if (Bcmp(dst, rt_key(rt), dst->sa_len) != 0)
senderr(ESRCH);
diff --git a/sys/netccitt/pk_var.h b/sys/netccitt/pk_var.h
index 1690d2a..2e58dd1 100644
--- a/sys/netccitt/pk_var.h
+++ b/sys/netccitt/pk_var.h
@@ -39,7 +39,7 @@
* SUCH DAMAGE.
*
* @(#)pk_var.h 8.1 (Berkeley) 6/10/93
- * $Id: pk_var.h,v 1.2 1994/08/02 07:47:48 davidg Exp $
+ * $Id: pk_var.h,v 1.3 1994/08/21 05:44:10 paul Exp $
*/
#ifndef _NETCCITT_PK_VAR_H_
@@ -228,6 +228,7 @@ struct mbuf_cache {
#if defined(KERNEL) && defined(CCITT)
extern struct pkcb_q pkcb_q;
struct pklcd *pk_listenhead;
+void ccittintr __P((void));
struct pklcd *pk_attach();
extern char *pk_name[], *pk_state[];
diff --git a/sys/netinet/if_ether.c b/sys/netinet/if_ether.c
index 9517a3c..ceb8ee7 100644
--- a/sys/netinet/if_ether.c
+++ b/sys/netinet/if_ether.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)if_ether.c 8.1 (Berkeley) 6/10/93
- * $Id: if_ether.c,v 1.11 1995/02/20 15:48:40 davidg Exp $
+ * $Id: if_ether.c,v 1.12 1995/03/16 17:32:26 wollman Exp $
*/
/*
@@ -84,7 +84,6 @@ static void arptimer __P((void *));
static struct llinfo_arp *arplookup __P((u_long, int, int));
static void in_arpinput __P((struct mbuf *));
-extern struct ifnet loif;
struct llinfo_arp llinfo_arp = {&llinfo_arp, &llinfo_arp};
struct ifqueue arpintrq = {0, 0, 0, 50};
int arp_inuse, arp_allocated, arp_intimer;
diff --git a/sys/netinet/igmp.c b/sys/netinet/igmp.c
index 9c55d8c..361fe4d 100644
--- a/sys/netinet/igmp.c
+++ b/sys/netinet/igmp.c
@@ -35,7 +35,7 @@
* SUCH DAMAGE.
*
* @(#)igmp.c 8.1 (Berkeley) 7/19/93
- * $Id: igmp.c,v 1.6 1994/10/31 06:36:47 pst Exp $
+ * $Id: igmp.c,v 1.7 1995/02/16 00:27:41 wollman Exp $
*/
/*
@@ -67,8 +67,6 @@
#include <netinet/igmp.h>
#include <netinet/igmp_var.h>
-extern struct ifnet loif;
-
struct igmpstat igmpstat;
static int igmp_timers_are_running = 0;
diff --git a/sys/netinet/in.c b/sys/netinet/in.c
index c36b0fe..495dcff 100644
--- a/sys/netinet/in.c
+++ b/sys/netinet/in.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)in.c 8.2 (Berkeley) 11/15/93
- * $Id: in.c,v 1.8 1994/12/22 21:56:22 wollman Exp $
+ * $Id: in.c,v 1.9 1995/02/14 06:28:25 phk Exp $
*/
#include <sys/param.h>
@@ -154,7 +154,6 @@ struct sockaddr_in *ap;
}
int in_interfaces; /* number of external internet interfaces */
-extern struct ifnet loif;
/*
* Generic internet control operations (ioctl's).
diff --git a/sys/netinet/in_pcb.c b/sys/netinet/in_pcb.c
index 25eb0aa..62ea84c 100644
--- a/sys/netinet/in_pcb.c
+++ b/sys/netinet/in_pcb.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)in_pcb.c 8.2 (Berkeley) 1/4/94
- * $Id: in_pcb.c,v 1.6 1995/03/02 19:29:42 davidg Exp $
+ * $Id: in_pcb.c,v 1.7 1995/03/14 21:50:55 davidg Exp $
*/
#include <sys/param.h>
@@ -392,7 +392,6 @@ in_pcbnotify(head, dst, fport_arg, laddr, lport_arg, cmd, notify)
int cmd;
void (*notify) __P((struct inpcb *, int));
{
- extern u_char inetctlerrmap[];
register struct inpcb *inp, *oinp;
struct in_addr faddr;
u_short fport = fport_arg, lport = lport_arg;
diff --git a/sys/netinet/in_pcb.h b/sys/netinet/in_pcb.h
index ff4c71b..9946f12 100644
--- a/sys/netinet/in_pcb.h
+++ b/sys/netinet/in_pcb.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)in_pcb.h 8.1 (Berkeley) 6/10/93
- * $Id: in_pcb.h,v 1.3 1994/08/02 07:48:20 davidg Exp $
+ * $Id: in_pcb.h,v 1.4 1994/08/21 05:27:28 paul Exp $
*/
#ifndef _NETINET_IN_PCB_H_
@@ -81,6 +81,8 @@ int in_pcbbind __P((struct inpcb *, struct mbuf *));
int in_pcbconnect __P((struct inpcb *, struct mbuf *));
void in_pcbdetach __P((struct inpcb *));
void in_pcbdisconnect __P((struct inpcb *));
+int in_pcbladdr __P((struct inpcb *, struct mbuf *,
+ struct sockaddr_in **));
struct inpcb *
in_pcblookup __P((struct inpcb *,
struct in_addr, u_int, struct in_addr, u_int, int));
diff --git a/sys/netinet/in_var.h b/sys/netinet/in_var.h
index ddf307c..cba0cb4 100644
--- a/sys/netinet/in_var.h
+++ b/sys/netinet/in_var.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)in_var.h 8.1 (Berkeley) 6/10/93
- * $Id: in_var.h,v 1.6 1994/09/06 22:42:20 wollman Exp $
+ * $Id: in_var.h,v 1.7 1994/10/25 22:13:32 swallace Exp $
*/
#ifndef _NETINET_IN_VAR_H_
@@ -82,6 +82,11 @@ struct in_aliasreq {
#ifdef KERNEL
extern struct in_ifaddr *in_ifaddr;
extern struct ifqueue ipintrq; /* ip packet input queue */
+extern struct in_addr zeroin_addr;
+extern u_char inetctlerrmap[];
+extern int rtq_reallyold; /* XXX */
+extern int rtq_minreallyold; /* XXX */
+extern int rtq_toomany; /* XXX */
/*
* Macro for finding the interface (ifnet structure) corresponding to one
diff --git a/sys/netinet/ip_icmp.c b/sys/netinet/ip_icmp.c
index fca9dad..031de2e 100644
--- a/sys/netinet/ip_icmp.c
+++ b/sys/netinet/ip_icmp.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)ip_icmp.c 8.2 (Berkeley) 1/4/94
- * $Id: ip_icmp.c,v 1.4 1994/10/08 22:39:56 phk Exp $
+ * $Id: ip_icmp.c,v 1.5 1995/02/16 00:27:43 wollman Exp $
*/
#include <sys/param.h>
@@ -43,6 +43,8 @@
#include <sys/time.h>
#include <sys/kernel.h>
#include <sys/socket.h>
+#include <vm/vm.h>
+#include <sys/sysctl.h>
#include <net/if.h>
#include <net/route.h>
@@ -52,6 +54,7 @@
#include <netinet/in_var.h>
#include <netinet/ip.h>
#include <netinet/ip_icmp.h>
+#include <netinet/ip_var.h>
#include <netinet/icmp_var.h>
/*
@@ -185,7 +188,6 @@ icmp_input(m, hlen)
struct in_ifaddr *ia;
void (*ctlfunc) __P((int, struct sockaddr *, struct ip *));
int code;
- extern u_char ip_protox[];
/*
* Locate icmp structure in mbuf, and check
@@ -420,7 +422,7 @@ icmp_reflect(m)
register struct ip *ip = mtod(m, struct ip *);
register struct in_ifaddr *ia;
struct in_addr t;
- struct mbuf *opts = 0, *ip_srcroute();
+ struct mbuf *opts = 0;
int optlen = (ip->ip_hl << 2) - sizeof(struct ip);
if (!in_canforward(ip->ip_src) &&
diff --git a/sys/netinet/ip_input.c b/sys/netinet/ip_input.c
index 2a2ac733..d65df32 100644
--- a/sys/netinet/ip_input.c
+++ b/sys/netinet/ip_input.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)ip_input.c 8.2 (Berkeley) 1/4/94
- * $Id: ip_input.c,v 1.16 1995/02/07 20:30:42 gpalmer Exp $
+ * $Id: ip_input.c,v 1.17 1995/02/14 23:04:52 wollman Exp $
*/
#include <sys/param.h>
@@ -44,12 +44,15 @@
#include <sys/errno.h>
#include <sys/time.h>
#include <sys/kernel.h>
+#include <vm/vm.h>
+#include <sys/sysctl.h>
#include <net/if.h>
#include <net/route.h>
#include <netinet/in.h>
#include <netinet/in_systm.h>
+#include <netinet/in_var.h>
#include <netinet/ip.h>
#include <netinet/in_pcb.h>
#include <netinet/in_var.h>
@@ -1187,10 +1190,6 @@ ip_sysctl(name, namelen, oldp, oldlenp, newp, newlen)
void *newp;
size_t newlen;
{
- extern int rtq_reallyold; /* XXX */
- extern int rtq_minreallyold; /* XXX */
- extern int rtq_toomany; /* XXX */
-
/* All sysctl names at this level are terminal. */
if (namelen != 1)
return (ENOTDIR);
diff --git a/sys/netinet/ip_mroute.c b/sys/netinet/ip_mroute.c
index 40b39da..e8a12a8 100644
--- a/sys/netinet/ip_mroute.c
+++ b/sys/netinet/ip_mroute.c
@@ -197,7 +197,6 @@ static int del_mfc(struct delmfcctl *);
static void cleanup_cache(void *);
static int ip_mdq(struct mbuf *, struct ifnet *, u_long, struct mfc *,
struct ip_moptions *);
-extern int (*legal_vif_num)(int);
static void phyint_send(struct ip *, struct vif *, struct mbuf *);
static void srcrt_send(struct ip *, struct vif *, struct mbuf *);
static void encap_send(struct ip *, struct vif *, struct mbuf *);
@@ -1873,7 +1872,6 @@ ip_mroute_mod_handle(struct lkm_table *lkmtp, int cmd)
static int (*old_mrt_ioctl)();
static void (*old_proto4_input)();
static int (*old_legal_vif_num)();
- extern u_char ip_protox[];
extern struct protosw inetsw[];
case LKM_E_LOAD:
diff --git a/sys/netinet/ip_mroute.h b/sys/netinet/ip_mroute.h
index 2d6540e..945c6bd 100644
--- a/sys/netinet/ip_mroute.h
+++ b/sys/netinet/ip_mroute.h
@@ -35,7 +35,7 @@
* SUCH DAMAGE.
*
* @(#)ip_mroute.h 8.1 (Berkeley) 6/10/93
- * $Id: ip_mroute.h,v 1.4 1994/09/06 22:42:23 wollman Exp $
+ * $Id: ip_mroute.h,v 1.5 1994/09/14 03:10:12 wollman Exp $
*/
#ifndef _NETINET_IP_MROUTE_H_
@@ -248,6 +248,7 @@ struct tbf
extern int (*ip_mrouter_cmd) __P((int, struct socket *, struct mbuf *));
extern int (*ip_mrouter_done) __P((void));
+extern int (*mrt_ioctl) __P((int, caddr_t, struct proc *));
#endif /* KERNEL */
diff --git a/sys/netinet/ip_output.c b/sys/netinet/ip_output.c
index 5d7537d..1648f36 100644
--- a/sys/netinet/ip_output.c
+++ b/sys/netinet/ip_output.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)ip_output.c 8.3 (Berkeley) 1/21/94
- * $Id: ip_output.c,v 1.11 1994/12/13 23:08:12 wollman Exp $
+ * $Id: ip_output.c,v 1.12 1995/01/12 13:06:31 ugen Exp $
*/
#include <sys/param.h>
@@ -172,7 +172,6 @@ ip_output(m0, opt, ro, flags, imo)
}
if (IN_MULTICAST(ntohl(ip->ip_dst.s_addr))) {
struct in_multi *inm;
- extern struct ifnet loif;
m->m_flags |= M_MCAST;
/*
@@ -811,7 +810,6 @@ ip_setmoptions(optname, imop, m)
}
switch (optname) {
- extern int (*legal_vif_num)(int);
/* store an index number for the vif you wanna use in the send */
case IP_MULTICAST_VIF:
if (!legal_vif_num) {
diff --git a/sys/netinet/ip_var.h b/sys/netinet/ip_var.h
index 5ac0e80..a1f0c42 100644
--- a/sys/netinet/ip_var.h
+++ b/sys/netinet/ip_var.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)ip_var.h 8.1 (Berkeley) 6/10/93
- * $Id: ip_var.h,v 1.7 1995/02/14 06:25:17 phk Exp $
+ * $Id: ip_var.h,v 1.8 1995/03/16 16:25:42 wollman Exp $
*/
#ifndef _NETINET_IP_VAR_H_
@@ -156,8 +156,10 @@ extern struct ipstat ipstat;
extern struct ipq ipq; /* ip reass. queue */
extern u_short ip_id; /* ip packet ctr, for ids */
extern int ip_defttl; /* default IP ttl */
+extern u_char ip_protox[];
extern struct socket *ip_rsvpd; /* reservation protocol daemon */
extern struct socket *ip_mrouter; /* multicast routing daemon */
+extern int (*legal_vif_num) __P((int));
int ip_ctloutput __P((int, struct socket *, int, int, struct mbuf **));
void ip_deq __P((struct ipasfrag *));
diff --git a/sys/netinet/tcp_input.c b/sys/netinet/tcp_input.c
index a6bf6fc..bc34836 100644
--- a/sys/netinet/tcp_input.c
+++ b/sys/netinet/tcp_input.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* From: @(#)tcp_input.c 8.5 (Berkeley) 4/10/94
- * $Id: tcp_input.c,v 1.14 1995/02/16 00:55:39 wollman Exp $
+ * $Id: tcp_input.c,v 1.15 1995/02/16 01:39:19 wollman Exp $
*/
#ifndef TUBA_INCLUDE
@@ -1881,8 +1881,6 @@ tcp_mss(tp, offer)
struct socket *so;
struct rmxp_tao *taop;
int origoffer = offer;
- extern int tcp_do_rfc1644;
- extern int tcp_mssdflt;
inp = tp->t_inpcb;
if ((rt = tcp_rtlookup(inp)) == NULL) {
@@ -2040,7 +2038,6 @@ tcp_mssopt(tp)
struct tcpcb *tp;
{
struct rtentry *rt;
- extern int tcp_mssdflt;
rt = tcp_rtlookup(tp->t_inpcb);
if (rt == NULL)
diff --git a/sys/netinet/tcp_reass.c b/sys/netinet/tcp_reass.c
index a6bf6fc..bc34836 100644
--- a/sys/netinet/tcp_reass.c
+++ b/sys/netinet/tcp_reass.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* From: @(#)tcp_input.c 8.5 (Berkeley) 4/10/94
- * $Id: tcp_input.c,v 1.14 1995/02/16 00:55:39 wollman Exp $
+ * $Id: tcp_input.c,v 1.15 1995/02/16 01:39:19 wollman Exp $
*/
#ifndef TUBA_INCLUDE
@@ -1881,8 +1881,6 @@ tcp_mss(tp, offer)
struct socket *so;
struct rmxp_tao *taop;
int origoffer = offer;
- extern int tcp_do_rfc1644;
- extern int tcp_mssdflt;
inp = tp->t_inpcb;
if ((rt = tcp_rtlookup(inp)) == NULL) {
@@ -2040,7 +2038,6 @@ tcp_mssopt(tp)
struct tcpcb *tp;
{
struct rtentry *rt;
- extern int tcp_mssdflt;
rt = tcp_rtlookup(tp->t_inpcb);
if (rt == NULL)
diff --git a/sys/netinet/tcp_subr.c b/sys/netinet/tcp_subr.c
index 7ba388a..fbbff78 100644
--- a/sys/netinet/tcp_subr.c
+++ b/sys/netinet/tcp_subr.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)tcp_subr.c 8.1 (Berkeley) 6/10/93
- * $Id: tcp_subr.c,v 1.7 1995/02/16 00:55:41 wollman Exp $
+ * $Id: tcp_subr.c,v 1.8 1995/03/06 02:49:24 nate Exp $
*/
#include <sys/param.h>
@@ -51,6 +51,7 @@
#include <netinet/in_systm.h>
#include <netinet/ip.h>
#include <netinet/in_pcb.h>
+#include <netinet/in_var.h>
#include <netinet/ip_var.h>
#include <netinet/ip_icmp.h>
#include <netinet/tcp.h>
@@ -427,8 +428,6 @@ tcp_ctlinput(cmd, sa, ip)
register struct ip *ip;
{
register struct tcphdr *th;
- extern struct in_addr zeroin_addr;
- extern u_char inetctlerrmap[];
void (*notify) __P((struct inpcb *, int)) = tcp_notify;
if (cmd == PRC_QUENCH)
diff --git a/sys/netinet/tcp_timewait.c b/sys/netinet/tcp_timewait.c
index 7ba388a..fbbff78 100644
--- a/sys/netinet/tcp_timewait.c
+++ b/sys/netinet/tcp_timewait.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)tcp_subr.c 8.1 (Berkeley) 6/10/93
- * $Id: tcp_subr.c,v 1.7 1995/02/16 00:55:41 wollman Exp $
+ * $Id: tcp_subr.c,v 1.8 1995/03/06 02:49:24 nate Exp $
*/
#include <sys/param.h>
@@ -51,6 +51,7 @@
#include <netinet/in_systm.h>
#include <netinet/ip.h>
#include <netinet/in_pcb.h>
+#include <netinet/in_var.h>
#include <netinet/ip_var.h>
#include <netinet/ip_icmp.h>
#include <netinet/tcp.h>
@@ -427,8 +428,6 @@ tcp_ctlinput(cmd, sa, ip)
register struct ip *ip;
{
register struct tcphdr *th;
- extern struct in_addr zeroin_addr;
- extern u_char inetctlerrmap[];
void (*notify) __P((struct inpcb *, int)) = tcp_notify;
if (cmd == PRC_QUENCH)
diff --git a/sys/netinet/tcp_usrreq.c b/sys/netinet/tcp_usrreq.c
index 0b39e82..9a412b5 100644
--- a/sys/netinet/tcp_usrreq.c
+++ b/sys/netinet/tcp_usrreq.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* From: @(#)tcp_usrreq.c 8.2 (Berkeley) 1/3/94
- * $Id: tcp_usrreq.c,v 1.10 1995/02/16 01:42:45 wollman Exp $
+ * $Id: tcp_usrreq.c,v 1.11 1995/02/17 00:29:42 wollman Exp $
*/
#include <sys/param.h>
@@ -44,6 +44,8 @@
#include <sys/protosw.h>
#include <sys/errno.h>
#include <sys/stat.h>
+#include <vm/vm.h>
+#include <sys/sysctl.h>
#include <net/if.h>
#include <net/route.h>
@@ -52,6 +54,7 @@
#include <netinet/in_systm.h>
#include <netinet/ip.h>
#include <netinet/in_pcb.h>
+#include <netinet/in_var.h>
#include <netinet/ip_var.h>
#include <netinet/tcp.h>
#include <netinet/tcp_fsm.h>
@@ -673,11 +676,6 @@ tcp_sysctl(name, namelen, oldp, oldlenp, newp, newlen)
void *newp;
size_t newlen;
{
- extern int tcp_do_rfc1323; /* XXX */
- extern int tcp_do_rfc1644; /* XXX */
- extern int tcp_mssdflt; /* XXX */
- extern int tcp_rttdflt; /* XXX */
-
/* All sysctl names at this level are terminal. */
if (namelen != 1)
return (ENOTDIR);
diff --git a/sys/netinet/tcp_var.h b/sys/netinet/tcp_var.h
index 460a370..bd4705e 100644
--- a/sys/netinet/tcp_var.h
+++ b/sys/netinet/tcp_var.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)tcp_var.h 8.3 (Berkeley) 4/10/94
- * $Id: tcp_var.h,v 1.7 1995/02/14 02:35:19 wollman Exp $
+ * $Id: tcp_var.h,v 1.9 1995/02/16 00:55:44 wollman Exp $
*/
#ifndef _NETINET_TCP_VAR_H_
@@ -309,7 +309,11 @@ struct tcpstat {
#ifdef KERNEL
extern struct inpcb tcb; /* head of queue of active tcpcb's */
extern struct tcpstat tcpstat; /* tcp statistics */
+extern int tcp_do_rfc1323; /* XXX */
+extern int tcp_do_rfc1644; /* XXX */
+extern int tcp_mssdflt; /* XXX */
extern u_long tcp_now; /* for RFC 1323 timestamps */
+extern int tcp_rttdflt; /* XXX */
int tcp_attach __P((struct socket *));
void tcp_canceltimers __P((struct tcpcb *));
diff --git a/sys/netinet/udp_usrreq.c b/sys/netinet/udp_usrreq.c
index 2c6f004..ec7ea3e 100644
--- a/sys/netinet/udp_usrreq.c
+++ b/sys/netinet/udp_usrreq.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)udp_usrreq.c 8.4 (Berkeley) 1/21/94
- * $Id: udp_usrreq.c,v 1.6 1995/02/16 01:25:06 wollman Exp $
+ * $Id: udp_usrreq.c,v 1.7 1995/02/16 01:47:36 wollman Exp $
*/
#include <sys/param.h>
@@ -43,6 +43,8 @@
#include <sys/socketvar.h>
#include <sys/errno.h>
#include <sys/stat.h>
+#include <vm/vm.h>
+#include <sys/sysctl.h>
#include <net/if.h>
#include <net/route.h>
@@ -51,6 +53,7 @@
#include <netinet/in_systm.h>
#include <netinet/ip.h>
#include <netinet/in_pcb.h>
+#include <netinet/in_var.h>
#include <netinet/ip_var.h>
#include <netinet/ip_icmp.h>
#include <netinet/udp.h>
@@ -364,8 +367,6 @@ udp_ctlinput(cmd, sa, ip)
register struct ip *ip;
{
register struct udphdr *uh;
- extern struct in_addr zeroin_addr;
- extern u_char inetctlerrmap[];
if (!PRC_IS_REDIRECT(cmd) &&
((unsigned)cmd >= PRC_NCMDS || inetctlerrmap[cmd] == 0))
diff --git a/sys/netiso/clnp_input.c b/sys/netiso/clnp_input.c
index 8ee40ae..300f8de 100644
--- a/sys/netiso/clnp_input.c
+++ b/sys/netiso/clnp_input.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)clnp_input.c 8.1 (Berkeley) 6/10/93
- * $Id: clnp_input.c,v 1.2 1994/08/02 07:49:39 davidg Exp $
+ * $Id: clnp_input.c,v 1.3 1994/11/15 14:26:11 bde Exp $
*/
/***********************************************************
@@ -60,7 +60,7 @@ SOFTWARE.
/*
* ARGO Project, Computer Sciences Dept., University of Wisconsin - Madison
*/
-/* $Header: /home/ncvs/src/sys/netiso/clnp_input.c,v 1.2 1994/08/02 07:49:39 davidg Exp $ */
+/* $Header: /home/ncvs/src/sys/netiso/clnp_input.c,v 1.3 1994/11/15 14:26:11 bde Exp $ */
/* $Source: /home/ncvs/src/sys/netiso/clnp_input.c,v $ */
#include <sys/param.h>
@@ -152,6 +152,7 @@ clnp_init()
*
* NOTES:
*/
+void
clnlintr()
{
register struct mbuf *m; /* ptr to first mbuf of pkt */
diff --git a/sys/netiso/iso_var.h b/sys/netiso/iso_var.h
index d260de5..bee5422 100644
--- a/sys/netiso/iso_var.h
+++ b/sys/netiso/iso_var.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)iso_var.h 8.1 (Berkeley) 6/10/93
- * $Id: iso_var.h,v 1.2 1994/08/02 07:50:49 davidg Exp $
+ * $Id: iso_var.h,v 1.3 1994/08/21 06:14:22 paul Exp $
*/
#ifndef _NETISO_ISO_VAR_H_
@@ -63,7 +63,7 @@ SOFTWARE.
/*
* ARGO Project, Computer Sciences Dept., University of Wisconsin - Madison
*/
-/* $Header: /home/ncvs/src/sys/netiso/iso_var.h,v 1.2 1994/08/02 07:50:49 davidg Exp $
+/* $Header: /home/ncvs/src/sys/netiso/iso_var.h,v 1.3 1994/08/21 06:14:22 paul Exp $
* $Source: /home/ncvs/src/sys/netiso/iso_var.h,v $
*/
@@ -137,6 +137,7 @@ struct snpa_hdr {
#ifdef KERNEL
struct iso_ifaddr *iso_ifaddr; /* linked list of iso address ifaces */
struct iso_ifaddr *iso_localifa(); /* linked list of iso address ifaces */
+void clnlintr __P((void));
struct ifqueue clnlintrq; /* clnl packet input queue */
#endif /* KERNEL */
diff --git a/sys/netns/ns_if.h b/sys/netns/ns_if.h
index 3032a39b..a4a955a 100644
--- a/sys/netns/ns_if.h
+++ b/sys/netns/ns_if.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)ns_if.h 8.1 (Berkeley) 6/10/93
- * $Id: ns_if.h,v 1.2 1994/08/02 07:51:48 davidg Exp $
+ * $Id: ns_if.h,v 1.3 1994/08/21 06:22:08 paul Exp $
*/
#ifndef _NETNS_NS_IF_H_
@@ -82,6 +82,7 @@ struct nsip_req {
#ifdef KERNEL
struct ns_ifaddr *ns_ifaddr;
struct ns_ifaddr *ns_iaonnetof();
+void nsintr __P((void));
struct ifqueue nsintrq; /* XNS input packet queue */
#endif
diff --git a/sys/netns/ns_input.c b/sys/netns/ns_input.c
index 91a5b31..a50c121 100644
--- a/sys/netns/ns_input.c
+++ b/sys/netns/ns_input.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)ns_input.c 8.1 (Berkeley) 6/10/93
- * $Id$
+ * $Id: ns_input.c,v 1.2 1994/08/02 07:51:49 davidg Exp $
*/
#include <sys/param.h>
@@ -100,6 +100,7 @@ ns_init()
*/
int nsintr_getpck = 0;
int nsintr_swtch = 0;
+void
nsintr()
{
register struct idp *idp;
diff --git a/sys/nfs/nfs_common.c b/sys/nfs/nfs_common.c
index d1c11c4..03b0b03 100644
--- a/sys/nfs/nfs_common.c
+++ b/sys/nfs/nfs_common.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_subs.c 8.3 (Berkeley) 1/4/94
- * $Id: nfs_subs.c,v 1.10 1995/02/15 03:40:00 davidg Exp $
+ * $Id: nfs_subs.c,v 1.11 1995/02/15 04:21:32 phk Exp $
*/
/*
@@ -690,7 +690,6 @@ nfs_loadattrcache(vpp, mdp, dposp, vaper)
register struct vnode *vp = *vpp;
register struct vattr *vap;
register struct nfsv2_fattr *fp;
- extern int (**spec_nfsv2nodeop_p)();
register struct nfsnode *np;
register struct nfsnodehashhead *nhpp;
register long t1;
@@ -736,7 +735,6 @@ nfs_loadattrcache(vpp, mdp, dposp, vaper)
else
vp->v_type = vtyp;
if (vp->v_type == VFIFO) {
- extern int (**fifo_nfsv2nodeop_p)();
vp->v_op = fifo_nfsv2nodeop_p;
}
if (vp->v_type == VCHR || vp->v_type == VBLK) {
diff --git a/sys/nfs/nfs_node.c b/sys/nfs/nfs_node.c
index 909f9e0..e5315f4 100644
--- a/sys/nfs/nfs_node.c
+++ b/sys/nfs/nfs_node.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_node.c 8.2 (Berkeley) 12/30/93
- * $Id: nfs_node.c,v 1.6 1994/10/06 21:06:56 davidg Exp $
+ * $Id: nfs_node.c,v 1.7 1994/10/17 17:47:33 phk Exp $
*/
#include <sys/param.h>
@@ -109,7 +109,6 @@ nfs_nget(mntp, fhp, npp)
register struct nfsnode *np;
struct nfsnodehashhead *nhpp;
register struct vnode *vp;
- extern int (**nfsv2_vnodeop_p)();
struct vnode *nvp;
int error;
@@ -165,7 +164,6 @@ nfs_inactive(ap)
register struct nfsnode *np;
register struct sillyrename *sp;
struct proc *p = curproc; /* XXX */
- extern int prtactive;
np = VTONFS(ap->a_vp);
if (prtactive && ap->a_vp->v_usecount != 0)
@@ -201,7 +199,6 @@ nfs_reclaim(ap)
register struct vnode *vp = ap->a_vp;
register struct nfsnode *np = VTONFS(vp);
register struct nfsmount *nmp = VFSTONFS(vp->v_mount);
- extern int prtactive;
if (prtactive && vp->v_usecount != 0)
vprint("nfs_reclaim: pushing active", vp);
diff --git a/sys/nfs/nfs_socket.c b/sys/nfs/nfs_socket.c
index 27c4561..ccd187a 100644
--- a/sys/nfs/nfs_socket.c
+++ b/sys/nfs/nfs_socket.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_socket.c 8.3 (Berkeley) 1/12/94
- * $Id: nfs_socket.c,v 1.4 1994/10/02 17:26:59 phk Exp $
+ * $Id: nfs_socket.c,v 1.5 1994/10/17 17:47:35 phk Exp $
*/
/*
@@ -68,8 +68,6 @@
#include <nfs/nfsrtt.h>
#include <nfs/nqnfs.h>
-#include <machine/clock.h> /* for inittodr */
-
#define TRUE 1
#define FALSE 0
diff --git a/sys/nfs/nfs_subs.c b/sys/nfs/nfs_subs.c
index d1c11c4..03b0b03 100644
--- a/sys/nfs/nfs_subs.c
+++ b/sys/nfs/nfs_subs.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_subs.c 8.3 (Berkeley) 1/4/94
- * $Id: nfs_subs.c,v 1.10 1995/02/15 03:40:00 davidg Exp $
+ * $Id: nfs_subs.c,v 1.11 1995/02/15 04:21:32 phk Exp $
*/
/*
@@ -690,7 +690,6 @@ nfs_loadattrcache(vpp, mdp, dposp, vaper)
register struct vnode *vp = *vpp;
register struct vattr *vap;
register struct nfsv2_fattr *fp;
- extern int (**spec_nfsv2nodeop_p)();
register struct nfsnode *np;
register struct nfsnodehashhead *nhpp;
register long t1;
@@ -736,7 +735,6 @@ nfs_loadattrcache(vpp, mdp, dposp, vaper)
else
vp->v_type = vtyp;
if (vp->v_type == VFIFO) {
- extern int (**fifo_nfsv2nodeop_p)();
vp->v_op = fifo_nfsv2nodeop_p;
}
if (vp->v_type == VCHR || vp->v_type == VBLK) {
diff --git a/sys/nfs/nfs_vfsops.c b/sys/nfs/nfs_vfsops.c
index dc4c789..9742bd4 100644
--- a/sys/nfs/nfs_vfsops.c
+++ b/sys/nfs/nfs_vfsops.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_vfsops.c 8.3 (Berkeley) 1/4/94
- * $Id: nfs_vfsops.c,v 1.9 1994/12/08 20:59:33 phk Exp $
+ * $Id: nfs_vfsops.c,v 1.10 1995/01/03 07:44:10 jkh Exp $
*/
#include <sys/param.h>
@@ -52,6 +52,8 @@
#include <sys/socketvar.h>
#include <sys/systm.h>
+#include <vm/vm.h>
+
#include <net/if.h>
#include <net/route.h>
#include <netinet/in.h>
@@ -579,7 +581,6 @@ nfs_unmount(mp, mntflags, p)
struct nfsnode *np;
struct vnode *vp;
int error, flags = 0;
- extern int doforce;
if (mntflags & MNT_FORCE) {
if (!doforce)
diff --git a/sys/nfs/nfs_vnops.c b/sys/nfs/nfs_vnops.c
index 2986b51..b4a9baf 100644
--- a/sys/nfs/nfs_vnops.c
+++ b/sys/nfs/nfs_vnops.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_vnops.c 8.5 (Berkeley) 2/13/94
- * $Id: nfs_vnops.c,v 1.11 1995/01/09 16:05:09 davidg Exp $
+ * $Id: nfs_vnops.c,v 1.12 1995/02/03 06:46:24 davidg Exp $
*/
/*
@@ -2510,7 +2510,6 @@ nfsfifo_read(ap)
struct ucred *a_cred;
} */ *ap;
{
- extern int (**fifo_vnodeop_p)();
register struct nfsnode *np = VTONFS(ap->a_vp);
/*
@@ -2533,7 +2532,6 @@ nfsfifo_write(ap)
struct ucred *a_cred;
} */ *ap;
{
- extern int (**fifo_vnodeop_p)();
register struct nfsnode *np = VTONFS(ap->a_vp);
/*
@@ -2561,7 +2559,6 @@ nfsfifo_close(ap)
register struct vnode *vp = ap->a_vp;
register struct nfsnode *np = VTONFS(vp);
struct vattr vattr;
- extern int (**fifo_vnodeop_p)();
if (np->n_flag & (NACC | NUPD)) {
if (np->n_flag & NACC)
diff --git a/sys/nfs/nfsnode.h b/sys/nfs/nfsnode.h
index 01d0969..dc9162b 100644
--- a/sys/nfs/nfsnode.h
+++ b/sys/nfs/nfsnode.h
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfsnode.h 8.4 (Berkeley) 2/13/94
- * $Id: nfsnode.h,v 1.7 1994/10/02 17:27:06 phk Exp $
+ * $Id: nfsnode.h,v 1.8 1994/10/17 17:47:44 phk Exp $
*/
#ifndef _NFS_NFSNODE_H_
@@ -108,6 +108,10 @@ struct nfsnode {
TAILQ_HEAD(, buf) nfs_bufq;
#ifdef KERNEL
+extern int (**fifo_nfsv2nodeop_p)();
+extern int (**nfsv2_vnodeop_p)();
+extern int (**spec_nfsv2nodeop_p)();
+
/*
* Prototypes for NFS vnode operations
*/
diff --git a/sys/nfsclient/nfs_node.c b/sys/nfsclient/nfs_node.c
index 909f9e0..e5315f4 100644
--- a/sys/nfsclient/nfs_node.c
+++ b/sys/nfsclient/nfs_node.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_node.c 8.2 (Berkeley) 12/30/93
- * $Id: nfs_node.c,v 1.6 1994/10/06 21:06:56 davidg Exp $
+ * $Id: nfs_node.c,v 1.7 1994/10/17 17:47:33 phk Exp $
*/
#include <sys/param.h>
@@ -109,7 +109,6 @@ nfs_nget(mntp, fhp, npp)
register struct nfsnode *np;
struct nfsnodehashhead *nhpp;
register struct vnode *vp;
- extern int (**nfsv2_vnodeop_p)();
struct vnode *nvp;
int error;
@@ -165,7 +164,6 @@ nfs_inactive(ap)
register struct nfsnode *np;
register struct sillyrename *sp;
struct proc *p = curproc; /* XXX */
- extern int prtactive;
np = VTONFS(ap->a_vp);
if (prtactive && ap->a_vp->v_usecount != 0)
@@ -201,7 +199,6 @@ nfs_reclaim(ap)
register struct vnode *vp = ap->a_vp;
register struct nfsnode *np = VTONFS(vp);
register struct nfsmount *nmp = VFSTONFS(vp->v_mount);
- extern int prtactive;
if (prtactive && vp->v_usecount != 0)
vprint("nfs_reclaim: pushing active", vp);
diff --git a/sys/nfsclient/nfs_socket.c b/sys/nfsclient/nfs_socket.c
index 27c4561..ccd187a 100644
--- a/sys/nfsclient/nfs_socket.c
+++ b/sys/nfsclient/nfs_socket.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_socket.c 8.3 (Berkeley) 1/12/94
- * $Id: nfs_socket.c,v 1.4 1994/10/02 17:26:59 phk Exp $
+ * $Id: nfs_socket.c,v 1.5 1994/10/17 17:47:35 phk Exp $
*/
/*
@@ -68,8 +68,6 @@
#include <nfs/nfsrtt.h>
#include <nfs/nqnfs.h>
-#include <machine/clock.h> /* for inittodr */
-
#define TRUE 1
#define FALSE 0
diff --git a/sys/nfsclient/nfs_subs.c b/sys/nfsclient/nfs_subs.c
index d1c11c4..03b0b03 100644
--- a/sys/nfsclient/nfs_subs.c
+++ b/sys/nfsclient/nfs_subs.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_subs.c 8.3 (Berkeley) 1/4/94
- * $Id: nfs_subs.c,v 1.10 1995/02/15 03:40:00 davidg Exp $
+ * $Id: nfs_subs.c,v 1.11 1995/02/15 04:21:32 phk Exp $
*/
/*
@@ -690,7 +690,6 @@ nfs_loadattrcache(vpp, mdp, dposp, vaper)
register struct vnode *vp = *vpp;
register struct vattr *vap;
register struct nfsv2_fattr *fp;
- extern int (**spec_nfsv2nodeop_p)();
register struct nfsnode *np;
register struct nfsnodehashhead *nhpp;
register long t1;
@@ -736,7 +735,6 @@ nfs_loadattrcache(vpp, mdp, dposp, vaper)
else
vp->v_type = vtyp;
if (vp->v_type == VFIFO) {
- extern int (**fifo_nfsv2nodeop_p)();
vp->v_op = fifo_nfsv2nodeop_p;
}
if (vp->v_type == VCHR || vp->v_type == VBLK) {
diff --git a/sys/nfsclient/nfs_vfsops.c b/sys/nfsclient/nfs_vfsops.c
index dc4c789..9742bd4 100644
--- a/sys/nfsclient/nfs_vfsops.c
+++ b/sys/nfsclient/nfs_vfsops.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_vfsops.c 8.3 (Berkeley) 1/4/94
- * $Id: nfs_vfsops.c,v 1.9 1994/12/08 20:59:33 phk Exp $
+ * $Id: nfs_vfsops.c,v 1.10 1995/01/03 07:44:10 jkh Exp $
*/
#include <sys/param.h>
@@ -52,6 +52,8 @@
#include <sys/socketvar.h>
#include <sys/systm.h>
+#include <vm/vm.h>
+
#include <net/if.h>
#include <net/route.h>
#include <netinet/in.h>
@@ -579,7 +581,6 @@ nfs_unmount(mp, mntflags, p)
struct nfsnode *np;
struct vnode *vp;
int error, flags = 0;
- extern int doforce;
if (mntflags & MNT_FORCE) {
if (!doforce)
diff --git a/sys/nfsclient/nfs_vnops.c b/sys/nfsclient/nfs_vnops.c
index 2986b51..b4a9baf 100644
--- a/sys/nfsclient/nfs_vnops.c
+++ b/sys/nfsclient/nfs_vnops.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_vnops.c 8.5 (Berkeley) 2/13/94
- * $Id: nfs_vnops.c,v 1.11 1995/01/09 16:05:09 davidg Exp $
+ * $Id: nfs_vnops.c,v 1.12 1995/02/03 06:46:24 davidg Exp $
*/
/*
@@ -2510,7 +2510,6 @@ nfsfifo_read(ap)
struct ucred *a_cred;
} */ *ap;
{
- extern int (**fifo_vnodeop_p)();
register struct nfsnode *np = VTONFS(ap->a_vp);
/*
@@ -2533,7 +2532,6 @@ nfsfifo_write(ap)
struct ucred *a_cred;
} */ *ap;
{
- extern int (**fifo_vnodeop_p)();
register struct nfsnode *np = VTONFS(ap->a_vp);
/*
@@ -2561,7 +2559,6 @@ nfsfifo_close(ap)
register struct vnode *vp = ap->a_vp;
register struct nfsnode *np = VTONFS(vp);
struct vattr vattr;
- extern int (**fifo_vnodeop_p)();
if (np->n_flag & (NACC | NUPD)) {
if (np->n_flag & NACC)
diff --git a/sys/nfsclient/nfsnode.h b/sys/nfsclient/nfsnode.h
index 01d0969..dc9162b 100644
--- a/sys/nfsclient/nfsnode.h
+++ b/sys/nfsclient/nfsnode.h
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfsnode.h 8.4 (Berkeley) 2/13/94
- * $Id: nfsnode.h,v 1.7 1994/10/02 17:27:06 phk Exp $
+ * $Id: nfsnode.h,v 1.8 1994/10/17 17:47:44 phk Exp $
*/
#ifndef _NFS_NFSNODE_H_
@@ -108,6 +108,10 @@ struct nfsnode {
TAILQ_HEAD(, buf) nfs_bufq;
#ifdef KERNEL
+extern int (**fifo_nfsv2nodeop_p)();
+extern int (**nfsv2_vnodeop_p)();
+extern int (**spec_nfsv2nodeop_p)();
+
/*
* Prototypes for NFS vnode operations
*/
diff --git a/sys/nfsserver/nfs_srvsock.c b/sys/nfsserver/nfs_srvsock.c
index 27c4561..ccd187a 100644
--- a/sys/nfsserver/nfs_srvsock.c
+++ b/sys/nfsserver/nfs_srvsock.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_socket.c 8.3 (Berkeley) 1/12/94
- * $Id: nfs_socket.c,v 1.4 1994/10/02 17:26:59 phk Exp $
+ * $Id: nfs_socket.c,v 1.5 1994/10/17 17:47:35 phk Exp $
*/
/*
@@ -68,8 +68,6 @@
#include <nfs/nfsrtt.h>
#include <nfs/nqnfs.h>
-#include <machine/clock.h> /* for inittodr */
-
#define TRUE 1
#define FALSE 0
diff --git a/sys/nfsserver/nfs_srvsubs.c b/sys/nfsserver/nfs_srvsubs.c
index d1c11c4..03b0b03 100644
--- a/sys/nfsserver/nfs_srvsubs.c
+++ b/sys/nfsserver/nfs_srvsubs.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_subs.c 8.3 (Berkeley) 1/4/94
- * $Id: nfs_subs.c,v 1.10 1995/02/15 03:40:00 davidg Exp $
+ * $Id: nfs_subs.c,v 1.11 1995/02/15 04:21:32 phk Exp $
*/
/*
@@ -690,7 +690,6 @@ nfs_loadattrcache(vpp, mdp, dposp, vaper)
register struct vnode *vp = *vpp;
register struct vattr *vap;
register struct nfsv2_fattr *fp;
- extern int (**spec_nfsv2nodeop_p)();
register struct nfsnode *np;
register struct nfsnodehashhead *nhpp;
register long t1;
@@ -736,7 +735,6 @@ nfs_loadattrcache(vpp, mdp, dposp, vaper)
else
vp->v_type = vtyp;
if (vp->v_type == VFIFO) {
- extern int (**fifo_nfsv2nodeop_p)();
vp->v_op = fifo_nfsv2nodeop_p;
}
if (vp->v_type == VCHR || vp->v_type == VBLK) {
diff --git a/sys/scsi/scsi_driver.c b/sys/scsi/scsi_driver.c
index 785e755..b5f3fad 100644
--- a/sys/scsi/scsi_driver.c
+++ b/sys/scsi/scsi_driver.c
@@ -35,13 +35,15 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: scsi_driver.c,v 1.4 1995/03/05 20:01:44 dufault Exp $
+ * $Id: scsi_driver.c,v 1.5 1995/03/15 14:22:06 dufault Exp $
*
*/
#include <sys/types.h>
#include <sys/errno.h>
#include <sys/param.h>
+#include <sys/systm.h>
#include <sys/buf.h>
+#include <sys/devconf.h>
#include <sys/malloc.h>
#include <scsi/scsi_all.h>
diff --git a/sys/scsi/scsiconf.c b/sys/scsi/scsiconf.c
index f4cff94..53dbf27 100644
--- a/sys/scsi/scsiconf.c
+++ b/sys/scsi/scsiconf.c
@@ -16,7 +16,7 @@
*
* New configuration setup: dufault@hda.com
*
- * $Id: scsiconf.c,v 1.22 1995/03/06 15:02:13 dufault Exp $
+ * $Id: scsiconf.c,v 1.23 1995/03/15 14:22:08 dufault Exp $
*/
#include <sys/types.h>
@@ -41,6 +41,13 @@
#include <scsi/scsi_all.h>
#include <scsi/scsiconf.h>
+/*
+ * XXX SCSI_DEVICE_ENTRIES() generates extern switches but it should
+ * generate static switches except for this. Separate macros are
+ * probably required for the extern and static parts.
+ */
+extern struct scsi_device uk_switch;
+
/* Extensible arrays: Use a realloc like implementation to permit
* the arrays to be extend. These are set up to be moved out
* of this file if needed elsewhere.
@@ -388,7 +395,6 @@ scsi_device_register(struct scsi_device *sd)
static struct scsi_device *
scsi_device_lookup(int type)
{
- extern struct scsi_device uk_switch;
struct scsi_device *sd;
for (sd = device_list; sd; sd = sd->next)
@@ -401,7 +407,6 @@ scsi_device_lookup(int type)
static struct scsi_device *
scsi_device_lookup_by_name(char *name)
{
- extern struct scsi_device uk_switch;
struct scsi_device *sd;
for (sd = device_list; sd; sd = sd->next)
diff --git a/sys/scsi/scsiconf.h b/sys/scsi/scsiconf.h
index 2c18e9c..47c963b 100644
--- a/sys/scsi/scsiconf.h
+++ b/sys/scsi/scsiconf.h
@@ -14,7 +14,7 @@
*
* Ported to run under 386BSD by Julian Elischer (julian@tfs.com) Sept 1992
*
- * $Id: scsiconf.h,v 1.18 1995/03/01 22:24:44 dufault Exp $
+ * $Id: scsiconf.h,v 1.19 1995/03/04 20:51:00 dufault Exp $
*/
#ifndef SCSI_SCSICONF_H
#define SCSI_SCSICONF_H 1
@@ -440,6 +440,7 @@ struct scsi_xfer
#define XS_LENGTH 0x09 /* Illegal length (over/under run) */
#ifdef KERNEL
+void *extend_get(struct extend_array *ea, int index);
char * scsi_type_long_name(int type);
char * scsi_type_name(int type);
void scsi_attachdevs __P((struct scsi_link *sc_link_proto));
@@ -454,7 +455,9 @@ errval scsi_inquire( struct scsi_link *sc_link,
errval scsi_prevent( struct scsi_link *sc_link, u_int32 type,u_int32 flags);
errval scsi_probe_busses __P(( int, int, int));
errval scsi_start_unit( struct scsi_link *sc_link, u_int32 flags);
+errval scsi_stop_unit(struct scsi_link *sc_link, u_int32 eject, u_int32 flags);
void scsi_done(struct scsi_xfer *xs);
+void scsi_user_done(struct scsi_xfer *xs);
errval scsi_scsi_cmd( struct scsi_link *sc_link, struct scsi_generic *scsi_cmd,
u_int32 cmdlen, u_char *data_addr,
u_int32 datalen, u_int32 retries,
@@ -469,6 +472,7 @@ struct proc *p)));
int scsi_opened_ok __P((dev_t dev, int flag, int type, struct scsi_link *sc_link));
+char *scsi_sense_desc(int asc, int ascq);
void scsi_sense_print(struct scsi_xfer *xs);
void show_scsi_xs(struct scsi_xfer *xs);
void show_scsi_cmd(struct scsi_xfer *xs);
diff --git a/sys/scsi/sd.c b/sys/scsi/sd.c
index b334b4c..62d05d2 100644
--- a/sys/scsi/sd.c
+++ b/sys/scsi/sd.c
@@ -14,7 +14,7 @@
*
* Ported to run under 386BSD by Julian Elischer (julian@dialix.oz.au) Sept 1992
*
- * $Id: sd.c,v 1.53 1995/03/06 05:36:59 davidg Exp $
+ * $Id: sd.c,v 1.54 1995/03/15 14:22:10 dufault Exp $
*/
#define SPLSD splbio
@@ -40,6 +40,8 @@
#include <vm/vm.h>
#include <sys/devconf.h>
#include <sys/dkstat.h>
+#include <machine/md_var.h>
+#include <i386/i386/cons.h> /* XXX */
u_int32 sdstrats, sdqueues;
@@ -1030,10 +1032,7 @@ sddump(dev_t dev)
int32 nblocks;
char *addr;
struct scsi_rw_big cmd;
- extern int Maxmem;
static int sddoingadump = 0;
- extern caddr_t CADDR1; /* map the page we are about to write, here */
- extern struct pte *CMAP1;
struct scsi_xfer *xs = &sx;
errval retval;
int c;
@@ -1041,8 +1040,8 @@ sddump(dev_t dev)
addr = (char *) 0; /* starting address */
/* toss any characters present prior to dump */
- while ((c = cncheckc(1)) && (c != 0x100));
- /*syscons and pccons differ */
+ while (cncheckc())
+ ;
/* size of memory to dump */
num = Maxmem;
@@ -1082,7 +1081,7 @@ sddump(dev_t dev)
blknum = dumplo + blkoff;
while (num > 0) {
- *(int *)CMAP1 =
+ *(int *)CMAP1 = /* XXX use pmap_enter() */
PG_V | PG_KW | trunc_page(addr);
pmap_update();
/*
@@ -1112,7 +1111,7 @@ sddump(dev_t dev)
xs->resid = blkcnt * 512;
xs->error = XS_NOERROR;
xs->bp = 0;
- xs->data = (u_char *) CADDR1;
+ xs->data = (u_char *) CADDR1; /* XXX use pmap_enter() */
xs->datalen = blkcnt * 512;
/*
@@ -1137,7 +1136,7 @@ sddump(dev_t dev)
(int) addr += 512 * blkcnt;
/* operator aborting dump? */
- if ((c = cncheckc(1)) && (c != 0x100))
+ if (cncheckc())
return (EINTR);
}
return (0);
diff --git a/sys/sys/bio.h b/sys/sys/bio.h
index 509e913..671bf95 100644
--- a/sys/sys/bio.h
+++ b/sys/sys/bio.h
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)buf.h 8.7 (Berkeley) 1/21/94
- * $Id: buf.h,v 1.11 1995/01/09 16:05:12 davidg Exp $
+ * $Id: buf.h,v 1.12 1995/02/18 21:12:33 bde Exp $
*/
#ifndef _SYS_BUF_H_
@@ -217,9 +217,11 @@ int bwrite __P((struct buf *));
void bdwrite __P((struct buf *));
void bawrite __P((struct buf *));
void brelse __P((struct buf *));
+void vfs_bio_awrite __P((struct buf *));
struct buf *getnewbuf __P((int slpflag, int slptimeo, int));
struct buf * getpbuf __P((void));
struct buf *incore __P((struct vnode *, daddr_t));
+int inmem __P((struct vnode *, daddr_t));
struct buf *getblk __P((struct vnode *, daddr_t, int, int, int));
struct buf *geteblk __P((int));
int allocbuf __P((struct buf *, int, int));
@@ -229,15 +231,24 @@ void biodone __P((struct buf *));
void cluster_callback __P((struct buf *));
int cluster_read __P((struct vnode *, u_quad_t, daddr_t, long,
struct ucred *, struct buf **));
+void cluster_wbuild __P((struct vnode *, struct buf *, long, daddr_t, int,
+ daddr_t));
void cluster_write __P((struct buf *, u_quad_t));
+int physio __P((void (*)(), struct buf *, dev_t, int, u_int (*)(),
+ struct uio *));
u_int minphys __P((struct buf *));
+void vfs_busy_pages __P((struct buf *, int clear_modify));
+void vfs_unbusy_pages(struct buf *);
void vwakeup __P((struct buf *));
void vmapbuf __P((struct buf *));
void vunmapbuf __P((struct buf *));
void relpbuf __P((struct buf *));
void brelvp __P((struct buf *));
void bgetvp __P((struct vnode *, struct buf *));
+void pbgetvp __P((struct vnode *, struct buf *));
+void pbrelvp __P((struct buf *));
void reassignbuf __P((struct buf *, struct vnode *));
+struct buf *trypbuf __P((void));
__END_DECLS
#endif
#endif /* !_SYS_BUF_H_ */
diff --git a/sys/sys/buf.h b/sys/sys/buf.h
index 509e913..671bf95 100644
--- a/sys/sys/buf.h
+++ b/sys/sys/buf.h
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)buf.h 8.7 (Berkeley) 1/21/94
- * $Id: buf.h,v 1.11 1995/01/09 16:05:12 davidg Exp $
+ * $Id: buf.h,v 1.12 1995/02/18 21:12:33 bde Exp $
*/
#ifndef _SYS_BUF_H_
@@ -217,9 +217,11 @@ int bwrite __P((struct buf *));
void bdwrite __P((struct buf *));
void bawrite __P((struct buf *));
void brelse __P((struct buf *));
+void vfs_bio_awrite __P((struct buf *));
struct buf *getnewbuf __P((int slpflag, int slptimeo, int));
struct buf * getpbuf __P((void));
struct buf *incore __P((struct vnode *, daddr_t));
+int inmem __P((struct vnode *, daddr_t));
struct buf *getblk __P((struct vnode *, daddr_t, int, int, int));
struct buf *geteblk __P((int));
int allocbuf __P((struct buf *, int, int));
@@ -229,15 +231,24 @@ void biodone __P((struct buf *));
void cluster_callback __P((struct buf *));
int cluster_read __P((struct vnode *, u_quad_t, daddr_t, long,
struct ucred *, struct buf **));
+void cluster_wbuild __P((struct vnode *, struct buf *, long, daddr_t, int,
+ daddr_t));
void cluster_write __P((struct buf *, u_quad_t));
+int physio __P((void (*)(), struct buf *, dev_t, int, u_int (*)(),
+ struct uio *));
u_int minphys __P((struct buf *));
+void vfs_busy_pages __P((struct buf *, int clear_modify));
+void vfs_unbusy_pages(struct buf *);
void vwakeup __P((struct buf *));
void vmapbuf __P((struct buf *));
void vunmapbuf __P((struct buf *));
void relpbuf __P((struct buf *));
void brelvp __P((struct buf *));
void bgetvp __P((struct vnode *, struct buf *));
+void pbgetvp __P((struct vnode *, struct buf *));
+void pbrelvp __P((struct buf *));
void reassignbuf __P((struct buf *, struct vnode *));
+struct buf *trypbuf __P((void));
__END_DECLS
#endif
#endif /* !_SYS_BUF_H_ */
diff --git a/sys/sys/conf.h b/sys/sys/conf.h
index 17844b1..04242b1 100644
--- a/sys/sys/conf.h
+++ b/sys/sys/conf.h
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)conf.h 8.3 (Berkeley) 1/21/94
- * $Id: conf.h,v 1.8 1995/02/09 13:51:25 davidg Exp $
+ * $Id: conf.h,v 1.9 1995/02/25 20:09:36 pst Exp $
*/
#ifndef _SYS_CONF_H_
@@ -120,6 +120,7 @@ struct linesw {
#ifdef KERNEL
extern struct linesw linesw[];
+extern int nlinesw;
#endif
struct swdevt {
diff --git a/sys/sys/disklabel.h b/sys/sys/disklabel.h
index a991671..e879b19 100644
--- a/sys/sys/disklabel.h
+++ b/sys/sys/disklabel.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)disklabel.h 8.1 (Berkeley) 6/2/93
- * $Id: disklabel.h,v 1.9 1994/12/11 23:20:41 bde Exp $
+ * $Id: disklabel.h,v 1.10 1995/02/22 21:24:17 bde Exp $
*/
#ifndef _SYS_DISKLABEL_H_
@@ -410,6 +410,8 @@ extern struct dos_partition dos_partitions[NDOSPART];
*/
#include <sys/conf.h>
+int bounds_check_with_label __P((struct buf *bp, struct disklabel *lp,
+ int wlabel));
char *correct_readdisklabel __P((dev_t dev, d_strategy_t *strat,
struct disklabel *lp));
int correct_writedisklabel __P((dev_t dev, d_strategy_t *strat,
diff --git a/sys/sys/diskmbr.h b/sys/sys/diskmbr.h
index a991671..e879b19 100644
--- a/sys/sys/diskmbr.h
+++ b/sys/sys/diskmbr.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)disklabel.h 8.1 (Berkeley) 6/2/93
- * $Id: disklabel.h,v 1.9 1994/12/11 23:20:41 bde Exp $
+ * $Id: disklabel.h,v 1.10 1995/02/22 21:24:17 bde Exp $
*/
#ifndef _SYS_DISKLABEL_H_
@@ -410,6 +410,8 @@ extern struct dos_partition dos_partitions[NDOSPART];
*/
#include <sys/conf.h>
+int bounds_check_with_label __P((struct buf *bp, struct disklabel *lp,
+ int wlabel));
char *correct_readdisklabel __P((dev_t dev, d_strategy_t *strat,
struct disklabel *lp));
int correct_writedisklabel __P((dev_t dev, d_strategy_t *strat,
diff --git a/sys/sys/diskpc98.h b/sys/sys/diskpc98.h
index a991671..e879b19 100644
--- a/sys/sys/diskpc98.h
+++ b/sys/sys/diskpc98.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)disklabel.h 8.1 (Berkeley) 6/2/93
- * $Id: disklabel.h,v 1.9 1994/12/11 23:20:41 bde Exp $
+ * $Id: disklabel.h,v 1.10 1995/02/22 21:24:17 bde Exp $
*/
#ifndef _SYS_DISKLABEL_H_
@@ -410,6 +410,8 @@ extern struct dos_partition dos_partitions[NDOSPART];
*/
#include <sys/conf.h>
+int bounds_check_with_label __P((struct buf *bp, struct disklabel *lp,
+ int wlabel));
char *correct_readdisklabel __P((dev_t dev, d_strategy_t *strat,
struct disklabel *lp));
int correct_writedisklabel __P((dev_t dev, d_strategy_t *strat,
diff --git a/sys/sys/exec.h b/sys/sys/exec.h
index 28941b0..b47b11d 100644
--- a/sys/sys/exec.h
+++ b/sys/sys/exec.h
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)exec.h 8.3 (Berkeley) 1/21/94
- * $Id: exec.h,v 1.8 1994/10/02 17:24:41 phk Exp $
+ * $Id: exec.h,v 1.9 1994/10/09 21:50:57 sos Exp $
*/
#ifndef _SYS_EXEC_H_
@@ -64,15 +64,6 @@ struct ps_strings {
#define PS_STRINGS ((struct ps_strings *) \
(USRSTACK - sizeof(struct ps_strings) - SPARE_USRSPACE))
-/*
- * Arguments to the exec system call.
- */
-struct execve_args {
- char *fname;
- char **argv;
- char **envv;
-};
-
struct execsw {
int (*ex_imgact)(void * /* struct image_params * */);
const char *ex_name;
diff --git a/sys/sys/file.h b/sys/sys/file.h
index 9f8ae04..309a732 100644
--- a/sys/sys/file.h
+++ b/sys/sys/file.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)file.h 8.1 (Berkeley) 6/2/93
- * $Id: file.h,v 1.3 1994/08/21 04:41:45 paul Exp $
+ * $Id: file.h,v 1.4 1995/02/20 19:42:37 guido Exp $
*/
#ifndef _SYS_FILE_H_
@@ -74,6 +74,7 @@ struct file {
};
extern struct file *filehead; /* head of list of open files */
+extern struct fileops vnops;
extern int maxfiles; /* kernel limit on number of open files */
extern int maxfilesperproc; /* per process limit on number of open files */
extern int nfiles; /* actual number of open files */
diff --git a/sys/sys/filedesc.h b/sys/sys/filedesc.h
index abaf880..258695f 100644
--- a/sys/sys/filedesc.h
+++ b/sys/sys/filedesc.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)filedesc.h 8.1 (Berkeley) 6/2/93
- * $Id: filedesc.h,v 1.3 1994/08/21 04:41:46 paul Exp $
+ * $Id: filedesc.h,v 1.4 1994/10/02 17:24:44 phk Exp $
*/
#ifndef _SYS_FILEDESC_H_
@@ -95,6 +95,7 @@ struct filedesc0 {
/*
* Kernel global variables and routines.
*/
+int dupfdopen __P((struct filedesc *, int, int, int, int));
int fdalloc __P((struct proc *p, int want, int *result));
int fdavail __P((struct proc *p, int n));
int falloc __P((struct proc *p, struct file **resultfp, int *resultfd));
diff --git a/sys/sys/gmon.h b/sys/sys/gmon.h
index 5744584..b2526cde 100644
--- a/sys/sys/gmon.h
+++ b/sys/sys/gmon.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)gmon.h 8.2 (Berkeley) 1/4/94
- * $Id: gmon.h,v 1.2 1994/08/02 07:53:02 davidg Exp $
+ * $Id: gmon.h,v 1.3 1995/01/29 06:23:34 bde Exp $
*/
#ifndef _SYS_GMON_H_
@@ -154,6 +154,10 @@ extern struct gmonparam _gmonparam;
#define GMON_PROF_ERROR 2
#define GMON_PROF_OFF 3
+#ifdef KERNEL
+void kmstartup __P((void));
+#endif
+
/*
* Sysctl definitions for extracting profiling information from the kernel.
*/
diff --git a/sys/sys/kernel.h b/sys/sys/kernel.h
index 97f374a..bba2bc7 100644
--- a/sys/sys/kernel.h
+++ b/sys/sys/kernel.h
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)kernel.h 8.3 (Berkeley) 1/21/94
- * $Id: kernel.h,v 1.5 1994/09/23 19:07:41 wollman Exp $
+ * $Id: kernel.h,v 1.6 1994/10/05 21:23:38 wollman Exp $
*/
#ifndef _SYS_KERNEL_H_
@@ -63,7 +63,10 @@ extern int tick; /* usec per tick (1000000 / hz) */
extern int hz; /* system clock's frequency */
extern int stathz; /* statistics clock's frequency */
extern int profhz; /* profiling clock's frequency */
+extern int ticks;
extern int lbolt; /* once a second sleep address */
+extern int tickdelta;
+extern long timedelta;
/*
* The following macros are used to declare global sets of objects, which
@@ -87,4 +90,6 @@ struct linker_set {
caddr_t ls_items[1]; /* really ls_length of them, trailing NULL */
};
+extern const struct linker_set execsw_set;
+
#endif
diff --git a/sys/sys/ktrace.h b/sys/sys/ktrace.h
index 469f872..15f14b5 100644
--- a/sys/sys/ktrace.h
+++ b/sys/sys/ktrace.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)ktrace.h 8.1 (Berkeley) 6/2/93
- * $Id: ktrace.h,v 1.5 1994/09/27 21:26:56 phk Exp $
+ * $Id: ktrace.h,v 1.6 1994/10/02 17:24:48 phk Exp $
*/
#ifndef _SYS_KTRACE_H_
@@ -158,6 +158,8 @@ int ktrsetchildren __P((struct proc *,struct proc *,int,int,struct vnode *));
int ktrops __P((struct proc *,struct proc *,int,int,struct vnode *));
void ktrpsig __P((struct vnode *,int, sig_t, int, int));
void ktrgenio __P((struct vnode *,int, enum uio_rw,struct iovec *,int,int));
+void ktrsyscall __P((struct vnode *, int, int narg, int args[]));
+void ktrsysret __P((struct vnode *, int, int, int));
#else /* KERNEL */
diff --git a/sys/sys/libkern.h b/sys/sys/libkern.h
index c53fcb3..e32f72d 100644
--- a/sys/sys/libkern.h
+++ b/sys/sys/libkern.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)libkern.h 8.1 (Berkeley) 6/10/93
- * $Id: libkern.h,v 1.4 1994/09/18 23:04:25 bde Exp $
+ * $Id: libkern.h,v 1.5 1994/11/14 14:56:46 bde Exp $
*/
#include <sys/types.h>
@@ -58,6 +58,8 @@ char *rindex __P((const char *, int));
int scanc __P((u_int, u_char *, u_char *, int));
int skpc __P((int, int, char *));
char *strcat __P((char *, const char *));
+int strcmp __P((const char *, const char *));
char *strcpy __P((char *, const char *));
size_t strlen __P((const char *));
+int strncmp __P((const char *, const char *, size_t));
char *strncpy __P((char *, const char *, size_t));
diff --git a/sys/sys/linedisc.h b/sys/sys/linedisc.h
index 17844b1..04242b1 100644
--- a/sys/sys/linedisc.h
+++ b/sys/sys/linedisc.h
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)conf.h 8.3 (Berkeley) 1/21/94
- * $Id: conf.h,v 1.8 1995/02/09 13:51:25 davidg Exp $
+ * $Id: conf.h,v 1.9 1995/02/25 20:09:36 pst Exp $
*/
#ifndef _SYS_CONF_H_
@@ -120,6 +120,7 @@ struct linesw {
#ifdef KERNEL
extern struct linesw linesw[];
+extern int nlinesw;
#endif
struct swdevt {
diff --git a/sys/sys/mount.h b/sys/sys/mount.h
index 4b3e6e5..1801475 100644
--- a/sys/sys/mount.h
+++ b/sys/sys/mount.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)mount.h 8.13 (Berkeley) 3/27/94
- * $Id: mount.h,v 1.11 1994/09/27 20:39:50 phk Exp $
+ * $Id: mount.h,v 1.12 1994/10/20 00:48:21 wollman Exp $
*/
#ifndef _SYS_MOUNT_H_
@@ -208,6 +208,8 @@ struct vfsconf {
*/
#ifdef KERNEL
+extern int doforce; /* Flag to permit forcible unmounting. */
+extern struct vfsconf void_vfsconf;
extern struct vfsconf *vfsconf[];
#ifdef __STDC__
@@ -455,11 +457,14 @@ struct nfs_args {
#endif /* NFS */
#ifdef KERNEL
+extern int (*mountroot) __P((void));
+
/*
* exported vnode operations
*/
int dounmount __P((struct mount *, int, struct proc *));
struct mount *getvfs __P((fsid_t *)); /* return vfs given fsid */
+void getnewfsid __P((struct mount *mp, int mtype));
int vflush __P((struct mount *mp, struct vnode *skipvp, int flags));
int vfs_export /* process mount export info */
__P((struct mount *, struct netexport *, struct export_args *));
@@ -468,6 +473,7 @@ struct netcred *vfs_export_lookup /* lookup host in fs export list */
int vfs_lock __P((struct mount *)); /* lock a vfs */
int vfs_mountedon __P((struct vnode *)); /* is a vfs mounted on vp */
void vfs_unlock __P((struct mount *)); /* unlock a vfs */
+void vfs_unmountall __P((void));
int vfs_busy __P((struct mount *)); /* mark a vfs busy */
void vfs_unbusy __P((struct mount *)); /* mark a vfs not busy */
extern TAILQ_HEAD(mntlist, mount) mountlist; /* mounted filesystem list */
diff --git a/sys/sys/msgbuf.h b/sys/sys/msgbuf.h
index 3d2f4b0..5d5c56a 100644
--- a/sys/sys/msgbuf.h
+++ b/sys/sys/msgbuf.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)msgbuf.h 8.1 (Berkeley) 6/2/93
- * $Id: msgbuf.h,v 1.3 1994/08/18 22:35:44 wollman Exp $
+ * $Id: msgbuf.h,v 1.4 1994/08/21 04:41:54 paul Exp $
*/
#ifndef _SYS_MSGBUF_H_
@@ -46,6 +46,7 @@ struct msgbuf {
char msg_bufc[MSG_BSIZE]; /* buffer */
};
#ifdef KERNEL
+extern int msgbufmapped;
extern struct msgbuf *msgbufp;
#endif
diff --git a/sys/sys/proc.h b/sys/sys/proc.h
index 1f93309..9097d0b 100644
--- a/sys/sys/proc.h
+++ b/sys/sys/proc.h
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)proc.h 8.8 (Berkeley) 1/21/94
- * $Id: proc.h,v 1.15 1995/01/09 16:05:14 davidg Exp $
+ * $Id: proc.h,v 1.16 1995/02/21 00:37:31 davidg Exp $
*/
#ifndef _SYS_PROC_H_
@@ -265,6 +265,8 @@ struct proc *pfind __P((pid_t)); /* Find process by id. */
struct pgrp *pgfind __P((pid_t)); /* Find process group by id. */
void mi_switch __P((void));
void resetpriority __P((struct proc *));
+void roundrobin __P((void *));
+void schedcpu __P((void *));
void setrunnable __P((struct proc *));
void setrunqueue __P((struct proc *));
void remrq __P((struct proc *));
diff --git a/sys/sys/ptrace.h b/sys/sys/ptrace.h
index db29a9b..9c6c159 100644
--- a/sys/sys/ptrace.h
+++ b/sys/sys/ptrace.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)ptrace.h 8.2 (Berkeley) 1/4/94
- * $Id: ptrace.h,v 1.2 1994/08/02 07:53:24 davidg Exp $
+ * $Id: ptrace.h,v 1.3 1994/08/08 13:00:27 davidg Exp $
*/
#ifndef _SYS_PTRACE_H_
@@ -58,6 +58,9 @@
#ifdef KERNEL
void proc_reparent __P((struct proc *child, struct proc *newparent));
+int ptrace_set_pc __P((struct proc *p, unsigned int addr));
+int ptrace_single_step __P((struct proc *p));
+int ptrace_write_u __P((struct proc *p, vm_offset_t off, int data));
#else /* !KERNEL */
#include <sys/cdefs.h>
diff --git a/sys/sys/signalvar.h b/sys/sys/signalvar.h
index 0d980d9..9495c5f 100644
--- a/sys/sys/signalvar.h
+++ b/sys/sys/signalvar.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)signalvar.h 8.3 (Berkeley) 1/4/94
- * $Id: signalvar.h,v 1.3 1994/09/25 19:34:01 phk Exp $
+ * $Id: signalvar.h,v 1.4 1994/10/02 17:24:55 phk Exp $
*/
#ifndef _SYS_SIGNALVAR_H_ /* tmp for user.h */
@@ -158,6 +158,7 @@ void pgsignal __P((struct pgrp *pgrp, int sig, int checkctty));
void postsig __P((int sig));
int issignal __P((struct proc *p));
void psignal __P((struct proc *p, int sig));
+void sigexit __P((struct proc *, int));
void siginit __P((struct proc *p));
void trapsignal __P((struct proc *p, int sig, unsigned code));
diff --git a/sys/sys/syscall-hide.h b/sys/sys/syscall-hide.h
index 71e7da3..d944710 100644
--- a/sys/sys/syscall-hide.h
+++ b/sys/sys/syscall-hide.h
@@ -2,7 +2,7 @@
* System call hiders.
*
* DO NOT EDIT-- this file is automatically generated.
- * created from $Id: syscalls.master,v 1.12 1994/12/14 17:57:23 wollman Exp $
+ * created from $Id: syscalls.master,v 1.13 1995/03/04 03:24:26 davidg Exp $
*/
HIDE_POSIX(fork)
diff --git a/sys/sys/syscall.h b/sys/sys/syscall.h
index 5681b70..0431eac 100644
--- a/sys/sys/syscall.h
+++ b/sys/sys/syscall.h
@@ -2,7 +2,7 @@
* System call numbers.
*
* DO NOT EDIT-- this file is automatically generated.
- * created from $Id: syscalls.master,v 1.12 1994/12/14 17:57:23 wollman Exp $
+ * created from $Id: syscalls.master,v 1.13 1995/03/04 03:24:26 davidg Exp $
*/
#define SYS_syscall 0
diff --git a/sys/sys/sysctl.h b/sys/sys/sysctl.h
index 009671c..6ed3cbc 100644
--- a/sys/sys/sysctl.h
+++ b/sys/sys/sysctl.h
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)sysctl.h 8.1 (Berkeley) 6/2/93
- * $Id: sysctl.h,v 1.19 1994/11/14 13:59:09 bde Exp $
+ * $Id: sysctl.h,v 1.20 1995/02/20 19:42:40 guido Exp $
*/
#ifndef _SYS_SYSCTL_H_
@@ -344,6 +344,12 @@ extern struct ctldebug debug10, debug11, debug12, debug13, debug14;
extern struct ctldebug debug15, debug16, debug17, debug18, debug19;
#endif /* DEBUG */
+extern char cpu_model[];
+extern int hw_float;
+extern char machine[];
+extern char osrelease[];
+extern char ostype[];
+
/*
* Internal sysctl function calling convention:
*
@@ -370,12 +376,14 @@ int sysctl_rdint __P((void *, size_t *, void *, int));
int sysctl_string __P((void *, size_t *, void *, size_t, char *, int));
int sysctl_rdstring __P((void *, size_t *, void *, char *));
int sysctl_rdstruct __P((void *, size_t *, void *, void *, int));
+int sysctl_struct __P((void *oldp, size_t *, void *, size_t, void *, int));
void fill_eproc __P((struct proc *, struct eproc *));
int sysctl_clockrate __P((char *, size_t*));
int sysctl_vnode __P((char *, size_t*));
int sysctl_file __P((char *, size_t*));
int sysctl_doproc __P((int *, u_int, char *, size_t*));
+int sysctl_doprof __P((int *, u_int, void *, size_t *, void *, size_t));
#else /* !KERNEL */
#include <sys/cdefs.h>
diff --git a/sys/sys/sysent.h b/sys/sys/sysent.h
index 64ac5bb..f2953a6 100644
--- a/sys/sys/sysent.h
+++ b/sys/sys/sysent.h
@@ -30,7 +30,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: sysent.h,v 1.2 1994/10/09 21:53:05 sos Exp $
+ * $Id: sysent.h,v 1.3 1995/02/14 19:23:20 sos Exp $
*/
#ifndef _SYS_SYSENT_H_
@@ -53,6 +53,7 @@ struct sysentvec {
};
#ifdef KERNEL
+extern struct sysentvec aout_sysvec;
extern struct sysent sysent[];
#endif
diff --git a/sys/sys/systm.h b/sys/sys/systm.h
index 3ba0b04..86c9da2 100644
--- a/sys/sys/systm.h
+++ b/sys/sys/systm.h
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)systm.h 8.4 (Berkeley) 2/23/94
- * $Id: systm.h,v 1.13 1994/10/10 00:58:35 phk Exp $
+ * $Id: systm.h,v 1.14 1995/02/14 06:15:25 phk Exp $
*/
#ifndef _SYS_SYSTM_H_
@@ -72,6 +72,8 @@
* patched by a stalking hacker.
*/
extern int securelevel; /* system security level */
+
+extern int cold; /* nonzero if we are doing a cold boot */
extern const char *panicstr; /* panic message */
extern char version[]; /* system version */
extern char copyright[]; /* system copyright */
@@ -174,10 +176,20 @@ extern void cpu_initclocks(void);
extern void vntblinit(void);
extern void nchinit(void);
+/* Finalize the world. */
+void shutdown_nice __P((void));
+
extern __dead void vm_pageout(void) __dead2; /* pagedaemon, called in proc 2 */
extern __dead void vfs_update(void) __dead2; /* update, called in proc 3 */
extern __dead void scheduler(void) __dead2; /* sched, called in process 0 */
+/*
+ * Kernel to clock driver interface.
+ */
+void inittodr __P((time_t base));
+void resettodr __P((void));
+void startrtclock __P((void));
+
/* Timeouts */
typedef void (timeout_t)(void *); /* actual timeout function type */
typedef timeout_t *timeout_func_t; /* a pointer to this type */
@@ -186,4 +198,30 @@ void timeout(timeout_func_t, void *, int);
void untimeout(timeout_func_t, void *);
void logwakeup __P((void));
+/* Syscalls that are called internally. */
+struct execve_args {
+ char *fname;
+ char **argv;
+ char **envv;
+};
+int execve __P((struct proc *, struct execve_args *, int *retval));
+struct fork_args {
+ int dummy;
+};
+int fork __P((struct proc *, struct fork_args *, int retval[]));
+struct sync_args {
+ int dummy;
+};
+int sync __P((struct proc *, struct sync_args *, int *retval));
+struct wait_args {
+ int pid;
+ int *status;
+ int options;
+ struct rusage *rusage;
+#if defined(COMPAT_43) || defined(COMPAT_IBCS2)
+ int compat; /* pseudo */
+#endif
+};
+int wait1 __P((struct proc *, struct wait_args *, int retval[]));
+
#endif /* !_SYS_SYSTM_H_ */
diff --git a/sys/sys/tty.h b/sys/sys/tty.h
index 6683a73..959fad5 100644
--- a/sys/sys/tty.h
+++ b/sys/sys/tty.h
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)tty.h 8.6 (Berkeley) 1/21/94
- * $Id: tty.h,v 1.11 1995/02/25 20:09:44 pst Exp $
+ * $Id: tty.h,v 1.12 1995/02/28 00:21:11 pst Exp $
*/
#ifndef _SYS_TTY_H_
@@ -184,6 +184,7 @@ struct speedtab {
(isctty((p), (tp)) && (p)->p_pgrp != (tp)->t_pgrp)
#ifdef KERNEL
+extern struct tty *constty; /* Temporary virtual console. */
extern struct ttychars ttydefaults;
/* Symbolic sleep message strings. */
@@ -202,6 +203,8 @@ int putc __P((int c, struct clist *q));
int q_to_b __P((struct clist *q, char *cp, int cc));
int unputc __P((struct clist *q));
+int ttcompat __P((struct tty *tp, int com, caddr_t data, int flag));
+
int nullmodem __P((struct tty *tp, int flag));
int tputchar __P((int c, struct tty *tp));
int ttioctl __P((struct tty *tp, int com, void *data, int flag));
diff --git a/sys/sys/vnode.h b/sys/sys/vnode.h
index dfb7214..63598bb 100644
--- a/sys/sys/vnode.h
+++ b/sys/sys/vnode.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)vnode.h 8.7 (Berkeley) 2/4/94
- * $Id: vnode.h,v 1.15 1995/01/05 16:22:17 gibbs Exp $
+ * $Id: vnode.h,v 1.16 1995/03/07 19:00:47 davidg Exp $
*/
#ifndef _SYS_VNODE_H_
@@ -223,6 +223,7 @@ void vhold __P((struct vnode *));
*/
extern struct vnode *rootvnode; /* root (i.e. "/") vnode */
extern int desiredvnodes; /* number of vnodes desired */
+extern int prtactive; /* nonzero to call vprint() */
extern struct vattr va_null; /* predefined null vattr structure */
/*
diff --git a/sys/ufs/ffs/ffs_vfsops.c b/sys/ufs/ffs/ffs_vfsops.c
index 6ba5040..be81fcd 100644
--- a/sys/ufs/ffs/ffs_vfsops.c
+++ b/sys/ufs/ffs/ffs_vfsops.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)ffs_vfsops.c 8.8 (Berkeley) 4/18/94
- * $Id: ffs_vfsops.c,v 1.11 1994/10/28 12:42:03 jkh Exp $
+ * $Id: ffs_vfsops.c,v 1.12 1994/11/14 13:21:42 bde Exp $
*/
#include <sys/param.h>
@@ -60,8 +60,6 @@
#include <ufs/ffs/fs.h>
#include <ufs/ffs/ffs_extern.h>
-#include <machine/clock.h> /* What is inittodr() doing in a fs anyway ? */
-
int ffs_sbupdate __P((struct ufsmount *, int));
int ffs_flushfiles __P((struct mount *, int, struct proc *));
int ffs_reload __P((struct mount *,struct ucred *,struct proc *));
@@ -552,7 +550,6 @@ ffs_flushfiles(mp, flags, p)
int flags;
struct proc *p;
{
- extern int doforce;
register struct ufsmount *ump;
int error;
diff --git a/sys/ufs/lfs/lfs_vfsops.c b/sys/ufs/lfs/lfs_vfsops.c
index 6c9f55f..27b46c1 100644
--- a/sys/ufs/lfs/lfs_vfsops.c
+++ b/sys/ufs/lfs/lfs_vfsops.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)lfs_vfsops.c 8.7 (Berkeley) 4/16/94
- * $Id: lfs_vfsops.c,v 1.8 1994/11/14 13:21:53 bde Exp $
+ * $Id: lfs_vfsops.c,v 1.9 1994/11/17 01:30:53 gibbs Exp $
*/
#include <sys/param.h>
@@ -322,7 +322,6 @@ lfs_unmount(mp, mntflags, p)
int mntflags;
struct proc *p;
{
- extern int doforce;
register struct ufsmount *ump;
register struct lfs *fs;
int i, error, flags, ronly;
diff --git a/sys/ufs/mfs/mfs_vfsops.c b/sys/ufs/mfs/mfs_vfsops.c
index d145208..79822d7 100644
--- a/sys/ufs/mfs/mfs_vfsops.c
+++ b/sys/ufs/mfs/mfs_vfsops.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)mfs_vfsops.c 8.4 (Berkeley) 4/16/94
- * $Id: mfs_vfsops.c,v 1.4 1994/08/18 22:35:55 wollman Exp $
+ * $Id: mfs_vfsops.c,v 1.5 1994/09/21 03:47:42 wollman Exp $
*/
#include <sys/param.h>
@@ -157,7 +157,6 @@ mfs_initminiroot(base)
caddr_t base;
{
struct fs *fs = (struct fs *)(base + SBOFF);
- extern int (*mountroot)();
/* check for valid super block */
if (fs->fs_magic != FS_MAGIC || fs->fs_bsize > MAXBSIZE ||
diff --git a/sys/ufs/ufs/ufs_vnops.c b/sys/ufs/ufs/ufs_vnops.c
index 6b48c7e..8bf1ef3 100644
--- a/sys/ufs/ufs/ufs_vnops.c
+++ b/sys/ufs/ufs/ufs_vnops.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)ufs_vnops.c 8.10 (Berkeley) 4/1/94
- * $Id: ufs_vnops.c,v 1.15 1995/02/14 06:12:26 phk Exp $
+ * $Id: ufs_vnops.c,v 1.16 1995/03/11 22:23:14 davidg Exp $
*/
#include <sys/param.h>
@@ -1754,8 +1754,6 @@ ufsfifo_read(ap)
struct ucred *a_cred;
} */ *ap;
{
- extern int (**fifo_vnodeop_p)();
-
/*
* Set access flag.
*/
@@ -1775,8 +1773,6 @@ ufsfifo_write(ap)
struct ucred *a_cred;
} */ *ap;
{
- extern int (**fifo_vnodeop_p)();
-
/*
* Set update and change flags.
*/
@@ -1798,7 +1794,6 @@ ufsfifo_close(ap)
struct proc *a_p;
} */ *ap;
{
- extern int (**fifo_vnodeop_p)();
register struct inode *ip = VTOI(ap->a_vp);
if (ap->a_vp->v_usecount > 1 && !(ip->i_flag & IN_LOCKED))
diff --git a/sys/vm/vm_extern.h b/sys/vm/vm_extern.h
index 50807a0..2dae26e 100644
--- a/sys/vm/vm_extern.h
+++ b/sys/vm/vm_extern.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)vm_extern.h 8.2 (Berkeley) 1/12/94
- * $Id: vm_extern.h,v 1.11 1995/02/20 23:58:09 davidg Exp $
+ * $Id: vm_extern.h,v 1.12 1995/02/21 01:32:47 davidg Exp $
*/
#ifndef _VM_EXTERN_H_
@@ -62,6 +62,8 @@ void thread_sleep_ __P((int, simple_lock_t, char *));
#endif
#ifdef KERNEL
+extern int indent;
+
#ifdef TYPEDEF_FOR_UAP
int getpagesize __P((struct proc * p, void *, int *));
int madvise __P((struct proc *, void *, int *));
@@ -73,10 +75,12 @@ int obreak __P((struct proc *, void *, int *));
int sbrk __P((struct proc *, void *, int *));
int smmap __P((struct proc *, void *, int *));
int sstk __P((struct proc *, void *, int *));
+int swapon __P((struct proc *, void *, int *));
#endif
void assert_wait __P((int, boolean_t));
+void faultin __P((struct proc *p));
int grow __P((struct proc *, u_int));
void iprintf __P((const char *,...));
int kernacc __P((caddr_t, int, int));
@@ -95,7 +99,6 @@ void munmapfd __P((struct proc *, int));
int pager_cache __P((vm_object_t, boolean_t));
void sched __P((void));
void swapinit __P((void));
-int swapon __P((struct proc *, void *, int *));
void swapout __P((struct proc *));
void swapout_threads __P((void));
int swfree __P((struct proc *, int));
@@ -119,6 +122,7 @@ struct vmspace *vmspace_alloc __P((vm_offset_t, vm_offset_t, int));
struct vmspace *vmspace_fork __P((struct vmspace *));
void vmspace_free __P((struct vmspace *));
void vmtotal __P((struct vmtotal *));
+vm_pager_t vnode_pager_alloc __P((caddr_t, vm_offset_t, vm_prot_t, vm_offset_t));
void vnode_pager_setsize __P((struct vnode *, u_long));
void vnode_pager_umount __P((struct mount *));
boolean_t vnode_pager_uncache __P((struct vnode *));
diff --git a/sys/vm/vm_init.c b/sys/vm/vm_init.c
index 6406c1e..64f3814 100644
--- a/sys/vm/vm_init.c
+++ b/sys/vm/vm_init.c
@@ -61,7 +61,7 @@
* any improvements or extensions that they make and grant Carnegie the
* rights to redistribute these changes.
*
- * $Id: vm_init.c,v 1.4 1994/10/09 01:52:09 phk Exp $
+ * $Id: vm_init.c,v 1.5 1995/01/09 16:05:42 davidg Exp $
*/
/*
@@ -85,9 +85,6 @@
void
vm_mem_init()
{
- extern vm_offset_t avail_start, avail_end;
- extern vm_offset_t virtual_avail, virtual_end;
-
/*
* Initializes resident memory structures. From here on, all physical
* memory is accounted for, and we use only virtual addresses.
diff --git a/sys/vm/vm_map.c b/sys/vm/vm_map.c
index 43cf626..4055b98 100644
--- a/sys/vm/vm_map.c
+++ b/sys/vm/vm_map.c
@@ -61,7 +61,7 @@
* any improvements or extensions that they make and grant Carnegie the
* rights to redistribute these changes.
*
- * $Id: vm_map.c,v 1.15 1995/02/21 01:13:05 davidg Exp $
+ * $Id: vm_map.c,v 1.16 1995/03/01 23:29:56 davidg Exp $
*/
/*
@@ -71,6 +71,7 @@
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/malloc.h>
+#include <sys/proc.h>
#include <vm/vm.h>
#include <vm/vm_page.h>
@@ -2608,7 +2609,6 @@ vm_map_print(map, full)
boolean_t full;
{
register vm_map_entry_t entry;
- extern int indent;
iprintf("%s map 0x%x: pmap=0x%x,ref=%d,nentries=%d,version=%d\n",
(map->is_main_map ? "Task" : "Share"),
diff --git a/sys/vm/vm_map.h b/sys/vm/vm_map.h
index c940e8a..f250144 100644
--- a/sys/vm/vm_map.h
+++ b/sys/vm/vm_map.h
@@ -61,7 +61,7 @@
* any improvements or extensions that they make and grant Carnegie the
* rights to redistribute these changes.
*
- * $Id: vm_map.h,v 1.3 1994/08/02 07:55:26 davidg Exp $
+ * $Id: vm_map.h,v 1.4 1995/01/09 16:05:46 davidg Exp $
*/
/*
@@ -181,6 +181,9 @@ typedef struct {
#define MAX_KMAPENT 128
#ifdef KERNEL
+extern vm_offset_t kentry_data;
+extern vm_size_t kentry_data_size;
+
boolean_t vm_map_check_protection __P((vm_map_t, vm_offset_t, vm_offset_t, vm_prot_t));
int vm_map_copy __P((vm_map_t, vm_map_t, vm_offset_t, vm_size_t, vm_offset_t, boolean_t, boolean_t));
void vm_map_copy_entry __P((vm_map_t, vm_map_t, vm_map_entry_t, vm_map_entry_t));
diff --git a/sys/vm/vm_mmap.c b/sys/vm/vm_mmap.c
index 03324bc..b858702 100644
--- a/sys/vm/vm_mmap.c
+++ b/sys/vm/vm_mmap.c
@@ -38,7 +38,7 @@
* from: Utah $Hdr: vm_mmap.c 1.6 91/10/21$
*
* @(#)vm_mmap.c 8.4 (Berkeley) 1/12/94
- * $Id: vm_mmap.c,v 1.12 1995/03/07 17:27:49 davidg Exp $
+ * $Id: vm_mmap.c,v 1.13 1995/03/12 08:11:34 davidg Exp $
*/
/*
@@ -59,6 +59,7 @@
#include <vm/vm.h>
#include <vm/vm_pager.h>
+#include <vm/vm_pageout.h>
#include <vm/vm_prot.h>
#ifdef DEBUG
@@ -528,7 +529,6 @@ mlock(p, uap, retval)
vm_offset_t addr;
vm_size_t size;
int error;
- extern int vm_page_max_wired;
#ifdef DEBUG
if (mmapdebug & MDB_FOLLOW)
diff --git a/sys/vm/vm_object.c b/sys/vm/vm_object.c
index d0410b5..de9b90e 100644
--- a/sys/vm/vm_object.c
+++ b/sys/vm/vm_object.c
@@ -61,7 +61,7 @@
* any improvements or extensions that they make and grant Carnegie the
* rights to redistribute these changes.
*
- * $Id: vm_object.c,v 1.30 1995/03/12 07:58:28 davidg Exp $
+ * $Id: vm_object.c,v 1.31 1995/03/12 08:08:06 davidg Exp $
*/
/*
@@ -1694,7 +1694,6 @@ vm_object_print(object, full)
boolean_t full;
{
register vm_page_t p;
- extern indent;
register int count;
diff --git a/sys/vm/vm_object.h b/sys/vm/vm_object.h
index c788cf7..11ff6a6 100644
--- a/sys/vm/vm_object.h
+++ b/sys/vm/vm_object.h
@@ -61,7 +61,7 @@
* any improvements or extensions that they make and grant Carnegie the
* rights to redistribute these changes.
*
- * $Id: vm_object.h,v 1.11 1995/03/12 08:05:46 davidg Exp $
+ * $Id: vm_object.h,v 1.12 1995/03/12 12:42:00 bde Exp $
*/
/*
@@ -71,6 +71,10 @@
#ifndef _VM_OBJECT_
#define _VM_OBJECT_
+#ifdef KERNEL
+#include <sys/proc.h> /* XXX for wakeup() */
+#endif
+
#include <vm/vm_page.h>
#include <vm/vm_pager.h>
@@ -120,6 +124,8 @@ struct vm_object_hash_entry {
typedef struct vm_object_hash_entry *vm_object_hash_entry_t;
#ifdef KERNEL
+extern int vm_object_cache_max;
+
TAILQ_HEAD(object_q, vm_object);
struct object_q vm_object_cached_list; /* list of objects persisting */
diff --git a/sys/vm/vm_page.c b/sys/vm/vm_page.c
index cdac17c..71eb2ef 100644
--- a/sys/vm/vm_page.c
+++ b/sys/vm/vm_page.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* from: @(#)vm_page.c 7.4 (Berkeley) 5/7/91
- * $Id: vm_page.c,v 1.22 1995/02/22 10:27:16 davidg Exp $
+ * $Id: vm_page.c,v 1.23 1995/03/01 23:29:59 davidg Exp $
*/
/*
@@ -73,6 +73,7 @@
#include <sys/proc.h>
#include <vm/vm.h>
+#include <vm/vm_kern.h>
#include <vm/vm_page.h>
#include <vm/vm_map.h>
#include <vm/vm_pageout.h>
@@ -165,10 +166,6 @@ vm_page_startup(starta, enda, vaddr)
int nblocks;
vm_offset_t first_managed_page;
- extern vm_offset_t kentry_data;
- extern vm_size_t kentry_data_size;
- extern vm_offset_t phys_avail[];
-
/* the biggest memory array is the second group of pages */
vm_offset_t start;
vm_offset_t biggestone, biggestsize;
@@ -693,7 +690,6 @@ vm_page_alloc_contig(size, low, high, alignment)
int i, s, start;
vm_offset_t addr, phys, tmp_addr;
vm_page_t pga = vm_page_array;
- extern vm_map_t kernel_map;
if ((alignment & (alignment - 1)) != 0)
panic("vm_page_alloc_contig: alignment must be a power of 2");
diff --git a/sys/vm/vm_pageout.c b/sys/vm/vm_pageout.c
index 36851bc..b3c0966 100644
--- a/sys/vm/vm_pageout.c
+++ b/sys/vm/vm_pageout.c
@@ -65,7 +65,7 @@
* any improvements or extensions that they make and grant Carnegie the
* rights to redistribute these changes.
*
- * $Id: vm_pageout.c,v 1.40 1995/03/01 23:30:02 davidg Exp $
+ * $Id: vm_pageout.c,v 1.41 1995/03/12 07:58:29 davidg Exp $
*/
/*
@@ -74,6 +74,7 @@
#include <sys/param.h>
#include <sys/systm.h>
+#include <sys/kernel.h>
#include <sys/proc.h>
#include <sys/resourcevar.h>
#include <sys/malloc.h>
@@ -472,7 +473,6 @@ vm_pageout_map_deactivate_pages(map, entry, count, freeer)
void
vm_req_vmdaemon()
{
- extern int ticks;
static int lastrun = 0;
if ((ticks > (lastrun + hz / 10)) || (ticks < lastrun)) {
diff --git a/sys/vm/vm_pageout.h b/sys/vm/vm_pageout.h
index 6e77a33..b44fe3d 100644
--- a/sys/vm/vm_pageout.h
+++ b/sys/vm/vm_pageout.h
@@ -61,7 +61,7 @@
* any improvements or extensions that they make and grant Carnegie the
* rights to redistribute these changes.
*
- * $Id: vm_pageout.h,v 1.8 1995/01/10 07:32:50 davidg Exp $
+ * $Id: vm_pageout.h,v 1.9 1995/03/01 23:30:03 davidg Exp $
*/
#ifndef _VM_VM_PAGEOUT_H_
@@ -75,6 +75,7 @@
* Exported data structures.
*/
+extern int vm_page_max_wired;
extern int vm_pages_needed; /* should be some "event" structure */
simple_lock_data_t vm_pages_needed_lock;
extern int vm_pageout_pages_needed;
@@ -124,6 +125,7 @@ vm_wait()
#ifdef KERNEL
+void vm_daemon __P((void));
int vm_pageout_scan __P((void));
void vm_pageout_page __P((vm_page_t, vm_object_t));
void vm_pageout_cluster __P((vm_page_t, vm_object_t));
diff --git a/sys/vm/vm_pager.h b/sys/vm/vm_pager.h
index 939b727..9dfbe73 100644
--- a/sys/vm/vm_pager.h
+++ b/sys/vm/vm_pager.h
@@ -37,7 +37,7 @@
* SUCH DAMAGE.
*
* @(#)vm_pager.h 8.4 (Berkeley) 1/12/94
- * $Id: vm_pager.h,v 1.4 1994/10/09 01:52:17 phk Exp $
+ * $Id: vm_pager.h,v 1.5 1995/01/09 16:05:56 davidg Exp $
*/
/*
@@ -108,6 +108,7 @@ extern struct pagerops *dfltpagerops;
vm_pager_t vm_pager_allocate __P((int, caddr_t, vm_size_t, vm_prot_t, vm_offset_t));
vm_page_t vm_pager_atop __P((vm_offset_t));
+void vm_pager_bufferinit __P((void));
void vm_pager_deallocate __P((vm_pager_t));
int vm_pager_get_pages __P((vm_pager_t, vm_page_t *, int, int, boolean_t));
boolean_t vm_pager_has_page __P((vm_pager_t, vm_offset_t));
diff --git a/sys/vm/vm_swap.c b/sys/vm/vm_swap.c
index 30641df..c09dbf7 100644
--- a/sys/vm/vm_swap.c
+++ b/sys/vm/vm_swap.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)vm_swap.c 8.5 (Berkeley) 2/17/94
- * $Id: vm_swap.c,v 1.13 1995/01/09 16:05:58 davidg Exp $
+ * $Id: vm_swap.c,v 1.14 1995/01/10 07:32:51 davidg Exp $
*/
#include <sys/param.h>
@@ -45,6 +45,8 @@
#include <sys/file.h>
#include <sys/rlist.h>
+#include <vm/vm.h>
+
#include <miscfs/specfs/specdev.h>
/*
diff --git a/sys/vm/vnode_pager.c b/sys/vm/vnode_pager.c
index 05dcc45..099ff14 100644
--- a/sys/vm/vnode_pager.c
+++ b/sys/vm/vnode_pager.c
@@ -37,7 +37,7 @@
* SUCH DAMAGE.
*
* from: @(#)vnode_pager.c 7.5 (Berkeley) 4/20/91
- * $Id: vnode_pager.c,v 1.28 1995/03/07 19:04:10 davidg Exp $
+ * $Id: vnode_pager.c,v 1.29 1995/03/12 07:56:06 davidg Exp $
*/
/*
@@ -85,7 +85,6 @@
int vnode_pager_putmulti();
void vnode_pager_init();
-vm_pager_t vnode_pager_alloc(caddr_t, vm_offset_t, vm_prot_t, vm_offset_t);
void vnode_pager_dealloc();
int vnode_pager_getpage();
int vnode_pager_getmulti();
OpenPOWER on IntegriCloud