summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/arch/i386/eisa/eisa_machdep.c33
-rw-r--r--sys/arch/i386/i386/apic.c10
-rw-r--r--sys/arch/i386/i386/autoconf.c18
-rw-r--r--sys/arch/i386/i386/conf.c15
-rw-r--r--sys/arch/i386/i386/db_disasm.c25
-rw-r--r--sys/arch/i386/i386/db_interface.c19
-rw-r--r--sys/arch/i386/i386/db_trace.c27
-rw-r--r--sys/arch/i386/i386/disksubr.c34
-rw-r--r--sys/arch/i386/i386/freebsd_machdep.c38
-rw-r--r--sys/arch/i386/i386/i686_mem.c44
-rw-r--r--sys/arch/i386/i386/ipx_cksum.c12
-rw-r--r--sys/arch/i386/i386/kgdb_machdep.c17
-rw-r--r--sys/arch/i386/i386/linux_machdep.c63
-rw-r--r--sys/arch/i386/i386/lock_machdep.c14
-rw-r--r--sys/arch/i386/i386/machdep.c17
-rw-r--r--sys/arch/i386/i386/mem.c39
-rw-r--r--sys/arch/i386/i386/mpbios.c79
-rw-r--r--sys/arch/i386/i386/mtrr.c6
-rw-r--r--sys/arch/i386/i386/pctr.c40
-rw-r--r--sys/arch/i386/i386/pmap.c119
-rw-r--r--sys/arch/i386/i386/process_machdep.c26
-rw-r--r--sys/arch/i386/i386/rbus_machdep.c10
-rw-r--r--sys/arch/i386/i386/svr4_machdep.c39
-rw-r--r--sys/arch/i386/i386/sys_machdep.c36
-rw-r--r--sys/arch/i386/i386/trap.c24
-rw-r--r--sys/arch/i386/i386/vm86.c23
-rw-r--r--sys/arch/i386/i386/vm_machdep.c30
-rw-r--r--sys/arch/i386/isa/ahc_isa.c23
-rw-r--r--sys/arch/i386/isa/clock.c56
-rw-r--r--sys/arch/i386/isa/isa_machdep.c156
-rw-r--r--sys/arch/i386/isa/isapnp_machdep.c14
-rw-r--r--sys/arch/i386/isa/joy.c26
-rw-r--r--sys/arch/i386/isa/joy_isa.c10
-rw-r--r--sys/arch/i386/isa/joy_isapnp.c10
-rw-r--r--sys/arch/i386/isa/lms.c27
-rw-r--r--sys/arch/i386/isa/mms.c27
-rw-r--r--sys/arch/i386/isa/npx.c16
-rw-r--r--sys/arch/i386/isa/pccom.c140
-rw-r--r--sys/arch/i386/pci/amd756.c33
-rw-r--r--sys/arch/i386/pci/opti82c558.c30
-rw-r--r--sys/arch/i386/pci/opti82c700.c33
-rw-r--r--sys/arch/i386/pci/pchb.c17
-rw-r--r--sys/arch/i386/pci/pci_addr_fixup.c81
-rw-r--r--sys/arch/i386/pci/pci_intr_fixup.c31
-rw-r--r--sys/arch/i386/pci/pci_machdep.c53
-rw-r--r--sys/arch/i386/pci/pcib.c17
-rw-r--r--sys/arch/i386/pci/pcibios.c44
-rw-r--r--sys/arch/i386/pci/pcic_pci_machdep.c23
-rw-r--r--sys/arch/i386/pci/pciide_machdep.c10
-rw-r--r--sys/arch/i386/pci/piix.c33
-rw-r--r--sys/arch/i386/pci/sis85c503.c22
-rw-r--r--sys/arch/i386/pci/via8231.c34
-rw-r--r--sys/arch/i386/pci/via82c586.c30
53 files changed, 529 insertions, 1324 deletions
diff --git a/sys/arch/i386/eisa/eisa_machdep.c b/sys/arch/i386/eisa/eisa_machdep.c
index 5191fe93fe9..3473982f6f0 100644
--- a/sys/arch/i386/eisa/eisa_machdep.c
+++ b/sys/arch/i386/eisa/eisa_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: eisa_machdep.c,v 1.9 2006/04/15 01:44:06 weingart Exp $ */
+/* $OpenBSD: eisa_machdep.c,v 1.10 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: eisa_machdep.c,v 1.10.22.2 2000/06/25 19:36:58 sommerfeld Exp $ */
/*-
@@ -108,19 +108,15 @@ struct i386_bus_dma_tag eisa_bus_dma_tag = {
};
void
-eisa_attach_hook(parent, self, eba)
- struct device *parent, *self;
- struct eisabus_attach_args *eba;
+eisa_attach_hook(struct device *parent, struct device *self,
+ struct eisabus_attach_args *eba)
{
-
/* Nothing to do */
}
int
-eisa_maxslots(ec)
- eisa_chipset_tag_t ec;
+eisa_maxslots(eisa_chipset_tag_t ec)
{
-
/*
* Always try 16 slots.
*/
@@ -128,10 +124,7 @@ eisa_maxslots(ec)
}
int
-eisa_intr_map(ec, irq, ihp)
- eisa_chipset_tag_t ec;
- u_int irq;
- eisa_intr_handle_t *ihp;
+eisa_intr_map(eisa_chipset_tag_t ec, u_int irq, eisa_intr_handle_t *ihp)
{
#if NIOAPIC > 0
struct mp_intr_map *mip;
@@ -172,9 +165,7 @@ eisa_intr_map(ec, irq, ihp)
}
const char *
-eisa_intr_string(ec, ih)
- eisa_chipset_tag_t ec;
- eisa_intr_handle_t ih;
+eisa_intr_string(eisa_chipset_tag_t ec, eisa_intr_handle_t ih)
{
static char irqstr[64];
@@ -195,12 +186,8 @@ eisa_intr_string(ec, ih)
}
void *
-eisa_intr_establish(ec, ih, type, level, func, arg, what)
- eisa_chipset_tag_t ec;
- eisa_intr_handle_t ih;
- int type, level, (*func)(void *);
- void *arg;
- char *what;
+eisa_intr_establish(eisa_chipset_tag_t ec, eisa_intr_handle_t ih, int type,
+ int level, int (*func)(void *), void *arg, char *what)
{
#if NIOAPIC > 0
if (ih != -1) {
@@ -217,9 +204,7 @@ eisa_intr_establish(ec, ih, type, level, func, arg, what)
}
void
-eisa_intr_disestablish(ec, cookie)
- eisa_chipset_tag_t ec;
- void *cookie;
+eisa_intr_disestablish(eisa_chipset_tag_t ec, void *cookie)
{
return (isa_intr_disestablish(NULL, cookie));
}
diff --git a/sys/arch/i386/i386/apic.c b/sys/arch/i386/i386/apic.c
index 9e80d1d50bb..3436ae5d075 100644
--- a/sys/arch/i386/i386/apic.c
+++ b/sys/arch/i386/i386/apic.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: apic.c,v 1.3 2006/05/29 20:40:58 miod Exp $ */
+/* $OpenBSD: apic.c,v 1.4 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: apic.c,v 1.1.2.2 2000/02/21 18:51:00 sommerfeld Exp $ */
/*-
@@ -47,12 +47,8 @@
#include <machine/apicvar.h>
void
-apic_format_redir(where1, where2, idx, redirhi, redirlo)
- char *where1;
- char *where2;
- int idx;
- u_int32_t redirhi;
- u_int32_t redirlo;
+apic_format_redir(char *where1, char *where2, int idx, u_int32_t redirhi,
+ u_int32_t redirlo)
{
printf("%s: %s%d 0x%x", where1, where2, idx, redirlo);
diff --git a/sys/arch/i386/i386/autoconf.c b/sys/arch/i386/i386/autoconf.c
index acb029af883..b10b6c34480 100644
--- a/sys/arch/i386/i386/autoconf.c
+++ b/sys/arch/i386/i386/autoconf.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: autoconf.c,v 1.64 2006/06/14 19:46:54 gwk Exp $ */
+/* $OpenBSD: autoconf.c,v 1.65 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: autoconf.c,v 1.20 1996/05/03 19:41:56 christos Exp $ */
/*-
@@ -106,7 +106,7 @@ extern int i386_has_xcrypt;
* Determine i/o configuration for a machine.
*/
void
-cpu_configure()
+cpu_configure(void)
{
/*
* Note, on i386, configure is not running under splhigh unlike other
@@ -177,7 +177,7 @@ cpu_configure()
* always determine the correct root disk.
*/
void
-diskconf()
+diskconf(void)
{
/*
* Configure root, swap, and dump area. This is
@@ -210,8 +210,7 @@ static struct {
};
int
-findblkmajor(dv)
- struct device *dv;
+findblkmajor(struct device *dv)
{
char *name = dv->dv_xname;
int i;
@@ -224,8 +223,7 @@ findblkmajor(dv)
}
char *
-findblkname(maj)
- int maj;
+findblkname(int maj)
{
int i;
@@ -245,7 +243,7 @@ long dumplo;
* change rootdev to correspond to the load device.
*/
void
-setroot()
+setroot(void)
{
int majdev, mindev, unit, part, adaptor;
struct swdevt *swp;
@@ -389,9 +387,9 @@ struct genericconf {
};
void
-rootconf()
+rootconf(void)
{
- register struct genericconf *gc;
+ struct genericconf *gc;
int unit, part = 0;
#if defined(NFSCLIENT)
struct ifnet *ifp;
diff --git a/sys/arch/i386/i386/conf.c b/sys/arch/i386/i386/conf.c
index a156071731e..60b851ce105 100644
--- a/sys/arch/i386/i386/conf.c
+++ b/sys/arch/i386/i386/conf.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: conf.c,v 1.113 2006/06/11 10:56:39 mk Exp $ */
+/* $OpenBSD: conf.c,v 1.114 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: conf.c,v 1.75 1996/05/03 19:40:20 christos Exp $ */
/*
@@ -337,10 +337,8 @@ dev_t swapdev = makedev(1, 0);
* Returns true if dev is /dev/mem or /dev/kmem.
*/
int
-iskmemdev(dev)
- dev_t dev;
+iskmemdev(dev_t dev)
{
-
return (major(dev) == mem_no && (minor(dev) < 2 || minor(dev) == 14));
}
@@ -348,15 +346,13 @@ iskmemdev(dev)
* Returns true if dev is /dev/zero.
*/
int
-iszerodev(dev)
- dev_t dev;
+iszerodev(dev_t dev)
{
-
return (major(dev) == mem_no && minor(dev) == 12);
}
dev_t
-getnulldev()
+getnulldev(void)
{
return makedev(mem_no, 2);
}
@@ -434,8 +430,7 @@ int findblkmajor(struct device *dv);
dev_t dev_rawpart(struct device *); /* XXX */
dev_t
-dev_rawpart(dv)
- struct device *dv;
+dev_rawpart(struct device *dv)
{
int majdev;
diff --git a/sys/arch/i386/i386/db_disasm.c b/sys/arch/i386/i386/db_disasm.c
index 2b59e7ff249..88a02e1db7d 100644
--- a/sys/arch/i386/i386/db_disasm.c
+++ b/sys/arch/i386/i386/db_disasm.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_disasm.c,v 1.13 2006/05/11 13:21:11 mickey Exp $ */
+/* $OpenBSD: db_disasm.c,v 1.14 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: db_disasm.c,v 1.11 1996/05/03 19:41:58 christos Exp $ */
/*
@@ -876,11 +876,8 @@ db_addr_t db_disasm_esc(db_addr_t, int, int, int, char *);
* Read address at location and return updated location.
*/
db_addr_t
-db_read_address(loc, short_addr, regmodrm, addrp)
- db_addr_t loc;
- int short_addr;
- int regmodrm;
- struct i_addr *addrp; /* out */
+db_read_address(db_addr_t loc, int short_addr, int regmodrm,
+ struct i_addr *addrp)
{
int mod, rm, sib, index, disp;
@@ -957,10 +954,7 @@ db_read_address(loc, short_addr, regmodrm, addrp)
}
void
-db_print_address(seg, size, addrp)
- char * seg;
- int size;
- struct i_addr *addrp;
+db_print_address(char *seg, int size, struct i_addr *addrp)
{
if (addrp->is_reg) {
db_printf("%s", db_reg[size][addrp->disp]);
@@ -986,12 +980,7 @@ db_print_address(seg, size, addrp)
* and return updated location.
*/
db_addr_t
-db_disasm_esc(loc, inst, short_addr, size, seg)
- db_addr_t loc;
- int inst;
- int short_addr;
- int size;
- char * seg;
+db_disasm_esc(db_addr_t loc, int inst, int short_addr, int size, char *seg)
{
int regmodrm;
struct finst *fp;
@@ -1082,9 +1071,7 @@ db_disasm_esc(loc, inst, short_addr, size, seg)
* next instruction.
*/
db_addr_t
-db_disasm(loc, altfmt)
- db_addr_t loc;
- boolean_t altfmt;
+db_disasm(db_addr_t loc, boolean_t altfmt)
{
int inst;
int size;
diff --git a/sys/arch/i386/i386/db_interface.c b/sys/arch/i386/i386/db_interface.c
index 3662dc593b5..765e44560cf 100644
--- a/sys/arch/i386/i386/db_interface.c
+++ b/sys/arch/i386/i386/db_interface.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_interface.c,v 1.20 2006/05/11 13:21:11 mickey Exp $ */
+/* $OpenBSD: db_interface.c,v 1.21 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: db_interface.c,v 1.22 1996/05/03 19:42:00 christos Exp $ */
/*
@@ -83,8 +83,7 @@ int db_cpuid2apic(int);
* Print trap reason.
*/
void
-kdbprinttrap(type, code)
- int type, code;
+kdbprinttrap(int type, int code)
{
db_printf("kernel: ");
if (type >= trap_types || type < 0)
@@ -98,9 +97,7 @@ kdbprinttrap(type, code)
* kdb_trap - field a TRACE or BPT trap
*/
int
-kdb_trap(type, code, regs)
- int type, code;
- db_regs_t *regs;
+kdb_trap(int type, int code, db_regs_t *regs)
{
int s;
@@ -178,11 +175,7 @@ kdb_trap(type, code, regs)
}
void
-db_sysregs_cmd(addr, have_addr, count, modif)
- db_expr_t addr;
- int have_addr;
- db_expr_t count;
- char *modif;
+db_sysregs_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
{
int64_t idtr, gdtr;
uint32_t cr;
@@ -351,7 +344,7 @@ struct db_command db_machine_command_table[] = {
};
void
-db_machine_init()
+db_machine_init(void)
{
#ifdef MULTIPROCESSOR
int i;
@@ -367,7 +360,7 @@ db_machine_init()
}
void
-Debugger()
+Debugger(void)
{
__asm__("int $3");
}
diff --git a/sys/arch/i386/i386/db_trace.c b/sys/arch/i386/i386/db_trace.c
index cadf68728f3..81ab9296920 100644
--- a/sys/arch/i386/i386/db_trace.c
+++ b/sys/arch/i386/i386/db_trace.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_trace.c,v 1.11 2006/05/11 13:21:11 mickey Exp $ */
+/* $OpenBSD: db_trace.c,v 1.12 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: db_trace.c,v 1.18 1996/05/03 19:42:01 christos Exp $ */
/*
@@ -89,7 +89,7 @@ void db_nextframe(struct i386_frame **, db_addr_t *, int *, int,
int (*pr)(const char *, ...));
void
-db_find_trace_symbols()
+db_find_trace_symbols(void)
{
db_expr_t value;
@@ -106,8 +106,7 @@ db_find_trace_symbols()
* Figure out how many arguments were passed into the frame at "fp".
*/
int
-db_numargs(fp)
- struct i386_frame *fp;
+db_numargs(struct i386_frame *fp)
{
int *argp;
int inst;
@@ -140,12 +139,8 @@ db_numargs(fp)
* of the function that faulted, but that could get hairy.
*/
void
-db_nextframe(fp, ip, argp, is_trap, pr)
- struct i386_frame **fp; /* in/out */
- db_addr_t *ip; /* out */
- int *argp; /* in */
- int is_trap; /* in */
- int (*pr)(const char *, ...);
+db_nextframe(struct i386_frame **fp, db_addr_t *ip, int *argp, int is_trap,
+ int (*pr)(const char *, ...))
{
switch (is_trap) {
@@ -180,12 +175,8 @@ db_nextframe(fp, ip, argp, is_trap, pr)
}
void
-db_stack_trace_print(addr, have_addr, count, modif, pr)
- db_expr_t addr;
- boolean_t have_addr;
- db_expr_t count;
- char *modif;
- int (*pr)(const char *, ...);
+db_stack_trace_print(db_expr_t addr, boolean_t have_addr, db_expr_t count,
+ char *modif, int (*pr)(const char *, ...))
{
struct i386_frame *frame, *lastframe;
int *argp;
@@ -200,8 +191,8 @@ db_stack_trace_print(addr, have_addr, count, modif, pr)
#endif
{
- register char *cp = modif;
- register char c;
+ char *cp = modif;
+ char c;
while ((c = *cp++) != 0) {
if (c == 't')
diff --git a/sys/arch/i386/i386/disksubr.c b/sys/arch/i386/i386/disksubr.c
index ed068a03da1..4808c305d72 100644
--- a/sys/arch/i386/i386/disksubr.c
+++ b/sys/arch/i386/i386/disksubr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: disksubr.c,v 1.55 2006/09/16 14:56:11 krw Exp $ */
+/* $OpenBSD: disksubr.c,v 1.56 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */
/*
@@ -61,12 +61,8 @@
* Returns null on success and an error string on failure.
*/
char *
-readdisklabel(dev, strat, lp, osdep, spoofonly)
- dev_t dev;
- void (*strat)(struct buf *);
- register struct disklabel *lp;
- struct cpu_disklabel *osdep;
- int spoofonly;
+readdisklabel(dev_t dev, void (*strat)(struct buf *), struct disklabel *lp,
+ struct cpu_disklabel *osdep, int spoofonly)
{
struct dos_partition *dp = osdep->dosparts, *dp2;
struct dkbad *bdp = &DKBAD(osdep);
@@ -329,13 +325,11 @@ done:
* before setting it.
*/
int
-setdisklabel(olp, nlp, openmask, osdep)
- register struct disklabel *olp, *nlp;
- u_long openmask;
- struct cpu_disklabel *osdep;
+setdisklabel(struct disklabel *olp, struct disklabel *nlp, u_long openmask,
+ struct cpu_disklabel *osdep)
{
- register int i;
- register struct partition *opp, *npp;
+ int i;
+ struct partition *opp, *npp;
/* sanity clause */
if (nlp->d_secpercyl == 0 || nlp->d_secsize == 0 ||
@@ -386,11 +380,8 @@ setdisklabel(olp, nlp, openmask, osdep)
* XXX cannot handle OpenBSD partitions in extended partitions!
*/
int
-writedisklabel(dev, strat, lp, osdep)
- dev_t dev;
- void (*strat)(struct buf *);
- register struct disklabel *lp;
- struct cpu_disklabel *osdep;
+writedisklabel(dev_t dev, void (*strat)(struct buf *), struct disklabel *lp,
+ struct cpu_disklabel *osdep)
{
struct dos_partition *dp = osdep->dosparts, *dp2;
struct buf *bp;
@@ -484,11 +475,8 @@ done:
* if needed, and signal errors or early completion.
*/
int
-bounds_check_with_label(bp, lp, osdep, wlabel)
- struct buf *bp;
- struct disklabel *lp;
- struct cpu_disklabel *osdep;
- int wlabel;
+bounds_check_with_label(struct buf *bp, struct disklabel *lp,
+ struct cpu_disklabel *osdep, int wlabel)
{
#define blockpersec(count, lp) ((count) * (((lp)->d_secsize) / DEV_BSIZE))
struct partition *p = lp->d_partitions + DISKPART(bp->b_dev);
diff --git a/sys/arch/i386/i386/freebsd_machdep.c b/sys/arch/i386/i386/freebsd_machdep.c
index 21d561fc8e9..c1e2a7261c5 100644
--- a/sys/arch/i386/i386/freebsd_machdep.c
+++ b/sys/arch/i386/i386/freebsd_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: freebsd_machdep.c,v 1.19 2006/05/11 13:21:11 mickey Exp $ */
+/* $OpenBSD: freebsd_machdep.c,v 1.20 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: freebsd_machdep.c,v 1.10 1996/05/03 19:42:05 christos Exp $ */
/*-
@@ -73,15 +73,11 @@
* specified pc, psl.
*/
void
-freebsd_sendsig(catcher, sig, mask, code, type, val)
- sig_t catcher;
- int sig, mask;
- u_long code;
- int type;
- union sigval val;
+freebsd_sendsig(sig_t catcher, int sig, int mask, u_long code, int type,
+ union sigval val)
{
- register struct proc *p = curproc;
- register struct trapframe *tf;
+ struct proc *p = curproc;
+ struct trapframe *tf;
struct freebsd_sigframe *fp, frame;
struct sigacts *psp = p->p_sigacts;
int oonstack;
@@ -173,16 +169,13 @@ freebsd_sendsig(catcher, sig, mask, code, type, val)
* a machine fault.
*/
int
-freebsd_sys_sigreturn(p, v, retval)
- struct proc *p;
- void *v;
- register_t *retval;
+freebsd_sys_sigreturn(struct proc *p, void *v, register_t *retval)
{
struct freebsd_sys_sigreturn_args /* {
syscallarg(struct freebsd_sigcontext *) scp;
} */ *uap = v;
struct freebsd_sigcontext *scp, context;
- register struct trapframe *tf;
+ struct trapframe *tf;
tf = p->p_md.md_regs;
@@ -248,10 +241,8 @@ freebsd_sys_sigreturn(p, v, retval)
*/
void
-netbsd_to_freebsd_ptrace_regs(nregs, nfpregs, fregs)
- struct reg *nregs;
- struct fpreg *nfpregs;
- struct freebsd_ptrace_reg *fregs;
+netbsd_to_freebsd_ptrace_regs(struct reg *nregs, struct fpreg *nfpregs,
+ struct freebsd_ptrace_reg *fregs)
{
struct save87 *nframe = (struct save87 *)nfpregs;
@@ -308,10 +299,8 @@ netbsd_to_freebsd_ptrace_regs(nregs, nfpregs, fregs)
}
void
-freebsd_to_netbsd_ptrace_regs(fregs, nregs, nfpregs)
- struct freebsd_ptrace_reg *fregs;
- struct reg *nregs;
- struct fpreg *nfpregs;
+freebsd_to_netbsd_ptrace_regs(struct freebsd_ptrace_reg *fregs,
+ struct reg *nregs, struct fpreg *nfpregs)
{
struct save87 *nframe = (struct save87 *)nfpregs;
@@ -382,10 +371,7 @@ freebsd_ptrace_getregs(struct freebsd_ptrace_reg *fregs, caddr_t addr,
}
int
-freebsd_ptrace_setregs(fregs, addr, data)
- struct freebsd_ptrace_reg *fregs;
- caddr_t addr;
- int data;
+freebsd_ptrace_setregs(struct freebsd_ptrace_reg *fregs, caddr_t addr, int data)
{
vaddr_t offset = (vaddr_t)addr;
diff --git a/sys/arch/i386/i386/i686_mem.c b/sys/arch/i386/i386/i686_mem.c
index 2effc56a0b7..eae289331ad 100644
--- a/sys/arch/i386/i386/i686_mem.c
+++ b/sys/arch/i386/i386/i686_mem.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: i686_mem.c,v 1.8 2006/05/27 04:08:57 gwk Exp $ */
+/* $OpenBSD: i686_mem.c,v 1.9 2006/09/19 11:06:33 jsg Exp $ */
/*-
* Copyright (c) 1999 Michael Smith <msmith@freebsd.org>
* All rights reserved.
@@ -134,9 +134,7 @@ i686_mtrrconflict(int flag1, int flag2)
* Look for an exactly-matching range.
*/
struct mem_range_desc *
-mem_range_match(sc, mrd)
- struct mem_range_softc *sc;
- struct mem_range_desc *mrd;
+mem_range_match(struct mem_range_softc *sc, struct mem_range_desc *mrd)
{
struct mem_range_desc *cand;
int i;
@@ -154,8 +152,7 @@ mem_range_match(sc, mrd)
* that MTRRs are enabled, and we may or may not have fixed MTRRs.
*/
void
-i686_mrfetch(sc)
- struct mem_range_softc *sc;
+i686_mrfetch(struct mem_range_softc *sc)
{
struct mem_range_desc *mrd;
u_int64_t msrv;
@@ -232,8 +229,7 @@ i686_mrfetch(sc)
* Return the MTRR memory type matching a region's flags
*/
int
-i686_mtrrtype(flags)
- int flags;
+i686_mtrrtype(int flags)
{
int i;
@@ -265,8 +261,7 @@ i686_mrt2mtrr(int flags, int oldval)
* XXX Must be called with interrupts enabled.
*/
void
-i686_mrstore(sc)
- struct mem_range_softc *sc;
+i686_mrstore(struct mem_range_softc *sc)
{
disable_intr(); /* disable interrupts */
i686_mrstoreone((void *)sc);
@@ -279,8 +274,7 @@ i686_mrstore(sc)
* just stuffing one entry; this is simpler (but slower, of course).
*/
void
-i686_mrstoreone(arg)
- void *arg;
+i686_mrstoreone(void *arg)
{
struct mem_range_softc *sc = (struct mem_range_softc *)arg;
struct mem_range_desc *mrd;
@@ -368,9 +362,7 @@ i686_mrstoreone(arg)
* Hunt for the fixed MTRR referencing (addr)
*/
struct mem_range_desc *
-i686_mtrrfixsearch(sc, addr)
- struct mem_range_softc *sc;
- u_int64_t addr;
+i686_mtrrfixsearch(struct mem_range_softc *sc, u_int64_t addr)
{
struct mem_range_desc *mrd;
int i;
@@ -392,10 +384,7 @@ i686_mtrrfixsearch(sc, addr)
* XXX note that this will have to be updated when we start supporting "busy" ranges.
*/
int
-i686_mrsetlow(sc, mrd, arg)
- struct mem_range_softc *sc;
- struct mem_range_desc *mrd;
- int *arg;
+i686_mrsetlow(struct mem_range_softc *sc, struct mem_range_desc *mrd, int *arg)
{
struct mem_range_desc *first_md, *last_md, *curr_md;
@@ -427,10 +416,8 @@ i686_mrsetlow(sc, mrd, arg)
* XXX needs to be updated to properly support "busy" ranges.
*/
int
-i686_mrsetvariable(sc, mrd, arg)
- struct mem_range_softc *sc;
- struct mem_range_desc *mrd;
- int *arg;
+i686_mrsetvariable(struct mem_range_softc *sc, struct mem_range_desc *mrd,
+ int *arg)
{
struct mem_range_desc *curr_md, *free_md;
int i;
@@ -490,10 +477,7 @@ i686_mrsetvariable(sc, mrd, arg)
*
*/
int
-i686_mrset(sc, mrd, arg)
- struct mem_range_softc *sc;
- struct mem_range_desc *mrd;
- int *arg;
+i686_mrset(struct mem_range_softc *sc, struct mem_range_desc *mrd, int *arg)
{
struct mem_range_desc *targ;
int error = 0;
@@ -545,8 +529,7 @@ i686_mrset(sc, mrd, arg)
* fetch the initial settings.
*/
void
-i686_mrinit(sc)
- struct mem_range_softc *sc;
+i686_mrinit(struct mem_range_softc *sc)
{
struct mem_range_desc *mrd;
int nmdesc = 0;
@@ -611,8 +594,7 @@ i686_mrinit(sc)
* Initialise MTRRs on an AP after the BSP has run the init code.
*/
void
-i686_mrAPinit(sc)
- struct mem_range_softc *sc;
+i686_mrAPinit(struct mem_range_softc *sc)
{
i686_mrstoreone((void *)sc); /* set MTRRs to match BSP */
wrmsr(MSR_MTRRdefType, mtrrdef); /* set MTRR behaviour to match BSP */
diff --git a/sys/arch/i386/i386/ipx_cksum.c b/sys/arch/i386/i386/ipx_cksum.c
index 26bd1993705..d68aa1b1c6a 100644
--- a/sys/arch/i386/i386/ipx_cksum.c
+++ b/sys/arch/i386/i386/ipx_cksum.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ipx_cksum.c,v 1.4 2006/05/11 13:21:11 mickey Exp $ */
+/* $OpenBSD: ipx_cksum.c,v 1.5 2006/09/19 11:06:33 jsg Exp $ */
/*-
* Copyright (c) 1994, 1995 Charles M. Hannum. All rights reserved.
@@ -66,13 +66,11 @@
#define ADDWORD {sum += *(u_short *)w;}
u_short
-ipx_cksum(m, len)
- register struct mbuf *m;
- register int len;
+ipx_cksum(struct mbuf *m, int len)
{
- register u_char *w;
- register unsigned sum = 0;
- register int mlen = 0;
+ u_char *w;
+ unsigned sum = 0;
+ int mlen = 0;
int byte_swapped = 0;
for (; m && len; m = m->m_next) {
diff --git a/sys/arch/i386/i386/kgdb_machdep.c b/sys/arch/i386/i386/kgdb_machdep.c
index 95623ff532a..85706ba7866 100644
--- a/sys/arch/i386/i386/kgdb_machdep.c
+++ b/sys/arch/i386/i386/kgdb_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: kgdb_machdep.c,v 1.6 2006/05/11 13:21:11 mickey Exp $ */
+/* $OpenBSD: kgdb_machdep.c,v 1.7 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: kgdb_machdep.c,v 1.6 1998/08/13 21:36:03 thorpej Exp $ */
/*-
@@ -92,9 +92,7 @@
* Determine if the memory at va..(va+len) is valid.
*/
int
-kgdb_acc(va, len)
- vaddr_t va;
- size_t len;
+kgdb_acc(vaddr_t va, size_t len)
{
vaddr_t last_va;
@@ -116,8 +114,7 @@ kgdb_acc(va, len)
* (gdb only understands unix signal numbers).
*/
int
-kgdb_signal(type)
- int type;
+kgdb_signal(int type)
{
switch (type) {
case T_NMI:
@@ -162,9 +159,7 @@ kgdb_signal(type)
* understood by gdb.
*/
void
-kgdb_getregs(regs, gdb_regs)
- db_regs_t *regs;
- kgdb_reg_t *gdb_regs;
+kgdb_getregs(db_regs_t *regs, kgdb_reg_t *gdb_regs)
{
gdb_regs[ 0] = regs->tf_eax;
@@ -196,9 +191,7 @@ kgdb_getregs(regs, gdb_regs)
* Reverse the above.
*/
void
-kgdb_setregs(regs, gdb_regs)
- db_regs_t *regs;
- kgdb_reg_t *gdb_regs;
+kgdb_setregs(db_regs_t *regs, kgdb_reg_t *gdb_regs)
{
regs->tf_eax = gdb_regs[ 0];
diff --git a/sys/arch/i386/i386/linux_machdep.c b/sys/arch/i386/i386/linux_machdep.c
index c994c11455a..5177e6718eb 100644
--- a/sys/arch/i386/i386/linux_machdep.c
+++ b/sys/arch/i386/i386/linux_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: linux_machdep.c,v 1.31 2006/01/12 22:39:20 weingart Exp $ */
+/* $OpenBSD: linux_machdep.c,v 1.32 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: linux_machdep.c,v 1.29 1996/05/03 19:42:11 christos Exp $ */
/*
@@ -104,12 +104,8 @@ int linux_write_ldt(struct proc *, struct linux_sys_modify_ldt_args *,
*/
void
-linux_sendsig(catcher, sig, mask, code, type, val)
- sig_t catcher;
- int sig, mask;
- u_long code;
- int type;
- union sigval val;
+linux_sendsig(sig_t catcher, int sig, int mask, u_long code, int type,
+ union sigval val)
{
struct proc *p = curproc;
struct trapframe *tf;
@@ -201,10 +197,7 @@ linux_sendsig(catcher, sig, mask, code, type, val)
* a machine fault.
*/
int
-linux_sys_sigreturn(p, v, retval)
- struct proc *p;
- void *v;
- register_t *retval;
+linux_sys_sigreturn(struct proc *p, void *v, register_t *retval)
{
struct linux_sys_sigreturn_args /* {
syscallarg(struct linux_sigcontext *) scp;
@@ -271,10 +264,7 @@ linux_sys_sigreturn(p, v, retval)
}
int
-linux_sys_rt_sigreturn(p, v, retval)
- struct proc *p;
- void *v;
- register_t *retval;
+linux_sys_rt_sigreturn(struct proc *p, void *v, register_t *retval)
{
return(ENOSYS);
}
@@ -282,14 +272,8 @@ linux_sys_rt_sigreturn(p, v, retval)
#ifdef USER_LDT
int
-linux_read_ldt(p, uap, retval)
- struct proc *p;
- struct linux_sys_modify_ldt_args /* {
- syscallarg(int) func;
- syscallarg(void *) ptr;
- syscallarg(size_t) bytecount;
- } */ *uap;
- register_t *retval;
+linux_read_ldt(struct proc *p, struct linux_sys_modify_ldt_args *uap,
+ register_t *retval)
{
struct i386_get_ldt_args gl;
int error;
@@ -329,14 +313,8 @@ struct linux_ldt_info {
};
int
-linux_write_ldt(p, uap, retval)
- struct proc *p;
- struct linux_sys_modify_ldt_args /* {
- syscallarg(int) func;
- syscallarg(void *) ptr;
- syscallarg(size_t) bytecount;
- } */ *uap;
- register_t *retval;
+linux_write_ldt(struct proc *p, struct linux_sys_modify_ldt_args *uap,
+ register_t *retval)
{
struct linux_ldt_info ldt_info;
struct segment_descriptor sd;
@@ -394,10 +372,7 @@ linux_write_ldt(p, uap, retval)
#endif /* USER_LDT */
int
-linux_sys_modify_ldt(p, v, retval)
- struct proc *p;
- void *v;
- register_t *retval;
+linux_sys_modify_ldt(struct proc *p, void *v, register_t *retval)
{
struct linux_sys_modify_ldt_args /* {
syscallarg(int) func;
@@ -426,8 +401,7 @@ linux_sys_modify_ldt(p, v, retval)
* array for all major device numbers, and map linux_mknod too.
*/
dev_t
-linux_fakedev(dev)
- dev_t dev;
+linux_fakedev(dev_t dev)
{
if (major(dev) == NATIVE_CONS_MAJOR)
@@ -439,10 +413,7 @@ linux_fakedev(dev)
* We come here in a last attempt to satisfy a Linux ioctl() call
*/
int
-linux_machdepioctl(p, v, retval)
- struct proc *p;
- void *v;
- register_t *retval;
+linux_machdepioctl(struct proc *p, void *v, register_t *retval)
{
struct linux_sys_ioctl_args /* {
syscallarg(int) fd;
@@ -622,10 +593,7 @@ linux_machdepioctl(p, v, retval)
* to rely on I/O permission maps, which are not implemented.
*/
int
-linux_sys_iopl(p, v, retval)
- struct proc *p;
- void *v;
- register_t *retval;
+linux_sys_iopl(struct proc *p, void *v, register_t *retval)
{
#if 0
struct linux_sys_iopl_args /* {
@@ -648,10 +616,7 @@ linux_sys_iopl(p, v, retval)
* just let it have the whole range.
*/
int
-linux_sys_ioperm(p, v, retval)
- struct proc *p;
- void *v;
- register_t *retval;
+linux_sys_ioperm(struct proc *p, void *v, register_t *retval)
{
struct linux_sys_ioperm_args /* {
syscallarg(unsigned int) lo;
diff --git a/sys/arch/i386/i386/lock_machdep.c b/sys/arch/i386/i386/lock_machdep.c
index 0672d9eced4..99e0bded4ac 100644
--- a/sys/arch/i386/i386/lock_machdep.c
+++ b/sys/arch/i386/i386/lock_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: lock_machdep.c,v 1.2 2004/06/13 21:49:15 niklas Exp $ */
+/* $OpenBSD: lock_machdep.c,v 1.3 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: lock_machdep.c,v 1.1.2.3 2000/05/03 14:40:30 sommerfeld Exp $ */
/*-
@@ -56,8 +56,7 @@
#ifdef LOCKDEBUG
void
-__cpu_simple_lock_init(lockp)
- __cpu_simple_lock_t *lockp;
+__cpu_simple_lock_init(__cpu_simple_lock_t *lockp)
{
*lockp = __SIMPLELOCK_UNLOCKED;
}
@@ -67,8 +66,7 @@ int spin_limit = 10000000;
#endif
void
-__cpu_simple_lock(lockp)
- __cpu_simple_lock_t *lockp;
+__cpu_simple_lock(__cpu_simple_lock_t *lockp)
{
#if defined (DEBUG) && defined(DDB)
int spincount = 0;
@@ -92,8 +90,7 @@ __cpu_simple_lock(lockp)
}
int
-__cpu_simple_lock_try(lockp)
- __cpu_simple_lock_t *lockp;
+__cpu_simple_lock_try(__cpu_simple_lock_t *lockp)
{
if (i386_atomic_testset_i(lockp, __SIMPLELOCK_LOCKED)
@@ -103,8 +100,7 @@ __cpu_simple_lock_try(lockp)
}
void
-__cpu_simple_unlock(lockp)
- __cpu_simple_lock_t *lockp;
+__cpu_simple_unlock(__cpu_simple_lock_t *lockp)
{
*lockp = __SIMPLELOCK_UNLOCKED;
}
diff --git a/sys/arch/i386/i386/machdep.c b/sys/arch/i386/i386/machdep.c
index 220cca8ea48..703ab4069bc 100644
--- a/sys/arch/i386/i386/machdep.c
+++ b/sys/arch/i386/i386/machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: machdep.c,v 1.364 2006/08/20 01:42:51 gwk Exp $ */
+/* $OpenBSD: machdep.c,v 1.365 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: machdep.c,v 1.214 1996/11/10 03:16:17 thorpej Exp $ */
/*-
@@ -544,8 +544,7 @@ i386_init_pcb_tss_ldt(struct cpu_info *ci)
* allocsys() again with the correct base virtual address.
*/
caddr_t
-allocsys(v)
- register caddr_t v;
+allocsys(caddr_t v)
{
#define valloc(name, type, num) \
@@ -2368,7 +2367,7 @@ sys_sigreturn(struct proc *p, void *v, register_t *retval)
syscallarg(struct sigcontext *) sigcntxp;
} */ *uap = v;
struct sigcontext *scp, context;
- register struct trapframe *tf;
+ struct trapframe *tf;
tf = p->p_md.md_regs;
@@ -2547,7 +2546,7 @@ void
dumpconf()
{
int nblks; /* size of dump area */
- register int maj, i;
+ int maj, i;
if (dumpdev == NODEV)
return;
@@ -2615,12 +2614,12 @@ reserve_dumppages(vaddr_t p)
void
dumpsys()
{
- register u_int i, j, npg;
- register int maddr;
+ u_int i, j, npg;
+ int maddr;
daddr_t blkno;
int (*dump)(dev_t, daddr_t, caddr_t, size_t);
int error;
- register char *str;
+ char *str;
extern int msgbufmapped;
/* Save registers. */
@@ -3070,7 +3069,7 @@ init386(paddr_t first_avail)
#endif
for(i = 0, im = bios_memmap; im->type != BIOS_MAP_END; im++)
if (im->type == BIOS_MAP_FREE) {
- register paddr_t a, e;
+ paddr_t a, e;
a = round_page(im->addr);
e = trunc_page(im->addr + im->size);
diff --git a/sys/arch/i386/i386/mem.c b/sys/arch/i386/i386/mem.c
index 44f7a4e784a..1643f68a649 100644
--- a/sys/arch/i386/i386/mem.c
+++ b/sys/arch/i386/i386/mem.c
@@ -1,5 +1,5 @@
/* $NetBSD: mem.c,v 1.31 1996/05/03 19:42:19 christos Exp $ */
-/* $OpenBSD: mem.c,v 1.30 2006/05/27 04:08:57 gwk Exp $ */
+/* $OpenBSD: mem.c,v 1.31 2006/09/19 11:06:33 jsg Exp $ */
/*
* Copyright (c) 1988 University of Utah.
* Copyright (c) 1982, 1986, 1990, 1993
@@ -76,10 +76,7 @@ static int mem_ioctl(dev_t, u_long, caddr_t, int, struct proc *);
/*ARGSUSED*/
int
-mmopen(dev, flag, mode, p)
- dev_t dev;
- int flag, mode;
- struct proc *p;
+mmopen(dev_t dev, int flag, int mode, struct proc *p)
{
switch (minor(dev)) {
@@ -107,10 +104,7 @@ mmopen(dev, flag, mode, p)
/*ARGSUSED*/
int
-mmclose(dev, flag, mode, p)
- dev_t dev;
- int flag, mode;
- struct proc *p;
+mmclose(dev_t dev, int flag, int mode, struct proc *p)
{
#ifdef APERTURE
if (minor(dev) == 4)
@@ -214,10 +208,7 @@ mmrw(dev_t dev, struct uio *uio, int flags)
}
paddr_t
-mmmmap(dev, off, prot)
- dev_t dev;
- off_t off;
- int prot;
+mmmmap(dev_t dev, off_t off, int prot)
{
struct proc *p = curproc; /* XXX */
@@ -259,12 +250,7 @@ mmmmap(dev, off, prot)
}
int
-mmioctl(dev, cmd, data, flags, p)
- dev_t dev;
- u_long cmd;
- caddr_t data;
- int flags;
- struct proc *p;
+mmioctl(dev_t dev, u_long cmd, caddr_t data, int flags, struct proc *p)
{
#if NMTRR > 0
switch (minor(dev)) {
@@ -284,12 +270,7 @@ mmioctl(dev, cmd, data, flags, p)
* and mem_range_attr_set.
*/
static int
-mem_ioctl(dev, cmd, data, flags, p)
- dev_t dev;
- u_long cmd;
- caddr_t data;
- int flags;
- struct proc *p;
+mem_ioctl(dev_t dev, u_long cmd, caddr_t data, int flags, struct proc *p)
{
int nd, error = 0;
struct mem_range_op *mo = (struct mem_range_op *)data;
@@ -344,9 +325,7 @@ mem_ioctl(dev, cmd, data, flags, p)
* memory range attributes.
*/
int
-mem_range_attr_get(mrd, arg)
- struct mem_range_desc *mrd;
- int *arg;
+mem_range_attr_get(struct mem_range_desc *mrd, int *arg)
{
/* can we handle this? */
if (mem_range_softc.mr_op == NULL)
@@ -361,9 +340,7 @@ mem_range_attr_get(mrd, arg)
}
int
-mem_range_attr_set(mrd, arg)
- struct mem_range_desc *mrd;
- int *arg;
+mem_range_attr_set(struct mem_range_desc *mrd, int *arg)
{
/* can we handle this? */
if (mem_range_softc.mr_op == NULL)
diff --git a/sys/arch/i386/i386/mpbios.c b/sys/arch/i386/i386/mpbios.c
index 0f728918118..ffabc9d1c3f 100644
--- a/sys/arch/i386/i386/mpbios.c
+++ b/sys/arch/i386/i386/mpbios.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mpbios.c,v 1.15 2006/08/18 08:30:35 kettenis Exp $ */
+/* $OpenBSD: mpbios.c,v 1.16 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: mpbios.c,v 1.2 2002/10/01 12:56:57 fvdl Exp $ */
/*-
@@ -200,9 +200,7 @@ int mp_verbose = 0;
#endif
int
-mp_print(aux, pnp)
- void *aux;
- const char *pnp;
+mp_print(void *aux, const char *pnp)
{
struct cpu_attach_args * caa = (struct cpu_attach_args *) aux;
if (pnp)
@@ -211,10 +209,7 @@ mp_print(aux, pnp)
}
int
-mp_match(parent, cfv, aux)
- struct device *parent;
- void *cfv;
- void *aux;
+mp_match(struct device *parent, void *cfv, void *aux)
{
struct cfdata *cf = (struct cfdata *)cfv;
struct cpu_attach_args * caa = (struct cpu_attach_args *) aux;
@@ -229,10 +224,7 @@ mp_match(parent, cfv, aux)
* const'ed pointer.
*/
const void *
-mpbios_map(pa, len, handle)
- paddr_t pa;
- int len;
- struct mp_map *handle;
+mpbios_map(paddr_t pa, int len, struct mp_map *handle)
{
paddr_t pgpa = trunc_page(pa);
paddr_t endpa = round_page(pa + len);
@@ -260,8 +252,7 @@ mpbios_map(pa, len, handle)
}
static __inline void
-mpbios_unmap(handle)
- struct mp_map *handle;
+mpbios_unmap(struct mp_map *handle)
{
#if 1
pmap_kremove(handle->baseva, handle->vsize);
@@ -275,8 +266,7 @@ mpbios_unmap(handle)
* Look for an Intel MP spec table, indicating SMP capable hardware.
*/
int
-mpbios_probe(self)
- struct device *self;
+mpbios_probe(struct device *self)
{
paddr_t ebda, memtop;
@@ -388,9 +378,7 @@ mpbios_probe(self)
*/
static __inline int
-mpbios_cksum (start, len)
- const void *start;
- int len;
+mpbios_cksum(const void *start, int len)
{
unsigned char res=0;
const char *p = start;
@@ -412,11 +400,7 @@ mpbios_cksum (start, len)
*/
const void *
-mpbios_search (self, start, count, map)
- struct device *self;
- paddr_t start;
- int count;
- struct mp_map *map;
+mpbios_search(struct device *self, paddr_t start, int count, struct mp_map *map)
{
struct mp_map t;
@@ -505,8 +489,7 @@ static struct mp_bus nmi_bus = {
* nintrs
*/
void
-mpbios_scan(self)
- struct device *self;
+mpbios_scan(struct device *self)
{
const u_int8_t *position, *end;
int count;
@@ -725,9 +708,7 @@ mpbios_invent(int irq, int type, int bus)
}
void
-mpbios_cpu(ent, self)
- const u_int8_t *ent;
- struct device *self;
+mpbios_cpu(const u_int8_t *ent, struct device *self)
{
const struct mpbios_proc *entry = (const struct mpbios_proc *)ent;
struct cpu_attach_args caa;
@@ -777,9 +758,7 @@ mpbios_cpu(ent, self)
* Fill in: trigger mode, polarity, and possibly delivery mode.
*/
void
-mp_cfg_special_intr(entry, redir)
- const struct mpbios_int *entry;
- u_int32_t *redir;
+mp_cfg_special_intr(const struct mpbios_int *entry, u_int32_t *redir)
{
/*
@@ -816,9 +795,7 @@ mp_cfg_special_intr(entry, redir)
/* XXX too much duplicated code here. */
void
-mp_cfg_pci_intr(entry, redir)
- const struct mpbios_int *entry;
- u_int32_t *redir;
+mp_cfg_pci_intr(const struct mpbios_int *entry, u_int32_t *redir)
{
int mpspo = entry->int_flags & 0x03; /* XXX magic */
int mpstrig = (entry->int_flags >> 2) & 0x03; /* XXX magic */
@@ -856,9 +833,7 @@ mp_cfg_pci_intr(entry, redir)
}
void
-mp_cfg_eisa_intr (entry, redir)
- const struct mpbios_int *entry;
- u_int32_t *redir;
+mp_cfg_eisa_intr (const struct mpbios_int *entry, u_int32_t *redir)
{
int mpspo = entry->int_flags & 0x03; /* XXX magic */
int mpstrig = (entry->int_flags >> 2) & 0x03; /* XXX magic */
@@ -908,9 +883,7 @@ mp_cfg_eisa_intr (entry, redir)
void
-mp_cfg_isa_intr(entry, redir)
- const struct mpbios_int *entry;
- u_int32_t *redir;
+mp_cfg_isa_intr(const struct mpbios_int *entry, u_int32_t *redir)
{
int mpspo = entry->int_flags & 0x03; /* XXX magic */
int mpstrig = (entry->int_flags >> 2) & 0x03; /* XXX magic */
@@ -949,28 +922,24 @@ mp_cfg_isa_intr(entry, redir)
void
-mp_print_special_intr(intr)
- int intr;
+mp_print_special_intr(int intr)
{
}
void
-mp_print_pci_intr(intr)
- int intr;
+mp_print_pci_intr(int intr)
{
printf(" device %d INT_%c", (intr >> 2) & 0x1f, 'A' + (intr & 0x3));
}
void
-mp_print_isa_intr(intr)
- int intr;
+mp_print_isa_intr(int intr)
{
printf(" irq %d", intr);
}
void
-mp_print_eisa_intr(intr)
- int intr;
+mp_print_eisa_intr(int intr)
{
printf(" EISA irq %d", intr);
}
@@ -984,9 +953,7 @@ mp_print_eisa_intr(intr)
#define EXTEND_TAB(a,u) (!(_TAB_ROUND(a, u) == _TAB_ROUND((a + 1), u)))
void
-mpbios_bus(ent, self)
- const u_int8_t *ent;
- struct device *self;
+mpbios_bus(const u_int8_t *ent, struct device *self)
{
const struct mpbios_bus *entry = (const struct mpbios_bus *)ent;
int bus_id = entry->bus_id;
@@ -1043,9 +1010,7 @@ mpbios_bus(ent, self)
void
-mpbios_ioapic(ent, self)
- const u_int8_t *ent;
- struct device *self;
+mpbios_ioapic(const u_int8_t *ent, struct device *self)
{
const struct mpbios_ioapic *entry = (const struct mpbios_ioapic *)ent;
struct apic_attach_args aaa;
@@ -1065,9 +1030,7 @@ mpbios_ioapic(ent, self)
}
int
-mpbios_int(ent, mpi)
- const u_int8_t *ent;
- struct mp_intr_map *mpi;
+mpbios_int(const u_int8_t *ent, struct mp_intr_map *mpi)
{
const struct mpbios_int *entry = (const struct mpbios_int *)ent;
struct mpbios_int rw_entry = *entry;
diff --git a/sys/arch/i386/i386/mtrr.c b/sys/arch/i386/i386/mtrr.c
index 90e753e30c4..029fcabd04a 100644
--- a/sys/arch/i386/i386/mtrr.c
+++ b/sys/arch/i386/i386/mtrr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mtrr.c,v 1.7 2006/05/11 13:21:11 mickey Exp $ */
+/* $OpenBSD: mtrr.c,v 1.8 2006/09/19 11:06:33 jsg Exp $ */
/*-
* Copyright (c) 1999 Michael Smith <msmith@freebsd.org>
* Copyright (c) 1999 Brian Fundakowski Feldman
@@ -44,8 +44,7 @@ extern struct mem_range_ops k6_mrops;
void mtrrattach(int);
void
-mtrrattach (num)
- int num;
+mtrrattach(int num)
{
if (num > 1)
return;
@@ -70,4 +69,3 @@ mtrrattach (num)
mem_range_softc.mr_op->init(&mem_range_softc);
}
-
diff --git a/sys/arch/i386/i386/pctr.c b/sys/arch/i386/i386/pctr.c
index 634ccdf1cce..2913a91a142 100644
--- a/sys/arch/i386/i386/pctr.c
+++ b/sys/arch/i386/i386/pctr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pctr.c,v 1.20 2005/04/29 01:12:15 deraadt Exp $ */
+/* $OpenBSD: pctr.c,v 1.21 2006/09/19 11:06:33 jsg Exp $ */
/*
* Pentium performance counter driver for OpenBSD.
@@ -46,8 +46,7 @@ int p6ctrsel(int fflag, u_int cmd, u_int fn);
static __inline void p6ctrrd(struct pctrst *st);
void
-pctrattach(num)
- int num;
+pctrattach(int num)
{
if (num > 1)
return;
@@ -79,11 +78,7 @@ pctrattach(num)
}
int
-pctropen(dev, oflags, devtype, p)
- dev_t dev;
- int oflags;
- int devtype;
- struct proc *p;
+pctropen(dev_t dev, int oflags, int devtype, struct proc *p)
{
if (minor(dev))
return ENXIO;
@@ -91,20 +86,13 @@ pctropen(dev, oflags, devtype, p)
}
int
-pctrclose(dev, oflags, devtype, p)
- dev_t dev;
- int oflags;
- int devtype;
- struct proc *p;
+pctrclose(dev_t dev, int oflags, int devtype, struct proc *p)
{
return 0;
}
int
-p5ctrsel(fflag, cmd, fn)
- int fflag;
- u_int cmd;
- u_int fn;
+p5ctrsel(int fflag, u_int cmd, u_int fn)
{
pctrval msr11;
int msr;
@@ -131,8 +119,7 @@ p5ctrsel(fflag, cmd, fn)
}
static __inline void
-p5ctrrd(st)
- struct pctrst *st;
+p5ctrrd(struct pctrst *st)
{
u_int msr11;
@@ -147,10 +134,7 @@ p5ctrrd(st)
}
int
-p6ctrsel(fflag, cmd, fn)
- int fflag;
- u_int cmd;
- u_int fn;
+p6ctrsel(int fflag, u_int cmd, u_int fn)
{
int msrsel, msrval;
@@ -173,8 +157,7 @@ p6ctrsel(fflag, cmd, fn)
}
static __inline void
-p6ctrrd(st)
- struct pctrst *st;
+p6ctrrd(struct pctrst *st)
{
st->pctr_fn[0] = rdmsr(P6MSR_CTRSEL0);
st->pctr_fn[1] = rdmsr(P6MSR_CTRSEL1);
@@ -187,12 +170,7 @@ p6ctrrd(st)
int
-pctrioctl(dev, cmd, data, fflag, p)
- dev_t dev;
- u_long cmd;
- caddr_t data;
- int fflag;
- struct proc *p;
+pctrioctl(dev_t dev, u_long cmd, caddr_t data, int fflag, struct proc *p)
{
switch (cmd) {
case PCIOCRD:
diff --git a/sys/arch/i386/i386/pmap.c b/sys/arch/i386/i386/pmap.c
index 56f4eced303..dda070dbfe0 100644
--- a/sys/arch/i386/i386/pmap.c
+++ b/sys/arch/i386/i386/pmap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pmap.c,v 1.94 2006/08/28 12:18:10 mickey Exp $ */
+/* $OpenBSD: pmap.c,v 1.95 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: pmap.c,v 1.91 2000/06/02 17:46:37 thorpej Exp $ */
/*
@@ -1052,10 +1052,7 @@ setcslimit(struct pmap *pm, struct trapframe *tf, struct pcb *pcb,
*/
void
-pmap_kenter_pa(va, pa, prot)
- vaddr_t va;
- paddr_t pa;
- vm_prot_t prot;
+pmap_kenter_pa(vaddr_t va, paddr_t pa, vm_prot_t prot)
{
u_int32_t bits;
@@ -1084,9 +1081,7 @@ pmap_kenter_pa(va, pa, prot)
*/
void
-pmap_kremove(va, len)
- vaddr_t va;
- vsize_t len;
+pmap_kremove(vaddr_t va, vsize_t len)
{
u_int32_t bits;
#ifdef MULTIPROCESSOR
@@ -1131,8 +1126,7 @@ pmap_kremove(va, len)
*/
void
-pmap_bootstrap(kva_start)
- vaddr_t kva_start;
+pmap_bootstrap(vaddr_t kva_start)
{
extern paddr_t avail_end;
struct pmap *kpm;
@@ -1444,9 +1438,7 @@ pmap_init()
*/
struct pv_entry *
-pmap_alloc_pv(pmap, mode)
- struct pmap *pmap;
- int mode;
+pmap_alloc_pv(struct pmap *pmap, int mode)
{
struct pv_page *pvpage;
struct pv_entry *pv;
@@ -1501,9 +1493,7 @@ pmap_alloc_pv(pmap, mode)
*/
struct pv_entry *
-pmap_alloc_pvpage(pmap, mode)
- struct pmap *pmap;
- int mode;
+pmap_alloc_pvpage(struct pmap *pmap, int mode)
{
struct vm_page *pg;
struct pv_page *pvpage;
@@ -1705,9 +1695,7 @@ pmap_try_steal_pv_86(struct pv_head *pvh, struct pv_entry *cpv,
*/
struct pv_entry *
-pmap_add_pvpage(pvp, need_entry)
- struct pv_page *pvp;
- boolean_t need_entry;
+pmap_add_pvpage(struct pv_page *pvp, boolean_t need_entry)
{
int tofree, lcv;
@@ -1738,8 +1726,7 @@ pmap_add_pvpage(pvp, need_entry)
*/
void
-pmap_free_pv_doit(pv)
- struct pv_entry *pv;
+pmap_free_pv_doit(struct pv_entry *pv)
{
struct pv_page *pvp;
@@ -1773,9 +1760,7 @@ pmap_free_pv_doit(pv)
*/
void
-pmap_free_pv(pmap, pv)
- struct pmap *pmap;
- struct pv_entry *pv;
+pmap_free_pv(struct pmap *pmap, struct pv_entry *pv)
{
simple_lock(&pvalloc_lock);
pmap_free_pv_doit(pv);
@@ -1798,9 +1783,7 @@ pmap_free_pv(pmap, pv)
*/
void
-pmap_free_pvs(pmap, pvs)
- struct pmap *pmap;
- struct pv_entry *pvs;
+pmap_free_pvs(struct pmap *pmap, struct pv_entry *pvs)
{
struct pv_entry *nextpv;
@@ -1835,7 +1818,7 @@ pmap_free_pvs(pmap, pvs)
*/
void
-pmap_free_pvpage()
+pmap_free_pvpage(void)
{
int s;
struct vm_map *map;
@@ -1894,15 +1877,14 @@ pmap_free_pvpage()
* => caller should have pmap locked
* => we will gain the lock on the pv_head and allocate the new pv_entry
* => caller should adjust ptp's wire_count before calling
+ *
+ * pve: preallocated pve for us to use
+ * ptp: PTP in pmap that maps this VA
*/
void
-pmap_enter_pv(pvh, pve, pmap, va, ptp)
- struct pv_head *pvh;
- struct pv_entry *pve; /* preallocated pve for us to use */
- struct pmap *pmap;
- vaddr_t va;
- struct vm_page *ptp; /* PTP in pmap that maps this VA */
+pmap_enter_pv(struct pv_head *pvh, struct pv_entry *pve, struct pmap *pmap,
+ vaddr_t va, struct vm_page *ptp)
{
pve->pv_pmap = pmap;
pve->pv_va = va;
@@ -1924,10 +1906,7 @@ pmap_enter_pv(pvh, pve, pmap, va, ptp)
*/
struct pv_entry *
-pmap_remove_pv(pvh, pmap, va)
- struct pv_head *pvh;
- struct pmap *pmap;
- vaddr_t va;
+pmap_remove_pv(struct pv_head *pvh, struct pmap *pmap, vaddr_t va)
{
struct pv_entry *pve, **prevptr;
@@ -1963,10 +1942,7 @@ pmap_remove_pv(pvh, pmap, va)
*/
struct vm_page *
-pmap_alloc_ptp_86(pmap, pde_index, just_try)
- struct pmap *pmap;
- int pde_index;
- boolean_t just_try;
+pmap_alloc_ptp_86(struct pmap *pmap, int pde_index, boolean_t just_try)
{
struct vm_page *ptp;
@@ -2144,7 +2120,7 @@ pmap_get_ptp_86(struct pmap *pmap, int pde_index, boolean_t just_try)
*/
struct pmap *
-pmap_create()
+pmap_create(void)
{
struct pmap *pmap;
@@ -2217,8 +2193,7 @@ pmap_pinit_pd_86(struct pmap *pmap)
*/
void
-pmap_destroy(pmap)
- struct pmap *pmap;
+pmap_destroy(struct pmap *pmap)
{
int refs;
@@ -2250,8 +2225,7 @@ pmap_destroy(pmap)
*/
void
-pmap_release(pmap)
- struct pmap *pmap;
+pmap_release(struct pmap *pmap)
{
struct vm_page *pg;
@@ -2308,8 +2282,7 @@ pmap_release(pmap)
*/
void
-pmap_reference(pmap)
- struct pmap *pmap;
+pmap_reference(struct pmap *pmap)
{
simple_lock(&pmap->pm_obj.vmobjlock);
pmap->pm_obj.uo_refs++;
@@ -2323,8 +2296,7 @@ pmap_reference(pmap)
*/
void
-pmap_fork(pmap1, pmap2)
- struct pmap *pmap1, *pmap2;
+pmap_fork(struct pmap *pmap1, struct pmap *pmap2)
{
simple_lock(&pmap1->pm_obj.vmobjlock);
simple_lock(&pmap2->pm_obj.vmobjlock);
@@ -2357,8 +2329,7 @@ pmap_fork(pmap1, pmap2)
*/
void
-pmap_ldt_cleanup(p)
- struct proc *p;
+pmap_ldt_cleanup(struct proc *p)
{
struct pcb *pcb = &p->p_addr->u_pcb;
pmap_t pmap = p->p_vmspace->vm_map.pmap;
@@ -2401,8 +2372,7 @@ pmap_ldt_cleanup(p)
*/
void
-pmap_activate(p)
- struct proc *p;
+pmap_activate(struct proc *p)
{
struct pcb *pcb = &p->p_addr->u_pcb;
struct pmap *pmap = p->p_vmspace->vm_map.pmap;
@@ -2447,8 +2417,7 @@ pmap_activate(p)
*/
void
-pmap_deactivate(p)
- struct proc *p;
+pmap_deactivate(struct proc *p)
{
struct pmap *pmap = p->p_vmspace->vm_map.pmap;
@@ -2493,9 +2462,7 @@ pmap_extract_86(struct pmap *pmap, vaddr_t va, paddr_t *pap)
*/
void
-pmap_virtual_space(startp, endp)
- vaddr_t *startp;
- vaddr_t *endp;
+pmap_virtual_space(vaddr_t *startp, vaddr_t *endp)
{
*startp = virtual_avail;
*endp = virtual_end;
@@ -2705,12 +2672,8 @@ pmap_remove_ptes_86(struct pmap *pmap, struct vm_page *ptp, vaddr_t ptpva,
*/
boolean_t
-pmap_remove_pte_86(pmap, ptp, pte, va, cpumaskp)
- struct pmap *pmap;
- struct vm_page *ptp;
- pt_entry_t *pte;
- vaddr_t va;
- int32_t *cpumaskp;
+pmap_remove_pte_86(struct pmap *pmap, struct vm_page *ptp, pt_entry_t *pte,
+ vaddr_t va, int32_t *cpumaskp)
{
pt_entry_t opte;
int bank, off;
@@ -3345,8 +3308,7 @@ pmap_unwire_86(struct pmap *pmap, vaddr_t va)
*/
void
-pmap_collect(pmap)
- struct pmap *pmap;
+pmap_collect(struct pmap *pmap)
{
/*
* free all of the pt pages by removing the physical mappings
@@ -3659,9 +3621,7 @@ void pmap_dump_86(struct pmap *, vaddr_t, vaddr_t);
*/
void
-pmap_dump_86(pmap, sva, eva)
- struct pmap *pmap;
- vaddr_t sva, eva;
+pmap_dump_86(struct pmap *pmap, vaddr_t sva, vaddr_t eva)
{
pt_entry_t *ptes, *pte;
vaddr_t blkendva;
@@ -3770,11 +3730,7 @@ pmap_tlb_shootnow(int32_t cpumask)
* Cause the TLB entry for pmap/va to be shot down.
*/
void
-pmap_tlb_shootdown(pmap, va, pte, cpumaskp)
- pmap_t pmap;
- vaddr_t va;
- u_int32_t pte;
- int32_t *cpumaskp;
+pmap_tlb_shootdown(pmap_t pmap, vaddr_t va, u_int32_t pte, int32_t *cpumaskp)
{
struct cpu_info *ci, *self;
struct pmap_tlb_shootdown_q *pq;
@@ -3932,8 +3888,7 @@ pmap_do_tlb_shootdown(struct cpu_info *self)
* Note: We expect the queue to be locked.
*/
void
-pmap_tlb_shootdown_q_drain(pq)
- struct pmap_tlb_shootdown_q *pq;
+pmap_tlb_shootdown_q_drain(struct pmap_tlb_shootdown_q *pq)
{
struct pmap_tlb_shootdown_job *pj;
@@ -3953,8 +3908,7 @@ pmap_tlb_shootdown_q_drain(pq)
* Note: We expect the queue to be locked.
*/
struct pmap_tlb_shootdown_job *
-pmap_tlb_shootdown_job_get(pq)
- struct pmap_tlb_shootdown_q *pq;
+pmap_tlb_shootdown_job_get(struct pmap_tlb_shootdown_q *pq)
{
struct pmap_tlb_shootdown_job *pj;
@@ -3982,9 +3936,8 @@ pmap_tlb_shootdown_job_get(pq)
* Note: We expect the queue to be locked.
*/
void
-pmap_tlb_shootdown_job_put(pq, pj)
- struct pmap_tlb_shootdown_q *pq;
- struct pmap_tlb_shootdown_job *pj;
+pmap_tlb_shootdown_job_put(struct pmap_tlb_shootdown_q *pq,
+ struct pmap_tlb_shootdown_job *pj)
{
#ifdef DIAGNOSTIC
if (pq->pq_count == 0)
diff --git a/sys/arch/i386/i386/process_machdep.c b/sys/arch/i386/i386/process_machdep.c
index 36d97bd426f..c92332cb55a 100644
--- a/sys/arch/i386/i386/process_machdep.c
+++ b/sys/arch/i386/i386/process_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: process_machdep.c,v 1.20 2005/04/03 20:21:44 kettenis Exp $ */
+/* $OpenBSD: process_machdep.c,v 1.21 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: process_machdep.c,v 1.22 1996/05/03 19:42:25 christos Exp $ */
/*
@@ -184,9 +184,7 @@ process_fninit_xmm(struct savexmm *sxmm)
}
int
-process_read_regs(p, regs)
- struct proc *p;
- struct reg *regs;
+process_read_regs(struct proc *p, struct reg *regs)
{
struct trapframe *tf = process_frame(p);
@@ -222,9 +220,7 @@ process_read_regs(p, regs)
}
int
-process_read_fpregs(p, regs)
- struct proc *p;
- struct fpreg *regs;
+process_read_fpregs(struct proc *p, struct fpreg *regs)
{
union savefpu *frame = process_fpframe(p);
@@ -266,9 +262,7 @@ process_read_fpregs(p, regs)
#ifdef PTRACE
int
-process_write_regs(p, regs)
- struct proc *p;
- struct reg *regs;
+process_write_regs(struct proc *p, struct reg *regs)
{
struct trapframe *tf = process_frame(p);
@@ -311,9 +305,7 @@ process_write_regs(p, regs)
}
int
-process_write_fpregs(p, regs)
- struct proc *p;
- struct fpreg *regs;
+process_write_fpregs(struct proc *p, struct fpreg *regs)
{
union savefpu *frame = process_fpframe(p);
@@ -378,9 +370,7 @@ process_write_xmmregs(struct proc *p, const struct xmmregs *regs)
}
int
-process_sstep(p, sstep)
- struct proc *p;
- int sstep;
+process_sstep(struct proc *p, int sstep)
{
struct trapframe *tf = process_frame(p);
@@ -393,9 +383,7 @@ process_sstep(p, sstep)
}
int
-process_set_pc(p, addr)
- struct proc *p;
- caddr_t addr;
+process_set_pc(struct proc *p, caddr_t addr)
{
struct trapframe *tf = process_frame(p);
diff --git a/sys/arch/i386/i386/rbus_machdep.c b/sys/arch/i386/i386/rbus_machdep.c
index f68988e06f6..1f4d7c3c7d1 100644
--- a/sys/arch/i386/i386/rbus_machdep.c
+++ b/sys/arch/i386/i386/rbus_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rbus_machdep.c,v 1.17 2005/04/09 00:41:27 reyk Exp $ */
+/* $OpenBSD: rbus_machdep.c,v 1.18 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: rbus_machdep.c,v 1.2 1999/10/15 06:43:06 haya Exp $ */
/*
@@ -63,9 +63,7 @@
#define RBUS_MEM_SIZE 0x00100000
rbus_tag_t
-rbus_pccbb_parent_mem(self, pa)
- struct device *self;
- struct pci_attach_args *pa;
+rbus_pccbb_parent_mem(struct device *self, struct pci_attach_args *pa)
{
bus_addr_t start, min_start;
bus_size_t size;
@@ -111,9 +109,7 @@ rbus_pccbb_parent_mem(self, pa)
#define RBUS_IO_SIZE 0x1000
rbus_tag_t
-rbus_pccbb_parent_io(self, pa)
- struct device *self;
- struct pci_attach_args *pa;
+rbus_pccbb_parent_io(struct device *self, struct pci_attach_args *pa)
{
struct extent *ex;
bus_addr_t start;
diff --git a/sys/arch/i386/i386/svr4_machdep.c b/sys/arch/i386/i386/svr4_machdep.c
index 19885272a4f..001b7ec6287 100644
--- a/sys/arch/i386/i386/svr4_machdep.c
+++ b/sys/arch/i386/i386/svr4_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: svr4_machdep.c,v 1.23 2006/05/11 13:21:12 mickey Exp $ */
+/* $OpenBSD: svr4_machdep.c,v 1.24 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: svr4_machdep.c,v 1.24 1996/05/03 19:42:26 christos Exp $ */
/*
@@ -59,10 +59,8 @@
static void svr4_getsiginfo(union svr4_siginfo *, int, u_long, int, caddr_t);
void
-svr4_getcontext(p, uc, mask, oonstack)
- struct proc *p;
- struct svr4_ucontext *uc;
- int mask, oonstack;
+svr4_getcontext(struct proc *p, struct svr4_ucontext *uc, int mask,
+ int oonstack)
{
struct trapframe *tf = p->p_md.md_regs;
struct sigacts *psp = p->p_sigacts;
@@ -134,12 +132,10 @@ svr4_getcontext(p, uc, mask, oonstack)
* a machine fault.
*/
int
-svr4_setcontext(p, uc)
- struct proc *p;
- struct svr4_ucontext *uc;
+svr4_setcontext(struct proc *p, struct svr4_ucontext *uc)
{
struct sigacts *psp = p->p_sigacts;
- register struct trapframe *tf;
+ struct trapframe *tf;
svr4_greg_t *r = uc->uc_mcontext.greg;
struct svr4_sigaltstack *s = &uc->uc_stack;
struct sigaltstack *sf = &psp->ps_sigstk;
@@ -213,12 +209,8 @@ svr4_setcontext(p, uc)
static void
-svr4_getsiginfo(si, sig, code, type, addr)
- union svr4_siginfo *si;
- int sig;
- u_long code;
- int type;
- caddr_t addr;
+svr4_getsiginfo(union svr4_siginfo *si, int sig, u_long code, int type,
+ caddr_t addr)
{
si->svr4_si_signo = bsd_to_svr4_sig[sig];
si->svr4_si_errno = 0;
@@ -314,15 +306,11 @@ svr4_getsiginfo(si, sig, code, type, addr)
* will return to the user pc, psl.
*/
void
-svr4_sendsig(catcher, sig, mask, code, type, val)
- sig_t catcher;
- int sig, mask;
- u_long code;
- int type;
- union sigval val;
+svr4_sendsig(sig_t catcher, int sig, int mask, u_long code, int type,
+ union sigval val)
{
- register struct proc *p = curproc;
- register struct trapframe *tf;
+ struct proc *p = curproc;
+ struct trapframe *tf;
struct svr4_sigframe *fp, frame;
struct sigacts *psp = p->p_sigacts;
int oonstack;
@@ -390,10 +378,7 @@ svr4_sendsig(catcher, sig, mask, code, type, val)
* sysi86
*/
int
-svr4_sys_sysarch(p, v, retval)
- struct proc *p;
- void *v;
- register_t *retval;
+svr4_sys_sysarch(struct proc *p, void *v, register_t *retval)
{
struct svr4_sys_sysarch_args *uap = v;
int error;
diff --git a/sys/arch/i386/i386/sys_machdep.c b/sys/arch/i386/i386/sys_machdep.c
index abbcd816cf9..e365d2e1de7 100644
--- a/sys/arch/i386/i386/sys_machdep.c
+++ b/sys/arch/i386/i386/sys_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sys_machdep.c,v 1.25 2006/05/11 13:21:12 mickey Exp $ */
+/* $OpenBSD: sys_machdep.c,v 1.26 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: sys_machdep.c,v 1.28 1996/05/03 19:42:29 christos Exp $ */
/*-
@@ -79,9 +79,7 @@ int i386_set_ioperm(struct proc *, void *, register_t *);
static void i386_print_ldt(int, const struct segment_descriptor *);
static void
-i386_print_ldt(i, d)
- int i;
- const struct segment_descriptor *d;
+i386_print_ldt(int i, const struct segment_descriptor *d)
{
printf("[%d] lolimit=0x%x, lobase=0x%x, type=%u, dpl=%u, p=%u, "
"hilimit=0x%x, xx=%x, def32=%u, gran=%u, hibase=0x%x\n",
@@ -91,10 +89,7 @@ i386_print_ldt(i, d)
#endif
int
-i386_get_ldt(p, args, retval)
- struct proc *p;
- void *args;
- register_t *retval;
+i386_get_ldt(struct proc *p, void *args, register_t *retval)
{
int error;
pmap_t pmap = p->p_vmspace->vm_map.pmap;
@@ -159,10 +154,7 @@ i386_get_ldt(p, args, retval)
}
int
-i386_set_ldt(p, args, retval)
- struct proc *p;
- void *args;
- register_t *retval;
+i386_set_ldt(struct proc *p, void *args, register_t *retval)
{
int error, i, n;
struct pcb *pcb = &p->p_addr->u_pcb;
@@ -335,10 +327,7 @@ extern int allowaperture;
#endif
int
-i386_iopl(p, args, retval)
- struct proc *p;
- void *args;
- register_t *retval;
+i386_iopl(struct proc *p, void *args, register_t *retval)
{
int error;
struct trapframe *tf = p->p_md.md_regs;
@@ -366,10 +355,7 @@ i386_iopl(p, args, retval)
}
int
-i386_get_ioperm(p, args, retval)
- struct proc *p;
- void *args;
- register_t *retval;
+i386_get_ioperm(struct proc *p, void *args, register_t *retval)
{
int error;
struct pcb *pcb = &p->p_addr->u_pcb;
@@ -382,10 +368,7 @@ i386_get_ioperm(p, args, retval)
}
int
-i386_set_ioperm(p, args, retval)
- struct proc *p;
- void *args;
- register_t *retval;
+i386_set_ioperm(struct proc *p, void *args, register_t *retval)
{
int error;
struct pcb *pcb = &p->p_addr->u_pcb;
@@ -408,10 +391,7 @@ i386_set_ioperm(p, args, retval)
}
int
-sys_sysarch(p, v, retval)
- struct proc *p;
- void *v;
- register_t *retval;
+sys_sysarch(struct proc *p, void *v, register_t *retval)
{
struct sys_sysarch_args /* {
syscallarg(int) op;
diff --git a/sys/arch/i386/i386/trap.c b/sys/arch/i386/i386/trap.c
index e0d45461578..7392782d26a 100644
--- a/sys/arch/i386/i386/trap.c
+++ b/sys/arch/i386/i386/trap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: trap.c,v 1.77 2006/08/22 20:09:25 mickey Exp $ */
+/* $OpenBSD: trap.c,v 1.78 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: trap.c,v 1.95 1996/05/05 06:50:02 mycroft Exp $ */
/*-
@@ -107,10 +107,7 @@ void syscall(struct trapframe);
* trap and syscall.
*/
static __inline void
-userret(p, pc, oticks)
- register struct proc *p;
- int pc;
- u_quad_t oticks;
+userret(struct proc *p, int pc, u_quad_t oticks)
{
int sig;
@@ -178,10 +175,9 @@ int trapdebug = 0;
*/
/*ARGSUSED*/
void
-trap(frame)
- struct trapframe frame;
+trap(struct trapframe frame)
{
- register struct proc *p = curproc;
+ struct proc *p = curproc;
int type = frame.tf_trapno;
u_quad_t sticks;
struct pcb *pcb = NULL;
@@ -623,12 +619,11 @@ trapwrite(unsigned int addr)
*/
/*ARGSUSED*/
void
-syscall(frame)
- struct trapframe frame;
+syscall(struct trapframe frame)
{
- register caddr_t params;
- register struct sysent *callp;
- register struct proc *p;
+ caddr_t params;
+ struct sysent *callp;
+ struct proc *p;
int orig_error, error, opc, nsys;
size_t argsize;
register_t code, args[8], rval[2];
@@ -819,8 +814,7 @@ syscall(frame)
}
void
-child_return(arg)
- void *arg;
+child_return(void *arg)
{
struct proc *p = (struct proc *)arg;
struct trapframe *tf = p->p_md.md_regs;
diff --git a/sys/arch/i386/i386/vm86.c b/sys/arch/i386/i386/vm86.c
index 906d071cb4d..3211e34829e 100644
--- a/sys/arch/i386/i386/vm86.c
+++ b/sys/arch/i386/i386/vm86.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: vm86.c,v 1.16 2006/05/11 13:21:12 mickey Exp $ */
+/* $OpenBSD: vm86.c,v 1.17 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: vm86.c,v 1.15 1996/05/03 19:42:33 christos Exp $ */
/*-
@@ -142,9 +142,7 @@ __res; })
static __inline int
-is_bitset(nr, bitmap)
- int nr;
- caddr_t bitmap;
+is_bitset(int nr, caddr_t bitmap)
{
u_int byte; /* bt instruction doesn't do
bytes--it examines ints! */
@@ -163,9 +161,7 @@ is_bitset(nr, bitmap)
#define V86_AL(regs) (((u_char *)&((regs)->tf_eax))[0])
static void
-fast_intxx(p, intrno)
- struct proc *p;
- int intrno;
+fast_intxx(struct proc *p, int intrno)
{
struct trapframe *tf = p->p_md.md_regs;
/*
@@ -234,9 +230,7 @@ bad:
}
void
-vm86_return(p, retval)
- struct proc *p;
- int retval;
+vm86_return(struct proc *p, int retval)
{
union sigval sv;
@@ -274,9 +268,7 @@ vm86_return(p, retval)
* handler code and then having it restart VM86 mode).
*/
void
-vm86_gpfault(p, type)
- struct proc *p;
- int type;
+vm86_gpfault(struct proc *p, int type)
{
struct trapframe *tf = p->p_md.md_regs;
union sigval sv;
@@ -383,10 +375,7 @@ bad:
}
int
-i386_vm86(p, args, retval)
- struct proc *p;
- char *args;
- register_t *retval;
+i386_vm86(struct proc *p, char *args, register_t *retval)
{
struct trapframe *tf = p->p_md.md_regs;
struct pcb *pcb = &p->p_addr->u_pcb;
diff --git a/sys/arch/i386/i386/vm_machdep.c b/sys/arch/i386/i386/vm_machdep.c
index a5c1eb0e434..480ab5a8bfc 100644
--- a/sys/arch/i386/i386/vm_machdep.c
+++ b/sys/arch/i386/i386/vm_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: vm_machdep.c,v 1.45 2006/06/23 13:46:05 mickey Exp $ */
+/* $OpenBSD: vm_machdep.c,v 1.46 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: vm_machdep.c,v 1.61 1996/05/03 19:42:35 christos Exp $ */
/*-
@@ -73,12 +73,8 @@
* the frame pointers on the stack after copying.
*/
void
-cpu_fork(p1, p2, stack, stacksize, func, arg)
- struct proc *p1, *p2;
- void *stack;
- size_t stacksize;
- void (*func)(void *);
- void *arg;
+cpu_fork(struct proc *p1, struct proc *p2, void *stack, size_t stacksize,
+ void (*func)(void *), void *arg)
{
struct pcb *pcb = &p2->p_addr->u_pcb;
struct trapframe *tf;
@@ -138,8 +134,7 @@ cpu_fork(p1, p2, stack, stacksize, func, arg)
}
void
-cpu_swapout(p)
- struct proc *p;
+cpu_swapout(struct proc *p)
{
#if NNPX > 0
@@ -159,8 +154,7 @@ cpu_swapout(p)
* into switch() to wait for another process to wake up.
*/
void
-cpu_exit(p)
- register struct proc *p;
+cpu_exit(struct proc *p)
{
#if NNPX > 0
/* If we were using the FPU, forget about it. */
@@ -172,8 +166,7 @@ cpu_exit(p)
}
void
-cpu_wait(p)
- struct proc *p;
+cpu_wait(struct proc *p)
{
tss_free(p->p_md.md_tss_sel);
}
@@ -187,11 +180,8 @@ struct md_core {
};
int
-cpu_coredump(p, vp, cred, chdr)
- struct proc *p;
- struct vnode *vp;
- struct ucred *cred;
- struct core *chdr;
+cpu_coredump(struct proc *p, struct vnode *vp, struct ucred *cred,
+ struct core *chdr)
{
struct md_core md_core;
struct coreseg cseg;
@@ -237,9 +227,7 @@ cpu_coredump(p, vp, cred, chdr)
* Both addresses are assumed to reside in the Sysmap.
*/
void
-pagemove(from, to, size)
- caddr_t from, to;
- size_t size;
+pagemove(caddr_t from, caddr_t to, size_t size)
{
u_int32_t ofpte, otpte;
#ifdef MULTIPROCESSOR
diff --git a/sys/arch/i386/isa/ahc_isa.c b/sys/arch/i386/isa/ahc_isa.c
index c2c0ad8a608..75237730d07 100644
--- a/sys/arch/i386/isa/ahc_isa.c
+++ b/sys/arch/i386/isa/ahc_isa.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ahc_isa.c,v 1.14 2004/12/25 23:02:24 miod Exp $ */
+/* $OpenBSD: ahc_isa.c,v 1.15 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: ahc_isa.c,v 1.5 1996/10/21 22:27:39 thorpej Exp $ */
/*
@@ -145,9 +145,7 @@ static int ahc_isa_slot_initialized;
* Return irq setting of the board, otherwise -1.
*/
int
-ahc_isa_irq(iot, ioh)
- bus_space_tag_t iot;
- bus_space_handle_t ioh;
+ahc_isa_irq(bus_space_tag_t iot, bus_space_handle_t ioh)
{
int irq;
u_char intdef;
@@ -176,10 +174,7 @@ ahc_isa_irq(iot, ioh)
}
int
-ahc_isa_idstring(iot, ioh, idstring)
- bus_space_tag_t iot;
- bus_space_handle_t ioh;
- char *idstring;
+ahc_isa_idstring(bus_space_tag_t iot, bus_space_handle_t ioh, char *idstring)
{
u_int8_t vid[EISA_NVIDREGS], pid[EISA_NPIDREGS];
int i;
@@ -229,9 +224,7 @@ ahc_isa_idstring(iot, ioh, idstring)
}
int
-ahc_isa_match(ia, iobase)
- struct isa_attach_args *ia;
- bus_addr_t iobase;
+ahc_isa_match(struct isa_attach_args *ia, bus_addr_t iobase)
{
bus_space_tag_t iot = ia->ia_iot;
bus_space_handle_t ioh;
@@ -290,9 +283,7 @@ ahc_isa_match(ia, iobase)
* the actual probe routine to check it out.
*/
int
-ahc_isa_probe(parent, match, aux)
- struct device *parent;
- void *match, *aux;
+ahc_isa_probe(struct device *parent, void *match, void *aux)
{
struct isa_attach_args *ia = aux;
struct ahc_isa_slot *as;
@@ -340,9 +331,7 @@ ahc_isa_probe(parent, match, aux)
}
void
-ahc_isa_attach(parent, self, aux)
- struct device *parent, *self;
- void *aux;
+ahc_isa_attach(struct device *parent, struct device *self, void *aux)
{
struct ahc_softc *ahc = (void *)self;
struct isa_attach_args *ia = aux;
diff --git a/sys/arch/i386/isa/clock.c b/sys/arch/i386/isa/clock.c
index d18f216c533..4c8a4073c8c 100644
--- a/sys/arch/i386/isa/clock.c
+++ b/sys/arch/i386/isa/clock.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: clock.c,v 1.36 2006/06/19 15:13:35 deraadt Exp $ */
+/* $OpenBSD: clock.c,v 1.37 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: clock.c,v 1.39 1996/05/12 23:11:54 mycroft Exp $ */
/*-
@@ -129,9 +129,7 @@ int clock_broken_latch;
#define SECHOUR ((unsigned)(60*SECMIN)) /* seconds per hour */
u_int
-mc146818_read(sc, reg)
- void *sc; /* XXX use it? */
- u_int reg;
+mc146818_read(void *sc, u_int reg)
{
int s;
u_char v;
@@ -146,9 +144,7 @@ mc146818_read(sc, reg)
}
void
-mc146818_write(sc, reg, datum)
- void *sc; /* XXX use it? */
- u_int reg, datum;
+mc146818_write(void *sc, u_int reg, u_int datum)
{
int s;
@@ -161,7 +157,7 @@ mc146818_write(sc, reg, datum)
}
void
-startrtclock()
+startrtclock(void)
{
int s;
@@ -192,7 +188,7 @@ rtcdrain(void *v)
}
void
-initrtclock()
+initrtclock(void)
{
/* initialize 8253 clock */
outb(TIMER_MODE, TIMER_SEL0|TIMER_RATEGEN|TIMER_16BIT);
@@ -203,8 +199,7 @@ initrtclock()
}
int
-clockintr(arg)
- void *arg;
+clockintr(void *arg)
{
struct clockframe *frame = arg; /* not strictly necessary */
@@ -213,8 +208,7 @@ clockintr(arg)
}
int
-rtcintr(arg)
- void *arg;
+rtcintr(void *arg)
{
struct clockframe *frame = arg; /* not strictly necessary */
u_int stat = 0;
@@ -231,7 +225,7 @@ rtcintr(arg)
}
int
-gettick()
+gettick(void)
{
#if defined(I586_CPU) || defined(I686_CPU)
@@ -305,8 +299,7 @@ gettick()
* wave' mode counts at 2:1).
*/
void
-i8254_delay(n)
- int n;
+i8254_delay(int n)
{
int limit, tick, otick;
@@ -362,7 +355,7 @@ unsigned int delaycount; /* calibrated loop variable (1 millisecond) */
#define FIRST_GUESS 0x2000
void
-findcpuspeed()
+findcpuspeed(void)
{
int i;
int remainder;
@@ -384,7 +377,7 @@ findcpuspeed()
#if defined(I586_CPU) || defined(I686_CPU)
void
-calibrate_cyclecounter()
+calibrate_cyclecounter(void)
{
unsigned long long count, last_count;
@@ -396,7 +389,7 @@ calibrate_cyclecounter()
#endif
void
-i8254_initclocks()
+i8254_initclocks(void)
{
static struct timeout rtcdrain_timeout;
stathz = 128;
@@ -428,8 +421,7 @@ i8254_initclocks()
}
int
-rtcget(regs)
- mc_todregs *regs;
+rtcget(mc_todregs *regs)
{
if ((mc146818_read(NULL, MC_REGD) & MC_REGD_VRT) == 0) /* XXX softc */
return (-1);
@@ -438,23 +430,20 @@ rtcget(regs)
}
void
-rtcput(regs)
- mc_todregs *regs;
+rtcput(mc_todregs *regs)
{
MC146818_PUTTOD(NULL, regs); /* XXX softc */
}
int
-hexdectodec(n)
- int n;
+hexdectodec(int n)
{
return (((n >> 4) & 0x0f) * 10 + (n & 0x0f));
}
int
-dectohexdec(n)
- int n;
+dectohexdec(int n)
{
return ((u_char)(((n / 10) << 4) & 0xf0) | ((n % 10) & 0x0f));
@@ -468,7 +457,7 @@ static int timeset;
*/
int cmoscheck(void);
int
-cmoscheck()
+cmoscheck(void)
{
int i;
unsigned short cksum = 0;
@@ -495,8 +484,7 @@ int rtc_update_century = 0;
*/
int clock_expandyear(int);
int
-clock_expandyear(clockyear)
- int clockyear;
+clock_expandyear(int clockyear)
{
int s, clockcentury, cmoscentury;
@@ -547,8 +535,7 @@ clock_expandyear(clockyear)
* from a filesystem.
*/
void
-inittodr(base)
- time_t base;
+inittodr(time_t base)
{
mc_todregs rtclk;
struct clock_ymdhms dt;
@@ -630,7 +617,7 @@ fstime:
* Reset the clock.
*/
void
-resettodr()
+resettodr(void)
{
mc_todregs rtclk;
struct clock_ymdhms dt;
@@ -672,8 +659,7 @@ resettodr()
}
void
-setstatclockrate(arg)
- int arg;
+setstatclockrate(int arg)
{
if (arg == stathz)
mc146818_write(NULL, MC_REGA, MC_BASE_32_KHz | MC_RATE_128_Hz);
diff --git a/sys/arch/i386/isa/isa_machdep.c b/sys/arch/i386/isa/isa_machdep.c
index a8e203f8ff1..ed7165b5bf7 100644
--- a/sys/arch/i386/isa/isa_machdep.c
+++ b/sys/arch/i386/isa/isa_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: isa_machdep.c,v 1.54 2005/11/24 08:37:08 mickey Exp $ */
+/* $OpenBSD: isa_machdep.c,v 1.55 2006/09/19 11:06:33 jsg Exp $ */
/* $NetBSD: isa_machdep.c,v 1.22 1997/06/12 23:57:32 thorpej Exp $ */
#define ISA_DMA_STATS
@@ -214,7 +214,7 @@ struct i386_bus_dma_tag isa_bus_dma_tag = {
* during configuration of kernel, setup interrupt control unit
*/
void
-isa_defaultirq()
+isa_defaultirq(void)
{
int i;
@@ -253,7 +253,7 @@ isa_defaultirq()
}
void
-isa_nodefaultirq()
+isa_nodefaultirq(void)
{
int i;
@@ -267,7 +267,7 @@ isa_nodefaultirq()
* return true to panic system, false to ignore.
*/
int
-isa_nmi()
+isa_nmi(void)
{
/* This is historic garbage; these ports are not readable */
log(LOG_CRIT, "No-maskable interrupt, may be parity error\n");
@@ -280,8 +280,7 @@ u_long intrstray[ICU_LEN];
* Caught a stray interrupt, notify
*/
void
-isa_strayintr(irq)
- int irq;
+isa_strayintr(int irq)
{
/*
* Stray interrupts on irq 7 occur when an interrupt line is raised
@@ -308,7 +307,7 @@ int iunmask[NIPL]; /* Bitmask telling what interrupts are accepted. */
* happen very much anyway.
*/
void
-intr_calculatemasks()
+intr_calculatemasks(void)
{
int irq, level, unusedirqs;
struct intrhand *q;
@@ -407,11 +406,7 @@ fakeintr(arg)
#define LEGAL_IRQ(x) ((x) >= 0 && (x) < ICU_LEN && (x) != 2)
int
-isa_intr_alloc(ic, mask, type, irq)
- isa_chipset_tag_t ic;
- int mask;
- int type;
- int *irq;
+isa_intr_alloc(isa_chipset_tag_t ic, int mask, int type, int *irq)
{
int i, bestirq, count;
int tmp;
@@ -487,10 +482,7 @@ isa_intr_alloc(ic, mask, type, irq)
* 2 = interrupt all to ourself
*/
int
-isa_intr_check(ic, irq, type)
- isa_chipset_tag_t ic; /* Not used. */
- int irq;
- int type;
+isa_intr_check(isa_chipset_tag_t ic, int irq, int type)
{
if (!LEGAL_IRQ(irq) || type == IST_NONE)
return (0);
@@ -517,14 +509,8 @@ isa_intr_check(ic, irq, type)
* XXX PRONE TO RACE CONDITIONS, UGLY, 'INTERESTING' INSERTION ALGORITHM.
*/
void *
-isa_intr_establish(ic, irq, type, level, ih_fun, ih_arg, ih_what)
- isa_chipset_tag_t ic;
- int irq;
- int type;
- int level;
- int (*ih_fun)(void *);
- void *ih_arg;
- char *ih_what;
+isa_intr_establish(isa_chipset_tag_t ic, int irq, int type, int level,
+ int (*ih_fun)(void *), void *ih_arg, char *ih_what)
{
struct intrhand **p, *q, *ih;
static struct intrhand fakehand = {fakeintr};
@@ -631,9 +617,7 @@ isa_intr_establish(ic, irq, type, level, ih_fun, ih_arg, ih_what)
* Deregister an interrupt handler.
*/
void
-isa_intr_disestablish(ic, arg)
- isa_chipset_tag_t ic;
- void *arg;
+isa_intr_disestablish(isa_chipset_tag_t ic, void *arg)
{
struct intrhand *ih = arg;
int irq = ih->ih_irq;
@@ -669,9 +653,8 @@ isa_intr_disestablish(ic, arg)
}
void
-isa_attach_hook(parent, self, iba)
- struct device *parent, *self;
- struct isabus_attach_args *iba;
+isa_attach_hook(struct device *parent, struct device *self,
+ struct isabus_attach_args *iba)
{
extern int isa_has_been_seen;
@@ -709,14 +692,8 @@ u_long isa_dma_stats_nbouncebufs;
* Create an ISA DMA map.
*/
int
-_isa_bus_dmamap_create(t, size, nsegments, maxsegsz, boundary, flags, dmamp)
- bus_dma_tag_t t;
- bus_size_t size;
- int nsegments;
- bus_size_t maxsegsz;
- bus_size_t boundary;
- int flags;
- bus_dmamap_t *dmamp;
+_isa_bus_dmamap_create(bus_dma_tag_t t, bus_size_t size, int nsegments,
+ bus_size_t maxsegsz, bus_size_t boundary, int flags, bus_dmamap_t *dmamp)
{
struct i386_isa_dma_cookie *cookie;
bus_dmamap_t map;
@@ -802,9 +779,7 @@ _isa_bus_dmamap_create(t, size, nsegments, maxsegsz, boundary, flags, dmamp)
* Destroy an ISA DMA map.
*/
void
-_isa_bus_dmamap_destroy(t, map)
- bus_dma_tag_t t;
- bus_dmamap_t map;
+_isa_bus_dmamap_destroy(bus_dma_tag_t t, bus_dmamap_t map)
{
struct i386_isa_dma_cookie *cookie = map->_dm_cookie;
@@ -822,13 +797,8 @@ _isa_bus_dmamap_destroy(t, map)
* Load an ISA DMA map with a linear buffer.
*/
int
-_isa_bus_dmamap_load(t, map, buf, buflen, p, flags)
- bus_dma_tag_t t;
- bus_dmamap_t map;
- void *buf;
- bus_size_t buflen;
- struct proc *p;
- int flags;
+_isa_bus_dmamap_load(bus_dma_tag_t t, bus_dmamap_t map, void *buf,
+ bus_size_t buflen, struct proc *p, int flags)
{
struct i386_isa_dma_cookie *cookie = map->_dm_cookie;
int error;
@@ -894,11 +864,8 @@ _isa_bus_dmamap_load(t, map, buf, buflen, p, flags)
* Like _isa_bus_dmamap_load(), but for mbufs.
*/
int
-_isa_bus_dmamap_load_mbuf(t, map, m, flags)
- bus_dma_tag_t t;
- bus_dmamap_t map;
- struct mbuf *m;
- int flags;
+_isa_bus_dmamap_load_mbuf(bus_dma_tag_t t, bus_dmamap_t map, struct mbuf *m,
+ int flags)
{
panic("_isa_bus_dmamap_load_mbuf: not implemented");
@@ -908,11 +875,8 @@ _isa_bus_dmamap_load_mbuf(t, map, m, flags)
* Like _isa_bus_dmamap_load(), but for uios.
*/
int
-_isa_bus_dmamap_load_uio(t, map, uio, flags)
- bus_dma_tag_t t;
- bus_dmamap_t map;
- struct uio *uio;
- int flags;
+_isa_bus_dmamap_load_uio(bus_dma_tag_t t, bus_dmamap_t map, struct uio *uio,
+ int flags)
{
panic("_isa_bus_dmamap_load_uio: not implemented");
@@ -923,13 +887,8 @@ _isa_bus_dmamap_load_uio(t, map, uio, flags)
* bus_dmamem_alloc().
*/
int
-_isa_bus_dmamap_load_raw(t, map, segs, nsegs, size, flags)
- bus_dma_tag_t t;
- bus_dmamap_t map;
- bus_dma_segment_t *segs;
- int nsegs;
- bus_size_t size;
- int flags;
+_isa_bus_dmamap_load_raw(bus_dma_tag_t t, bus_dmamap_t map,
+ bus_dma_segment_t *segs, int nsegs, bus_size_t size, int flags)
{
panic("_isa_bus_dmamap_load_raw: not implemented");
@@ -939,9 +898,7 @@ _isa_bus_dmamap_load_raw(t, map, segs, nsegs, size, flags)
* Unload an ISA DMA map.
*/
void
-_isa_bus_dmamap_unload(t, map)
- bus_dma_tag_t t;
- bus_dmamap_t map;
+_isa_bus_dmamap_unload(bus_dma_tag_t t, bus_dmamap_t map)
{
struct i386_isa_dma_cookie *cookie = map->_dm_cookie;
@@ -965,12 +922,8 @@ _isa_bus_dmamap_unload(t, map)
* Synchronize an ISA DMA map.
*/
void
-_isa_bus_dmamap_sync(t, map, offset, len, op)
- bus_dma_tag_t t;
- bus_dmamap_t map;
- bus_addr_t offset;
- bus_size_t len;
- int op;
+_isa_bus_dmamap_sync(bus_dma_tag_t t, bus_dmamap_t map, bus_addr_t offset,
+ bus_size_t len, int op)
{
struct i386_isa_dma_cookie *cookie = map->_dm_cookie;
@@ -1029,13 +982,9 @@ _isa_bus_dmamap_sync(t, map, offset, len, op)
* Allocate memory safe for ISA DMA.
*/
int
-_isa_bus_dmamem_alloc(t, size, alignment, boundary, segs, nsegs, rsegs, flags)
- bus_dma_tag_t t;
- bus_size_t size, alignment, boundary;
- bus_dma_segment_t *segs;
- int nsegs;
- int *rsegs;
- int flags;
+_isa_bus_dmamem_alloc(bus_dma_tag_t t, bus_size_t size, bus_size_t alignment,
+ bus_size_t boundary, bus_dma_segment_t *segs, int nsegs, int *rsegs,
+ int flags)
{
paddr_t high;
@@ -1052,10 +1001,7 @@ _isa_bus_dmamem_alloc(t, size, alignment, boundary, segs, nsegs, rsegs, flags)
* Free memory safe for ISA DMA.
*/
void
-_isa_bus_dmamem_free(t, segs, nsegs)
- bus_dma_tag_t t;
- bus_dma_segment_t *segs;
- int nsegs;
+_isa_bus_dmamem_free(bus_dma_tag_t t, bus_dma_segment_t *segs, int nsegs)
{
_bus_dmamem_free(t, segs, nsegs);
@@ -1065,13 +1011,8 @@ _isa_bus_dmamem_free(t, segs, nsegs)
* Map ISA DMA-safe memory into kernel virtual address space.
*/
int
-_isa_bus_dmamem_map(t, segs, nsegs, size, kvap, flags)
- bus_dma_tag_t t;
- bus_dma_segment_t *segs;
- int nsegs;
- size_t size;
- caddr_t *kvap;
- int flags;
+_isa_bus_dmamem_map(bus_dma_tag_t t, bus_dma_segment_t *segs, int nsegs,
+ size_t size, caddr_t *kvap, int flags)
{
return (_bus_dmamem_map(t, segs, nsegs, size, kvap, flags));
@@ -1081,10 +1022,7 @@ _isa_bus_dmamem_map(t, segs, nsegs, size, kvap, flags)
* Unmap ISA DMA-safe memory from kernel virtual address space.
*/
void
-_isa_bus_dmamem_unmap(t, kva, size)
- bus_dma_tag_t t;
- caddr_t kva;
- size_t size;
+_isa_bus_dmamem_unmap(bus_dma_tag_t t, caddr_t kva, size_t size)
{
_bus_dmamem_unmap(t, kva, size);
@@ -1094,12 +1032,8 @@ _isa_bus_dmamem_unmap(t, kva, size)
* mmap(2) ISA DMA-safe memory.
*/
paddr_t
-_isa_bus_dmamem_mmap(t, segs, nsegs, off, prot, flags)
- bus_dma_tag_t t;
- bus_dma_segment_t *segs;
- int nsegs;
- off_t off;
- int prot, flags;
+_isa_bus_dmamem_mmap(bus_dma_tag_t t, bus_dma_segment_t *segs, int nsegs,
+ off_t off, int prot, int flags)
{
return (_bus_dmamem_mmap(t, segs, nsegs, off, prot, flags));
@@ -1114,12 +1048,8 @@ _isa_bus_dmamem_mmap(t, segs, nsegs, off, prot, flags)
* range RAM.
*/
int
-_isa_dma_check_buffer(buf, buflen, segcnt, boundary, p)
- void *buf;
- bus_size_t buflen;
- int segcnt;
- bus_size_t boundary;
- struct proc *p;
+_isa_dma_check_buffer(void *buf, bus_size_t buflen, int segcnt,
+ bus_size_t boundary, struct proc *p)
{
vaddr_t vaddr = (vaddr_t)buf;
vaddr_t endva;
@@ -1175,11 +1105,7 @@ _isa_dma_check_buffer(buf, buflen, segcnt, boundary, p)
}
int
-_isa_dma_alloc_bouncebuf(t, map, size, flags)
- bus_dma_tag_t t;
- bus_dmamap_t map;
- bus_size_t size;
- int flags;
+_isa_dma_alloc_bouncebuf(bus_dma_tag_t t, bus_dmamap_t map, bus_size_t size, int flags)
{
struct i386_isa_dma_cookie *cookie = map->_dm_cookie;
int error = 0;
@@ -1209,9 +1135,7 @@ _isa_dma_alloc_bouncebuf(t, map, size, flags)
}
void
-_isa_dma_free_bouncebuf(t, map)
- bus_dma_tag_t t;
- bus_dmamap_t map;
+_isa_dma_free_bouncebuf(bus_dma_tag_t t, bus_dmamap_t map)
{
struct i386_isa_dma_cookie *cookie = map->_dm_cookie;
diff --git a/sys/arch/i386/isa/isapnp_machdep.c b/sys/arch/i386/isa/isapnp_machdep.c
index a147c923a02..6d26ad73824 100644
--- a/sys/arch/i386/isa/isapnp_machdep.c
+++ b/sys/arch/i386/isa/isapnp_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: isapnp_machdep.c,v 1.2 1997/12/25 09:19:37 downsj Exp $ */
+/* $OpenBSD: isapnp_machdep.c,v 1.3 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: isapnp_machdep.c,v 1.5 1997/10/04 17:32:30 thorpej Exp $ */
/*-
@@ -96,8 +96,7 @@
* Map I/O regions used by PnP
*/
int
-isapnp_map(sc)
- struct isapnp_softc *sc;
+isapnp_map(struct isapnp_softc *sc)
{
#ifdef DIAGNOSTIC
@@ -114,8 +113,7 @@ isapnp_map(sc)
* Unmap I/O regions used by PnP
*/
void
-isapnp_unmap(sc)
- struct isapnp_softc *sc;
+isapnp_unmap(struct isapnp_softc *sc)
{
/* Do nothing. */
@@ -128,8 +126,7 @@ isapnp_unmap(sc)
* NOTE: assumes the caller has filled in sc->sc_read_port!
*/
int
-isapnp_map_readport(sc)
- struct isapnp_softc *sc;
+isapnp_map_readport(struct isapnp_softc *sc)
{
#ifdef _KERNEL
int error;
@@ -160,8 +157,7 @@ isapnp_map_readport(sc)
* Pretend to unmap a previously mapped `read port'.
*/
void
-isapnp_unmap_readport(sc)
- struct isapnp_softc *sc;
+isapnp_unmap_readport(struct isapnp_softc *sc)
{
/* Do nothing */
diff --git a/sys/arch/i386/isa/joy.c b/sys/arch/i386/isa/joy.c
index 317d0e0957c..f3c888bb842 100644
--- a/sys/arch/i386/isa/joy.c
+++ b/sys/arch/i386/isa/joy.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: joy.c,v 1.11 2006/03/15 20:03:04 miod Exp $ */
+/* $OpenBSD: joy.c,v 1.12 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: joy.c,v 1.3 1996/05/05 19:46:15 christos Exp $ */
/*-
@@ -56,10 +56,7 @@ struct cfdriver joy_cd = {
};
int
-joyopen(dev, flag, mode, p)
- dev_t dev;
- int flag, mode;
- struct proc *p;
+joyopen(dev_t dev, int flag, int mode, struct proc *p)
{
int unit = JOYUNIT(dev);
int i = JOYPART(dev);
@@ -81,10 +78,7 @@ joyopen(dev, flag, mode, p)
}
int
-joyclose(dev, flag, mode, p)
- dev_t dev;
- int flag, mode;
- struct proc *p;
+joyclose(dev_t dev, int flag, int mode, struct proc *p)
{
int unit = JOYUNIT(dev);
int i = JOYPART(dev);
@@ -95,10 +89,7 @@ joyclose(dev, flag, mode, p)
}
int
-joyread(dev, uio, flag)
- dev_t dev;
- struct uio *uio;
- int flag;
+joyread(dev_t dev, struct uio *uio, int flag)
{
int unit = JOYUNIT(dev);
struct joy_softc *sc = joy_cd.cd_devs[unit];
@@ -136,12 +127,7 @@ joyread(dev, uio, flag)
}
int
-joyioctl(dev, cmd, data, flag, p)
- dev_t dev;
- u_long cmd;
- caddr_t data;
- int flag;
- struct proc *p;
+joyioctl(dev_t dev, u_long cmd, caddr_t data, int flag, struct proc *p)
{
int unit = JOYUNIT(dev);
struct joy_softc *sc = joy_cd.cd_devs[unit];
@@ -177,7 +163,7 @@ joyioctl(dev, cmd, data, flag, p)
}
static int
-joy_get_tick()
+joy_get_tick(void)
{
int low, high;
diff --git a/sys/arch/i386/isa/joy_isa.c b/sys/arch/i386/isa/joy_isa.c
index 1be38d1f622..a53753a0657 100644
--- a/sys/arch/i386/isa/joy_isa.c
+++ b/sys/arch/i386/isa/joy_isa.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: joy_isa.c,v 1.5 2002/06/02 22:49:59 deraadt Exp $ */
+/* $OpenBSD: joy_isa.c,v 1.6 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: joy.c,v 1.3 1996/05/05 19:46:15 christos Exp $ */
/*-
@@ -57,9 +57,7 @@ struct cfattach joy_isa_ca = {
};
int
-joy_isa_probe(parent, match, aux)
- struct device *parent;
- void *match, *aux;
+joy_isa_probe(struct device *parent, void *match, void *aux)
{
struct isa_attach_args *ia = aux;
#ifdef WANT_JOYSTICK_CONNECTED
@@ -76,9 +74,7 @@ joy_isa_probe(parent, match, aux)
}
void
-joy_isa_attach(parent, self, aux)
- struct device *parent, *self;
- void *aux;
+joy_isa_attach(struct device *parent, struct device *self, void *aux)
{
struct joy_softc *sc = (void *) self;
struct isa_attach_args *ia = aux;
diff --git a/sys/arch/i386/isa/joy_isapnp.c b/sys/arch/i386/isa/joy_isapnp.c
index 8e61ab83616..92264399349 100644
--- a/sys/arch/i386/isa/joy_isapnp.c
+++ b/sys/arch/i386/isa/joy_isapnp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: joy_isapnp.c,v 1.5 2002/06/02 22:49:59 deraadt Exp $ */
+/* $OpenBSD: joy_isapnp.c,v 1.6 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: joy.c,v 1.3 1996/05/05 19:46:15 christos Exp $ */
/*-
@@ -57,17 +57,13 @@ struct cfattach joy_isapnp_ca = {
};
int
-joy_isapnp_probe(parent, match, aux)
- struct device *parent;
- void *match, *aux;
+joy_isapnp_probe(struct device *parent, void *match, void *aux)
{
return (1);
}
void
-joy_isapnp_attach(parent, self, aux)
- struct device *parent, *self;
- void *aux;
+joy_isapnp_attach(struct device *parent, struct device *self, void *aux)
{
struct joy_softc *sc = (void *) self;
struct isa_attach_args *ia = aux;
diff --git a/sys/arch/i386/isa/lms.c b/sys/arch/i386/isa/lms.c
index 7edde899115..4930a51a641 100644
--- a/sys/arch/i386/isa/lms.c
+++ b/sys/arch/i386/isa/lms.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: lms.c,v 1.18 2002/03/14 01:26:33 millert Exp $ */
+/* $OpenBSD: lms.c,v 1.19 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: lms.c,v 1.38 2000/01/08 02:57:25 takemura Exp $ */
/*-
@@ -76,10 +76,7 @@ const struct wsmouse_accessops lms_accessops = {
};
int
-lmsprobe(parent, match, aux)
- struct device *parent;
- void *match;
- void *aux;
+lmsprobe(struct device *parent, void *match, void *aux)
{
struct isa_attach_args *ia = aux;
bus_space_tag_t iot = ia->ia_iot;
@@ -121,9 +118,7 @@ out:
}
void
-lmsattach(parent, self, aux)
- struct device *parent, *self;
- void *aux;
+lmsattach(struct device *parent, struct device *self, void *aux)
{
struct lms_softc *sc = (void *)self;
struct isa_attach_args *ia = aux;
@@ -159,8 +154,7 @@ lmsattach(parent, self, aux)
}
int
-lms_enable(v)
- void *v;
+lms_enable(void *v)
{
struct lms_softc *sc = v;
@@ -177,8 +171,7 @@ lms_enable(v)
}
void
-lms_disable(v)
- void *v;
+lms_disable(void *v)
{
struct lms_softc *sc = v;
@@ -189,12 +182,7 @@ lms_disable(v)
}
int
-lms_ioctl(v, cmd, data, flag, p)
- void *v;
- u_long cmd;
- caddr_t data;
- int flag;
- struct proc *p;
+lms_ioctl(void *v, u_long cmd, caddr_t data, int flag, struct proc *p)
{
#if 0
struct lms_softc *sc = v;
@@ -209,8 +197,7 @@ lms_ioctl(v, cmd, data, flag, p)
}
int
-lmsintr(arg)
- void *arg;
+lmsintr(void *arg)
{
struct lms_softc *sc = arg;
bus_space_tag_t iot = sc->sc_iot;
diff --git a/sys/arch/i386/isa/mms.c b/sys/arch/i386/isa/mms.c
index 137c18384a5..0e517cb0745 100644
--- a/sys/arch/i386/isa/mms.c
+++ b/sys/arch/i386/isa/mms.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mms.c,v 1.17 2004/06/13 21:49:16 niklas Exp $ */
+/* $OpenBSD: mms.c,v 1.18 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: mms.c,v 1.35 2000/01/08 02:57:25 takemura Exp $ */
/*-
@@ -73,10 +73,7 @@ const struct wsmouse_accessops mms_accessops = {
};
int
-mmsprobe(parent, match, aux)
- struct device *parent;
- void *match;
- void *aux;
+mmsprobe(struct device *parent, void *match, void *aux)
{
struct isa_attach_args *ia = aux;
bus_space_tag_t iot = ia->ia_iot;
@@ -110,9 +107,7 @@ out:
}
void
-mmsattach(parent, self, aux)
- struct device *parent, *self;
- void *aux;
+mmsattach(struct device *parent, struct device *self, void *aux)
{
struct mms_softc *sc = (void *)self;
struct isa_attach_args *ia = aux;
@@ -148,8 +143,7 @@ mmsattach(parent, self, aux)
}
int
-mms_enable(v)
- void *v;
+mms_enable(void *v)
{
struct mms_softc *sc = v;
@@ -166,8 +160,7 @@ mms_enable(v)
}
void
-mms_disable(v)
- void *v;
+mms_disable(void *v)
{
struct mms_softc *sc = v;
@@ -178,12 +171,7 @@ mms_disable(v)
}
int
-mms_ioctl(v, cmd, data, flag, p)
- void *v;
- u_long cmd;
- caddr_t data;
- int flag;
- struct proc *p;
+mms_ioctl(void *v, u_long cmd, caddr_t data, int flag, struct proc *p)
{
#if 0
struct mms_softc *sc = v;
@@ -198,8 +186,7 @@ mms_ioctl(v, cmd, data, flag, p)
}
int
-mmsintr(arg)
- void *arg;
+mmsintr(void *arg)
{
struct mms_softc *sc = arg;
bus_space_tag_t iot = sc->sc_iot;
diff --git a/sys/arch/i386/isa/npx.c b/sys/arch/i386/isa/npx.c
index 42ad49dd328..5e0dd5bfb2f 100644
--- a/sys/arch/i386/isa/npx.c
+++ b/sys/arch/i386/isa/npx.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: npx.c,v 1.40 2006/07/25 19:16:51 kettenis Exp $ */
+/* $OpenBSD: npx.c,v 1.41 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: npx.c,v 1.57 1996/05/12 23:12:24 mycroft Exp $ */
#if 0
@@ -193,8 +193,7 @@ asm (".text\n\t"
"iret\n\t");
static inline int
-npxprobe1(ia)
- struct isa_attach_args *ia;
+npxprobe1(struct isa_attach_args *ia)
{
int control;
int status;
@@ -269,9 +268,7 @@ npxprobe1(ia)
* need to use interrupts. Return 1 if device exists.
*/
int
-npxprobe(parent, match, aux)
- struct device *parent;
- void *match, *aux;
+npxprobe(struct device *parent, void *match, void *aux)
{
struct isa_attach_args *ia = aux;
int irq;
@@ -356,9 +353,7 @@ npxinit(struct cpu_info *ci)
* Attach routine - announce which it is, and wire into system
*/
void
-npxattach(parent, self, aux)
- struct device *parent, *self;
- void *aux;
+npxattach(struct device *parent, struct device *self, void *aux)
{
struct npx_softc *sc = (void *)self;
struct isa_attach_args *ia = aux;
@@ -408,8 +403,7 @@ npxattach(parent, self, aux)
* IRQ13 exception handling makes exceptions even less precise than usual.
*/
int
-npxintr(arg)
- void *arg;
+npxintr(void *arg)
{
struct cpu_info *ci = curcpu();
struct proc *p = ci->ci_fpcurproc;
diff --git a/sys/arch/i386/isa/pccom.c b/sys/arch/i386/isa/pccom.c
index 0aa06e3d260..a37b083823b 100644
--- a/sys/arch/i386/isa/pccom.c
+++ b/sys/arch/i386/isa/pccom.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pccom.c,v 1.54 2006/07/31 11:06:20 mickey Exp $ */
+/* $OpenBSD: pccom.c,v 1.55 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: com.c,v 1.82.4.1 1996/06/02 09:08:00 mrg Exp $ */
/*
@@ -189,9 +189,7 @@ void com_kgdb_putc(void *, int);
#endif
int
-comspeed(freq, speed)
- long freq;
- long speed;
+comspeed(long freq, long speed)
{
#define divrnd(n, q) (((n)*2/(q)+1)/2) /* divide and round off */
@@ -215,9 +213,7 @@ comspeed(freq, speed)
}
int
-comprobe1(iot, ioh)
- bus_space_tag_t iot;
- bus_space_handle_t ioh;
+comprobe1(bus_space_tag_t iot, bus_space_handle_t ioh)
{
int i, k;
@@ -238,9 +234,7 @@ comprobe1(iot, ioh)
}
int
-comprobe(parent, match, aux)
- struct device *parent;
- void *match, *aux;
+comprobe(struct device *parent, void *match, void *aux)
{
bus_space_tag_t iot;
bus_space_handle_t ioh;
@@ -313,9 +307,7 @@ out:
}
void
-comattach(parent, self, aux)
- struct device *parent, *self;
- void *aux;
+comattach(struct device *parent, struct device *self, void *aux)
{
struct com_softc *sc = (void *)self;
bus_addr_t iobase;
@@ -423,9 +415,7 @@ comattach(parent, self, aux)
}
int
-com_detach(self, flags)
- struct device *self;
- int flags;
+com_detach(struct device *self, int flags)
{
struct com_softc *sc = (struct com_softc *)self;
int maj, mn;
@@ -455,9 +445,7 @@ com_detach(self, flags)
}
int
-com_activate(self, act)
- struct device *self;
- enum devact act;
+com_activate(struct device *self, enum devact act)
{
struct com_softc *sc = (struct com_softc *)self;
int s, rv = 0;
@@ -489,10 +477,7 @@ com_activate(self, act)
}
int
-comopen(dev, flag, mode, p)
- dev_t dev;
- int flag, mode;
- struct proc *p;
+comopen(dev_t dev, int flag, int mode, struct proc *p)
{
int unit = DEVUNIT(dev);
struct com_softc *sc;
@@ -695,10 +680,7 @@ comopen(dev, flag, mode, p)
}
int
-comclose(dev, flag, mode, p)
- dev_t dev;
- int flag, mode;
- struct proc *p;
+comclose(dev_t dev, int flag, int mode, struct proc *p)
{
int unit = DEVUNIT(dev);
struct com_softc *sc = pccom_cd.cd_devs[unit];
@@ -737,8 +719,7 @@ comclose(dev, flag, mode, p)
}
void
-compwroff(sc)
- struct com_softc *sc;
+compwroff(struct com_softc *sc)
{
bus_space_tag_t iot = sc->sc_iot;
bus_space_handle_t ioh = sc->sc_ioh;
@@ -781,8 +762,7 @@ compwroff(sc)
}
void
-com_raisedtr(arg)
- void *arg;
+com_raisedtr(void *arg)
{
struct com_softc *sc = arg;
@@ -791,10 +771,7 @@ com_raisedtr(arg)
}
int
-comread(dev, uio, flag)
- dev_t dev;
- struct uio *uio;
- int flag;
+comread(dev_t dev, struct uio *uio, int flag)
{
struct com_softc *sc = pccom_cd.cd_devs[DEVUNIT(dev)];
struct tty *tp = sc->sc_tty;
@@ -803,10 +780,7 @@ comread(dev, uio, flag)
}
int
-comwrite(dev, uio, flag)
- dev_t dev;
- struct uio *uio;
- int flag;
+comwrite(dev_t dev, struct uio *uio, int flag)
{
struct com_softc *sc = pccom_cd.cd_devs[DEVUNIT(dev)];
struct tty *tp = sc->sc_tty;
@@ -815,8 +789,7 @@ comwrite(dev, uio, flag)
}
struct tty *
-comtty(dev)
- dev_t dev;
+comtty(dev_t dev)
{
struct com_softc *sc = pccom_cd.cd_devs[DEVUNIT(dev)];
struct tty *tp = sc->sc_tty;
@@ -825,8 +798,7 @@ comtty(dev)
}
static u_char
-tiocm_xxx2mcr(data)
- int data;
+tiocm_xxx2mcr(int data)
{
u_char m = 0;
@@ -838,12 +810,7 @@ tiocm_xxx2mcr(data)
}
int
-comioctl(dev, cmd, data, flag, p)
- dev_t dev;
- u_long cmd;
- caddr_t data;
- int flag;
- struct proc *p;
+comioctl(dev_t dev, u_long cmd, caddr_t data, int flag, struct proc *p)
{
int unit = DEVUNIT(dev);
struct com_softc *sc = pccom_cd.cd_devs[unit];
@@ -954,9 +921,7 @@ comioctl(dev, cmd, data, flag, p)
}
int
-comparam(tp, t)
- struct tty *tp;
- struct termios *t;
+comparam(struct tty *tp, struct termios *t)
{
struct com_softc *sc = pccom_cd.cd_devs[DEVUNIT(tp->t_dev)];
bus_space_tag_t iot = sc->sc_iot;
@@ -1124,9 +1089,7 @@ comparam(tp, t)
* (un)block input via hw flowcontrol
*/
int
-comhwiflow(tp, block)
- struct tty *tp;
- int block;
+comhwiflow(struct tty *tp, int block)
{
struct com_softc *sc = pccom_cd.cd_devs[DEVUNIT(tp->t_dev)];
bus_space_tag_t iot = sc->sc_iot;
@@ -1165,8 +1128,7 @@ comhwiflow(tp, block)
}
void
-comstart(tp)
- struct tty *tp;
+comstart(struct tty *tp)
{
struct com_softc *sc = pccom_cd.cd_devs[DEVUNIT(tp->t_dev)];
bus_space_tag_t iot = sc->sc_iot;
@@ -1222,9 +1184,7 @@ out:
* Stop output on a line.
*/
int
-comstop(tp, flag)
- struct tty *tp;
- int flag;
+comstop(struct tty *tp, int flag)
{
int s;
struct com_softc *sc = pccom_cd.cd_devs[DEVUNIT(tp->t_dev)];
@@ -1240,8 +1200,7 @@ comstop(tp, flag)
}
void
-comdiag(arg)
- void *arg;
+comdiag(void *arg)
{
struct com_softc *sc = arg;
int overflows;
@@ -1262,7 +1221,7 @@ int maxcc = 0;
#endif
void
-comsoft()
+comsoft(void)
{
struct com_softc *sc;
struct tty *tp;
@@ -1372,8 +1331,7 @@ comsoft()
*/
int
-kgdbintr(arg)
- void *arg;
+kgdbintr(void *arg)
{
struct com_softc *sc = arg;
bus_space_tag_t iot = sc->sc_iot;
@@ -1419,8 +1377,7 @@ kgdbintr(arg)
#endif /* KGDB */
int
-comintr(arg)
- void *arg;
+comintr(void *arg)
{
struct com_softc *sc = arg;
struct tty *tp = sc->sc_tty;
@@ -1511,9 +1468,7 @@ comintr(arg)
}
void
-pccom_xr16850_fifo_init(iot, ioh)
- bus_space_tag_t iot;
- bus_space_handle_t ioh;
+pccom_xr16850_fifo_init(bus_space_tag_t iot, bus_space_handle_t ioh)
{
u_int8_t lcr, efr, fctl;
@@ -1531,8 +1486,7 @@ pccom_xr16850_fifo_init(iot, ioh)
*/
void
-comcnprobe(cp)
- struct consdev *cp;
+comcnprobe(struct consdev *cp)
{
/* XXX NEEDS TO BE FIXED XXX */
bus_space_tag_t iot = 0;
@@ -1566,9 +1520,7 @@ comcnprobe(cp)
*/
int
-com_common_getc(iot, ioh)
- bus_space_tag_t iot;
- bus_space_handle_t ioh;
+com_common_getc(bus_space_tag_t iot, bus_space_handle_t ioh)
{
int s = splhigh();
u_char stat, c;
@@ -1585,10 +1537,7 @@ com_common_getc(iot, ioh)
}
void
-com_common_putc(iot, ioh, c)
- bus_space_tag_t iot;
- bus_space_handle_t ioh;
- int c;
+com_common_putc(bus_space_tag_t iot, bus_space_handle_t ioh, int c)
{
int s = splhigh();
int timo;
@@ -1613,8 +1562,7 @@ com_common_putc(iot, ioh, c)
*/
void
-comcninit(cp)
- struct consdev *cp;
+comcninit(struct consdev *cp)
{
#if 0
@@ -1642,10 +1590,7 @@ comcninit(cp)
}
void
-cominit(iot, ioh, rate)
- bus_space_tag_t iot;
- bus_space_handle_t ioh;
- int rate;
+cominit(bus_space_tag_t iot, bus_space_handle_t ioh, int rate)
{
int s = splhigh();
u_int8_t stat;
@@ -1664,8 +1609,7 @@ cominit(iot, ioh, rate)
}
int
-comcngetc(dev)
- dev_t dev;
+comcngetc(dev_t dev)
{
return (com_common_getc(comconsiot, comconsioh));
}
@@ -1674,9 +1618,7 @@ comcngetc(dev)
* Console kernel output character routine.
*/
void
-comcnputc(dev, c)
- dev_t dev;
- int c;
+comcnputc(dev_t dev, int c)
{
#if 0
/* XXX not needed? */
@@ -1692,20 +1634,15 @@ comcnputc(dev, c)
}
void
-comcnpollc(dev, on)
- dev_t dev;
- int on;
+comcnpollc(dev_t dev, int on)
{
}
#ifdef KGDB
int
-com_kgdb_attach(iot, iobase, rate, frequency, cflag)
- bus_space_tag_t iot;
- bus_addr_t iobase;
- int rate, frequency;
- tcflag_t cflag;
+com_kgdb_attach(bus_space_tag_t iot, bus_addr_t iobase, int rate, int frequency,
+ tcflag_t cflag)
{
if (iot == comconsiot && iobase == comconsaddr) {
return (EBUSY); /* cannot share with console */
@@ -1729,8 +1666,7 @@ com_kgdb_attach(iot, iobase, rate, frequency, cflag)
/* ARGSUSED */
int
-com_kgdb_getc(arg)
- void *arg;
+com_kgdb_getc(void *arg)
{
return (com_common_getc(com_kgdb_iot, com_kgdb_ioh));
@@ -1738,9 +1674,7 @@ com_kgdb_getc(arg)
/* ARGSUSED */
void
-com_kgdb_putc(arg, c)
- void *arg;
- int c;
+com_kgdb_putc(void *arg, int c)
{
return (com_common_putc(com_kgdb_iot, com_kgdb_ioh, c));
diff --git a/sys/arch/i386/pci/amd756.c b/sys/arch/i386/pci/amd756.c
index bd86f45dd1d..fb95fac9eff 100644
--- a/sys/arch/i386/pci/amd756.c
+++ b/sys/arch/i386/pci/amd756.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: amd756.c,v 1.3 2002/03/14 01:26:33 millert Exp $ */
+/* $OpenBSD: amd756.c,v 1.4 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD$ */
/*-
@@ -108,12 +108,8 @@ const struct pciintr_icu amd756_pci_icu = {
int
-amd756_init(pc, iot, tag, ptagp, phandp)
- pci_chipset_tag_t pc;
- bus_space_tag_t iot;
- pcitag_t tag;
- pciintr_icu_tag_t *ptagp;
- pciintr_icu_handle_t *phandp;
+amd756_init(pci_chipset_tag_t pc, bus_space_tag_t iot, pcitag_t tag,
+ pciintr_icu_tag_t *ptagp, pciintr_icu_handle_t *phandp)
{
struct viper_handle *ph;
@@ -136,9 +132,7 @@ amd756_init(pc, iot, tag, ptagp, phandp)
}
int
-amd756_getclink(v, link, clinkp)
- pciintr_icu_handle_t v;
- int link, *clinkp;
+amd756_getclink(pciintr_icu_handle_t v, int link, int *clinkp)
{
if (AMD756_LEGAL_LINK(link - 1) == 0)
return (1);
@@ -148,9 +142,7 @@ amd756_getclink(v, link, clinkp)
}
int
-amd756_get_intr(v, clink, irqp)
- pciintr_icu_handle_t v;
- int clink, *irqp;
+amd756_get_intr(pciintr_icu_handle_t v, int clink, int *irqp)
{
struct viper_handle *ph = v;
pcireg_t reg;
@@ -168,9 +160,7 @@ amd756_get_intr(v, clink, irqp)
}
int
-amd756_set_intr(v, clink, irq)
- pciintr_icu_handle_t v;
- int clink, irq;
+amd756_set_intr(pciintr_icu_handle_t v, int clink, int irq)
{
struct viper_handle *ph = v;
int val;
@@ -189,9 +179,7 @@ amd756_set_intr(v, clink, irq)
}
int
-amd756_get_trigger(v, irq, triggerp)
- pciintr_icu_handle_t v;
- int irq, *triggerp;
+amd756_get_trigger(pciintr_icu_handle_t v, int irq, int *triggerp)
{
struct viper_handle *ph = v;
int i, pciirq;
@@ -216,9 +204,7 @@ amd756_get_trigger(v, irq, triggerp)
}
int
-amd756_set_trigger(v, irq, trigger)
- pciintr_icu_handle_t v;
- int irq, trigger;
+amd756_set_trigger(pciintr_icu_handle_t v, int irq, int trigger)
{
struct viper_handle *ph = v;
int i, pciirq;
@@ -245,8 +231,7 @@ amd756_set_trigger(v, irq, trigger)
#ifdef VIPER_DEBUG
static void
-amd756_pir_dump(ph)
- struct viper_handle *ph;
+amd756_pir_dump(struct viper_handle *ph)
{
int a, b;
diff --git a/sys/arch/i386/pci/opti82c558.c b/sys/arch/i386/pci/opti82c558.c
index 6a240fb13c0..03f067293b7 100644
--- a/sys/arch/i386/pci/opti82c558.c
+++ b/sys/arch/i386/pci/opti82c558.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: opti82c558.c,v 1.6 2002/03/14 01:26:33 millert Exp $ */
+/* $OpenBSD: opti82c558.c,v 1.7 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: opti82c558.c,v 1.2 2000/07/18 11:24:09 soda Exp $ */
/*-
@@ -125,12 +125,8 @@ static const int viper_pirq_encode[] = {
};
int
-opti82c558_init(pc, iot, tag, ptagp, phandp)
- pci_chipset_tag_t pc;
- bus_space_tag_t iot;
- pcitag_t tag;
- pciintr_icu_tag_t *ptagp;
- pciintr_icu_handle_t *phandp;
+opti82c558_init(pci_chipset_tag_t pc, bus_space_tag_t iot, pcitag_t tag,
+ pciintr_icu_tag_t *ptagp, pciintr_icu_handle_t *phandp)
{
struct opti82c558_handle *ph;
@@ -147,9 +143,7 @@ opti82c558_init(pc, iot, tag, ptagp, phandp)
}
int
-opti82c558_getclink(v, link, clinkp)
- pciintr_icu_handle_t v;
- int link, *clinkp;
+opti82c558_getclink(pciintr_icu_handle_t v, int link, int *clinkp)
{
if (VIPER_LEGAL_LINK(link - 1)) {
@@ -161,9 +155,7 @@ opti82c558_getclink(v, link, clinkp)
}
int
-opti82c558_get_intr(v, clink, irqp)
- pciintr_icu_handle_t v;
- int clink, *irqp;
+opti82c558_get_intr(pciintr_icu_handle_t v, int clink, int *irqp)
{
struct opti82c558_handle *ph = v;
pcireg_t reg;
@@ -180,9 +172,7 @@ opti82c558_get_intr(v, clink, irqp)
}
int
-opti82c558_set_intr(v, clink, irq)
- pciintr_icu_handle_t v;
- int clink, irq;
+opti82c558_set_intr(pciintr_icu_handle_t v, int clink, int irq)
{
struct opti82c558_handle *ph = v;
int shift;
@@ -201,9 +191,7 @@ opti82c558_set_intr(v, clink, irq)
}
int
-opti82c558_get_trigger(v, irq, triggerp)
- pciintr_icu_handle_t v;
- int irq, *triggerp;
+opti82c558_get_trigger(pciintr_icu_handle_t v, int irq, int *triggerp)
{
struct opti82c558_handle *ph = v;
pcireg_t reg;
@@ -224,9 +212,7 @@ opti82c558_get_trigger(v, irq, triggerp)
}
int
-opti82c558_set_trigger(v, irq, trigger)
- pciintr_icu_handle_t v;
- int irq, trigger;
+opti82c558_set_trigger(pciintr_icu_handle_t v, int irq, int trigger)
{
struct opti82c558_handle *ph = v;
int shift;
diff --git a/sys/arch/i386/pci/opti82c700.c b/sys/arch/i386/pci/opti82c700.c
index 07766921546..c5af374894a 100644
--- a/sys/arch/i386/pci/opti82c700.c
+++ b/sys/arch/i386/pci/opti82c700.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: opti82c700.c,v 1.6 2002/03/14 01:26:33 millert Exp $ */
+/* $OpenBSD: opti82c700.c,v 1.7 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: opti82c700.c,v 1.2 2000/07/18 11:07:20 soda Exp $ */
/*-
@@ -113,12 +113,8 @@ void opti82c700_pir_dump(struct opti82c700_handle *);
#endif
int
-opti82c700_init(pc, iot, tag, ptagp, phandp)
- pci_chipset_tag_t pc;
- bus_space_tag_t iot;
- pcitag_t tag;
- pciintr_icu_tag_t *ptagp;
- pciintr_icu_handle_t *phandp;
+opti82c700_init(pci_chipset_tag_t pc, bus_space_tag_t iot, pcitag_t tag,
+ pciintr_icu_tag_t *ptagp, pciintr_icu_handle_t *phandp)
{
struct opti82c700_handle *ph;
@@ -137,8 +133,7 @@ opti82c700_init(pc, iot, tag, ptagp, phandp)
}
int
-opti82c700_addr(link, addrofs, ofs)
- int link, *addrofs, *ofs;
+opti82c700_addr(int link, int *addrofs, int *ofs)
{
int regofs, src;
@@ -173,9 +168,7 @@ opti82c700_addr(link, addrofs, ofs)
}
int
-opti82c700_getclink(v, link, clinkp)
- pciintr_icu_handle_t v;
- int link, *clinkp;
+opti82c700_getclink(pciintr_icu_handle_t v, int link, int *clinkp)
{
DPRINTF(("FireStar link value 0x%x: ", link));
@@ -204,9 +197,7 @@ opti82c700_getclink(v, link, clinkp)
}
int
-opti82c700_get_intr(v, clink, irqp)
- pciintr_icu_handle_t v;
- int clink, *irqp;
+opti82c700_get_intr(pciintr_icu_handle_t v, int clink, int *irqp)
{
struct opti82c700_handle *ph = v;
pcireg_t reg;
@@ -225,9 +216,7 @@ opti82c700_get_intr(v, clink, irqp)
}
int
-opti82c700_set_intr(v, clink, irq)
- pciintr_icu_handle_t v;
- int clink, irq;
+opti82c700_set_intr(pciintr_icu_handle_t v, int clink, int irq)
{
struct opti82c700_handle *ph = v;
int addrofs, ofs;
@@ -248,9 +237,7 @@ opti82c700_set_intr(v, clink, irq)
}
int
-opti82c700_get_trigger(v, irq, triggerp)
- pciintr_icu_handle_t v;
- int irq, *triggerp;
+opti82c700_get_trigger(pciintr_icu_handle_t v, int irq, int *triggerp)
{
struct opti82c700_handle *ph = v;
int i, val, addrofs, ofs;
@@ -296,9 +283,7 @@ opti82c700_get_trigger(v, irq, triggerp)
}
int
-opti82c700_set_trigger(v, irq, trigger)
- pciintr_icu_handle_t v;
- int irq, trigger;
+opti82c700_set_trigger(pciintr_icu_handle_t v, int irq, int trigger)
{
struct opti82c700_handle *ph = v;
int i, val, addrofs, ofs;
diff --git a/sys/arch/i386/pci/pchb.c b/sys/arch/i386/pci/pchb.c
index 7a664b416c5..466d9cf0a78 100644
--- a/sys/arch/i386/pci/pchb.c
+++ b/sys/arch/i386/pci/pchb.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pchb.c,v 1.52 2006/03/13 20:10:49 brad Exp $ */
+/* $OpenBSD: pchb.c,v 1.53 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: pchb.c,v 1.6 1997/06/06 23:29:16 thorpej Exp $ */
/*
@@ -150,9 +150,7 @@ const struct pci_matchid via_devices[] = {
};
int
-pchbmatch(parent, match, aux)
- struct device *parent;
- void *match, *aux;
+pchbmatch(struct device *parent, void *match, void *aux)
{
struct pci_attach_args *pa = aux;
@@ -177,9 +175,7 @@ pchbmatch(parent, match, aux)
u_int32_t rcc_bus_visited = 1;
void
-pchbattach(parent, self, aux)
- struct device *parent, *self;
- void *aux;
+pchbattach(struct device *parent, struct device *self, void *aux)
{
struct pchb_softc *sc = (struct pchb_softc *)self;
struct pci_attach_args *pa = aux;
@@ -410,9 +406,7 @@ pchbattach(parent, self, aux)
}
int
-pchb_print(aux, pnp)
- void *aux;
- const char *pnp;
+pchb_print(void *aux, const char *pnp)
{
struct pcibus_attach_args *pba = aux;
@@ -427,8 +421,7 @@ pchb_print(aux, pnp)
* http://csrc.nist.gov/publications/fips/fips140-1/fips1401.pdf
*/
void
-pchb_rnd(v)
- void *v;
+pchb_rnd(void *v)
{
struct pchb_softc *sc = v;
diff --git a/sys/arch/i386/pci/pci_addr_fixup.c b/sys/arch/i386/pci/pci_addr_fixup.c
index bb99bf6f769..6f12fe5618a 100644
--- a/sys/arch/i386/pci/pci_addr_fixup.c
+++ b/sys/arch/i386/pci/pci_addr_fixup.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pci_addr_fixup.c,v 1.19 2006/08/14 22:48:28 deraadt Exp $ */
+/* $OpenBSD: pci_addr_fixup.c,v 1.20 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: pci_addr_fixup.c,v 1.7 2000/08/03 20:10:45 nathanw Exp $ */
/*-
@@ -76,10 +76,7 @@ int pciaddr_device_is_agp(pci_chipset_tag_t, pcitag_t);
#define PCIADDR_ISAMEM_RESERVE (16 * 1024 * 1024)
void
-pci_addr_fixup(sc, pc, maxbus)
- struct pcibios_softc *sc;
- pci_chipset_tag_t pc;
- int maxbus;
+pci_addr_fixup(struct pcibios_softc *sc, pci_chipset_tag_t pc, int maxbus)
{
extern paddr_t avail_end;
const char *verbose_header =
@@ -151,10 +148,8 @@ pci_addr_fixup(sc, pc, maxbus)
}
void
-pciaddr_resource_reserve(sc, pc, tag)
- struct pcibios_softc *sc;
- pci_chipset_tag_t pc;
- pcitag_t tag;
+pciaddr_resource_reserve(struct pcibios_softc *sc, pci_chipset_tag_t pc,
+ pcitag_t tag)
{
if (pcibios_flags & PCIBIOS_VERBOSE)
pciaddr_print_devid(pc, tag);
@@ -162,10 +157,8 @@ pciaddr_resource_reserve(sc, pc, tag)
}
void
-pciaddr_resource_reserve_disabled(sc, pc, tag)
- struct pcibios_softc *sc;
- pci_chipset_tag_t pc;
- pcitag_t tag;
+pciaddr_resource_reserve_disabled(struct pcibios_softc *sc,
+ pci_chipset_tag_t pc, pcitag_t tag)
{
if (pcibios_flags & PCIBIOS_VERBOSE)
pciaddr_print_devid(pc, tag);
@@ -174,10 +167,8 @@ pciaddr_resource_reserve_disabled(sc, pc, tag)
}
void
-pciaddr_resource_allocate(sc, pc, tag)
- struct pcibios_softc *sc;
- pci_chipset_tag_t pc;
- pcitag_t tag;
+pciaddr_resource_allocate(struct pcibios_softc *sc, pci_chipset_tag_t pc,
+ pcitag_t tag)
{
if (pcibios_flags & PCIBIOS_VERBOSE)
pciaddr_print_devid(pc, tag);
@@ -185,11 +176,8 @@ pciaddr_resource_allocate(sc, pc, tag)
}
void
-pciaddr_resource_manage(sc, pc, tag, func)
- struct pcibios_softc *sc;
- pci_chipset_tag_t pc;
- pcitag_t tag;
- pciaddr_resource_manage_func_t func;
+pciaddr_resource_manage(struct pcibios_softc *sc, pci_chipset_tag_t pc,
+ pcitag_t tag, pciaddr_resource_manage_func_t func)
{
struct extent *ex;
pcireg_t val, mask;
@@ -271,14 +259,9 @@ pciaddr_resource_manage(sc, pc, tag, func)
}
int
-pciaddr_do_resource_allocate(sc, pc, tag, mapreg, ex, type, addr, size)
- struct pcibios_softc *sc;
- pci_chipset_tag_t pc;
- pcitag_t tag;
- struct extent *ex;
- int mapreg, type;
- u_long *addr;
- bus_size_t size;
+pciaddr_do_resource_allocate(struct pcibios_softc *sc, pci_chipset_tag_t pc,
+ pcitag_t tag, int mapreg, struct extent *ex, int type, u_long *addr,
+ bus_size_t size)
{
bus_addr_t start;
int error;
@@ -322,14 +305,9 @@ pciaddr_do_resource_allocate(sc, pc, tag, mapreg, ex, type, addr, size)
}
int
-pciaddr_do_resource_reserve(sc, pc, tag, mapreg, ex, type, addr, size)
- struct pcibios_softc *sc;
- pci_chipset_tag_t pc;
- pcitag_t tag;
- struct extent *ex;
- int type, mapreg;
- u_long *addr;
- bus_size_t size;
+pciaddr_do_resource_reserve(struct pcibios_softc *sc, pci_chipset_tag_t pc,
+ pcitag_t tag, int mapreg, struct extent *ex, int type, u_long *addr,
+ bus_size_t size)
{
pcireg_t val;
int error;
@@ -356,14 +334,9 @@ pciaddr_do_resource_reserve(sc, pc, tag, mapreg, ex, type, addr, size)
}
int
-pciaddr_do_resource_reserve_disabled(sc, pc, tag, mapreg, ex, type, addr, size)
- struct pcibios_softc *sc;
- pci_chipset_tag_t pc;
- pcitag_t tag;
- struct extent *ex;
- int type, mapreg;
- u_long *addr;
- bus_size_t size;
+pciaddr_do_resource_reserve_disabled(struct pcibios_softc *sc,
+ pci_chipset_tag_t pc, pcitag_t tag, int mapreg, struct extent *ex, int type,
+ u_long *addr, bus_size_t size)
{
pcireg_t val;
int error;
@@ -393,8 +366,7 @@ pciaddr_do_resource_reserve_disabled(sc, pc, tag, mapreg, ex, type, addr, size)
}
bus_addr_t
-pciaddr_ioaddr(val)
- u_int32_t val;
+pciaddr_ioaddr(u_int32_t val)
{
return ((PCI_MAPREG_TYPE(val) == PCI_MAPREG_TYPE_MEM)
? PCI_MAPREG_MEM_ADDR(val)
@@ -402,9 +374,7 @@ pciaddr_ioaddr(val)
}
void
-pciaddr_print_devid(pc, tag)
- pci_chipset_tag_t pc;
- pcitag_t tag;
+pciaddr_print_devid(pci_chipset_tag_t pc, pcitag_t tag)
{
int bus, device, function;
pcireg_t id;
@@ -416,9 +386,7 @@ pciaddr_print_devid(pc, tag)
}
int
-pciaddr_device_is_agp(pc, tag)
- pci_chipset_tag_t pc;
- pcitag_t tag;
+pciaddr_device_is_agp(pci_chipset_tag_t pc, pcitag_t tag)
{
pcireg_t class, status, rval;
int off;
@@ -443,10 +411,7 @@ pciaddr_device_is_agp(pc, tag)
struct extent *
-pciaddr_search(mem_port, startp, size)
- int mem_port;
- bus_addr_t *startp;
- bus_size_t size;
+pciaddr_search(int mem_port, bus_addr_t *startp, bus_size_t size)
{
extern struct cfdriver pcibios_cd;
struct pcibios_softc *sc;
diff --git a/sys/arch/i386/pci/pci_intr_fixup.c b/sys/arch/i386/pci/pci_intr_fixup.c
index a91d27dbfc8..03827b2e851 100644
--- a/sys/arch/i386/pci/pci_intr_fixup.c
+++ b/sys/arch/i386/pci/pci_intr_fixup.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pci_intr_fixup.c,v 1.55 2006/08/06 01:13:22 brad Exp $ */
+/* $OpenBSD: pci_intr_fixup.c,v 1.56 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: pci_intr_fixup.c,v 1.10 2000/08/10 21:18:27 soda Exp $ */
/*
@@ -251,8 +251,7 @@ pciintr_icu_lookup(id)
}
struct pciintr_link_map *
-pciintr_link_lookup(link)
- int link;
+pciintr_link_lookup(int link)
{
struct pciintr_link_map *l;
@@ -330,8 +329,7 @@ pciintr_link_alloc(pci_chipset_tag_t pc, struct pcibios_intr_routing *pir, int p
}
struct pcibios_intr_routing *
-pciintr_pir_lookup(bus, device)
- int bus, device;
+pciintr_pir_lookup(int bus, int device)
{
struct pcibios_intr_routing *pir;
int entry;
@@ -350,8 +348,7 @@ pciintr_pir_lookup(bus, device)
}
int
-pciintr_bitmap_count_irq(irq_bitmap, irqp)
- int irq_bitmap, *irqp;
+pciintr_bitmap_count_irq(int irq_bitmap, int *irqp)
{
int i, bit, count = 0, irq = I386_PCI_INTERRUPT_LINE_NO_CONNECTION;
@@ -542,9 +539,7 @@ pciintr_link_fixup(void)
}
int
-pci_intr_route_link(pc, ihp)
- pci_chipset_tag_t pc;
- pci_intr_handle_t *ihp;
+pci_intr_route_link(pci_chipset_tag_t pc, pci_intr_handle_t *ihp)
{
struct pciintr_link_map *l;
pcireg_t intr;
@@ -611,7 +606,7 @@ pci_intr_route_link(pc, ihp)
}
int
-pci_intr_post_fixup()
+pci_intr_post_fixup(void)
{
struct pciintr_link_map *l;
int i, pciirq;
@@ -651,10 +646,8 @@ pci_intr_post_fixup()
}
int
-pci_intr_header_fixup(pc, tag, ihp)
- pci_chipset_tag_t pc;
- pcitag_t tag;
- pci_intr_handle_t *ihp;
+pci_intr_header_fixup(pci_chipset_tag_t pc, pcitag_t tag,
+ pci_intr_handle_t *ihp)
{
struct pcibios_intr_routing *pir;
struct pciintr_link_map *l;
@@ -722,7 +715,7 @@ pci_intr_header_fixup(pc, tag, ihp)
}
if (pcibios_flags & PCIBIOS_INTRDEBUG) {
- register pcireg_t id = pci_conf_read(pc, tag, PCI_ID_REG);
+ pcireg_t id = pci_conf_read(pc, tag, PCI_ID_REG);
printf("\n%d:%d:%d %04x:%04x pin %c clink 0x%02x irq %d "
"stage %d %s irq %d\n", bus, device, function,
@@ -735,10 +728,8 @@ pci_intr_header_fixup(pc, tag, ihp)
}
int
-pci_intr_fixup(sc, pc, iot)
- struct pcibios_softc *sc;
- pci_chipset_tag_t pc;
- bus_space_tag_t iot;
+pci_intr_fixup(struct pcibios_softc *sc, pci_chipset_tag_t pc,
+ bus_space_tag_t iot)
{
struct pcibios_pir_header *pirh = &pcibios_pir_header;
const struct pciintr_icu_table *piit = NULL;
diff --git a/sys/arch/i386/pci/pci_machdep.c b/sys/arch/i386/pci/pci_machdep.c
index b7690fb9d66..07d8c5722c7 100644
--- a/sys/arch/i386/pci/pci_machdep.c
+++ b/sys/arch/i386/pci/pci_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pci_machdep.c,v 1.33 2006/06/25 07:44:54 brad Exp $ */
+/* $OpenBSD: pci_machdep.c,v 1.34 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: pci_machdep.c,v 1.28 1997/06/06 23:29:17 thorpej Exp $ */
/*-
@@ -167,9 +167,8 @@ struct i386_bus_dma_tag pci_bus_dma_tag = {
};
void
-pci_attach_hook(parent, self, pba)
- struct device *parent, *self;
- struct pcibus_attach_args *pba;
+pci_attach_hook(struct device *parent, struct device *self,
+ struct pcibus_attach_args *pba)
{
#if NBIOS > 0
@@ -183,9 +182,7 @@ pci_attach_hook(parent, self, pba)
}
int
-pci_bus_maxdevs(pc, busno)
- pci_chipset_tag_t pc;
- int busno;
+pci_bus_maxdevs(pci_chipset_tag_t pc, int busno)
{
/*
@@ -201,9 +198,7 @@ pci_bus_maxdevs(pc, busno)
}
pcitag_t
-pci_make_tag(pc, bus, device, function)
- pci_chipset_tag_t pc;
- int bus, device, function;
+pci_make_tag(pci_chipset_tag_t pc, int bus, int device, int function)
{
pcitag_t tag;
@@ -231,10 +226,7 @@ pci_make_tag(pc, bus, device, function)
}
void
-pci_decompose_tag(pc, tag, bp, dp, fp)
- pci_chipset_tag_t pc;
- pcitag_t tag;
- int *bp, *dp, *fp;
+pci_decompose_tag(pci_chipset_tag_t pc, pcitag_t tag, int *bp, int *dp, int *fp)
{
switch (pci_mode) {
@@ -260,10 +252,7 @@ pci_decompose_tag(pc, tag, bp, dp, fp)
}
pcireg_t
-pci_conf_read(pc, tag, reg)
- pci_chipset_tag_t pc;
- pcitag_t tag;
- int reg;
+pci_conf_read(pci_chipset_tag_t pc, pcitag_t tag, int reg)
{
pcireg_t data;
@@ -287,11 +276,7 @@ pci_conf_read(pc, tag, reg)
}
void
-pci_conf_write(pc, tag, reg, data)
- pci_chipset_tag_t pc;
- pcitag_t tag;
- int reg;
- pcireg_t data;
+pci_conf_write(pci_chipset_tag_t pc, pcitag_t tag, int reg, pcireg_t data)
{
switch (pci_mode) {
@@ -312,7 +297,7 @@ pci_conf_write(pc, tag, reg, data)
}
int
-pci_mode_detect()
+pci_mode_detect(void)
{
#ifdef PCI_CONF_MODE
@@ -420,9 +405,7 @@ not2:
}
int
-pci_intr_map(pa, ihp)
- struct pci_attach_args *pa;
- pci_intr_handle_t *ihp;
+pci_intr_map(struct pci_attach_args *pa, pci_intr_handle_t *ihp)
{
#if NIOAPIC > 0
struct mp_intr_map *mip;
@@ -532,9 +515,7 @@ bad:
}
const char *
-pci_intr_string(pc, ih)
- pci_chipset_tag_t pc;
- pci_intr_handle_t ih;
+pci_intr_string(pci_chipset_tag_t pc, pci_intr_handle_t ih)
{
static char irqstr[64];
int line = ih.line & APIC_INT_LINE_MASK;
@@ -555,12 +536,8 @@ pci_intr_string(pc, ih)
}
void *
-pci_intr_establish(pc, ih, level, func, arg, what)
- pci_chipset_tag_t pc;
- pci_intr_handle_t ih;
- int level, (*func)(void *);
- void *arg;
- char *what;
+pci_intr_establish(pci_chipset_tag_t pc, pci_intr_handle_t ih, int level,
+ int (*func)(void *), void *arg, char *what)
{
void *ret;
int l = ih.line & APIC_INT_LINE_MASK;
@@ -582,9 +559,7 @@ pci_intr_establish(pc, ih, level, func, arg, what)
}
void
-pci_intr_disestablish(pc, cookie)
- pci_chipset_tag_t pc;
- void *cookie;
+pci_intr_disestablish(pci_chipset_tag_t pc, void *cookie)
{
/* XXX oh, unroute the pci int link? */
isa_intr_disestablish(NULL, cookie);
diff --git a/sys/arch/i386/pci/pcib.c b/sys/arch/i386/pci/pcib.c
index 92c1c49be9a..f0cc7bc2968 100644
--- a/sys/arch/i386/pci/pcib.c
+++ b/sys/arch/i386/pci/pcib.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pcib.c,v 1.19 2005/01/07 02:24:18 brad Exp $ */
+/* $OpenBSD: pcib.c,v 1.20 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: pcib.c,v 1.6 1997/06/06 23:29:16 thorpej Exp $ */
/*-
@@ -69,9 +69,7 @@ struct cfdriver pcib_cd = {
};
int
-pcibmatch(parent, match, aux)
- struct device *parent;
- void *match, *aux;
+pcibmatch(struct device *parent, void *match, void *aux)
{
struct pci_attach_args *pa = aux;
@@ -107,9 +105,7 @@ pcibmatch(parent, match, aux)
}
void
-pcibattach(parent, self, aux)
- struct device *parent, *self;
- void *aux;
+pcibattach(struct device *parent, struct device *self, void *aux)
{
/*
* Cannot attach isa bus now; must postpone for various reasons
@@ -120,8 +116,7 @@ pcibattach(parent, self, aux)
}
void
-pcib_callback(self)
- struct device *self;
+pcib_callback(struct device *self)
{
struct isabus_attach_args iba;
@@ -143,9 +138,7 @@ pcib_callback(self)
}
int
-pcib_print(aux, pnp)
- void *aux;
- const char *pnp;
+pcib_print(void *aux, const char *pnp)
{
/* Only ISAs can attach to pcib's; easy. */
if (pnp)
diff --git a/sys/arch/i386/pci/pcibios.c b/sys/arch/i386/pci/pcibios.c
index ea83f89717e..438d3338d45 100644
--- a/sys/arch/i386/pci/pcibios.c
+++ b/sys/arch/i386/pci/pcibios.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pcibios.c,v 1.33 2006/04/27 15:37:55 mickey Exp $ */
+/* $OpenBSD: pcibios.c,v 1.34 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: pcibios.c,v 1.5 2000/08/01 05:23:59 uch Exp $ */
/*
@@ -145,9 +145,7 @@ struct cfattach pcibios_ca = {
};
int
-pcibiosprobe(parent, match, aux)
- struct device *parent;
- void *match, *aux;
+pcibiosprobe(struct device *parent, void *match, void *aux)
{
struct bios_attach_args *ba = aux;
u_int32_t rev_maj, rev_min, mech1, mech2, scmech1, scmech2, maxbus;
@@ -169,9 +167,7 @@ pcibiosprobe(parent, match, aux)
}
void
-pcibiosattach(parent, self, aux)
- struct device *parent, *self;
- void *aux;
+pcibiosattach(struct device *parent, struct device *self, void *aux)
{
struct pcibios_softc *sc = (struct pcibios_softc *)self;
u_int32_t rev_maj, rev_min, mech1, mech2, scmech1, scmech2;
@@ -241,8 +237,7 @@ pcibiosattach(parent, self, aux)
}
struct pcibios_intr_routing *
-pcibios_pir_init(sc)
- struct pcibios_softc *sc;
+pcibios_pir_init(struct pcibios_softc *sc)
{
paddr_t pa;
@@ -346,10 +341,9 @@ pcibios_pir_init(sc)
}
int
-pcibios_get_status(sc, rev_maj, rev_min, mech1, mech2, scmech1, scmech2, maxbus)
- struct pcibios_softc *sc;
- u_int32_t *rev_maj, *rev_min, *mech1, *mech2, *scmech1, *scmech2,
- *maxbus;
+pcibios_get_status(struct pcibios_softc *sc, u_int32_t *rev_maj,
+ u_int32_t *rev_min, u_int32_t *mech1, u_int32_t *mech2, u_int32_t *scmech1,
+ u_int32_t *scmech2, u_int32_t *maxbus)
{
u_int32_t ax, bx, cx, edx;
int rv;
@@ -390,11 +384,8 @@ pcibios_get_status(sc, rev_maj, rev_min, mech1, mech2, scmech1, scmech2, maxbus)
}
int
-pcibios_get_intr_routing(sc, table, nentries, exclirq)
- struct pcibios_softc *sc;
- struct pcibios_intr_routing *table;
- int *nentries;
- u_int16_t *exclirq;
+pcibios_get_intr_routing(struct pcibios_softc *sc,
+ struct pcibios_intr_routing *table, int *nentries, u_int16_t *exclirq)
{
u_int32_t ax, bx;
int rv;
@@ -435,10 +426,7 @@ pcibios_get_intr_routing(sc, table, nentries, exclirq)
}
int
-pcibios_return_code(sc, ax, func)
- struct pcibios_softc *sc;
- u_int16_t ax;
- const char *func;
+pcibios_return_code(struct pcibios_softc *sc, u_int16_t ax, const char *func)
{
const char *errstr;
int rv = ax >> 8;
@@ -492,8 +480,7 @@ pcibios_return_code(sc, ax, func)
}
void
-pcibios_print_exclirq(sc)
- struct pcibios_softc *sc;
+pcibios_print_exclirq(struct pcibios_softc *sc)
{
int i;
@@ -508,7 +495,7 @@ pcibios_print_exclirq(sc)
}
void
-pcibios_print_pir_table()
+pcibios_print_pir_table(void)
{
int i, j;
@@ -527,11 +514,8 @@ pcibios_print_pir_table()
}
void
-pci_device_foreach(sc, pc, maxbus, func)
- struct pcibios_softc *sc;
- pci_chipset_tag_t pc;
- int maxbus;
- void (*func)(struct pcibios_softc *, pci_chipset_tag_t, pcitag_t);
+pci_device_foreach(struct pcibios_softc *sc, pci_chipset_tag_t pc, int maxbus,
+ void (*func)(struct pcibios_softc *, pci_chipset_tag_t, pcitag_t))
{
const struct pci_quirkdata *qd;
int bus, device, function, maxdevs, nfuncs;
diff --git a/sys/arch/i386/pci/pcic_pci_machdep.c b/sys/arch/i386/pci/pcic_pci_machdep.c
index 1861a31bfc6..e46e8c39313 100644
--- a/sys/arch/i386/pci/pcic_pci_machdep.c
+++ b/sys/arch/i386/pci/pcic_pci_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pcic_pci_machdep.c,v 1.3 2002/03/14 01:26:33 millert Exp $ */
+/* $OpenBSD: pcic_pci_machdep.c,v 1.4 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: pcic_pci_machdep.c,v 1.1 1998/12/20 17:53:29 nathanw Exp $ */
/*
@@ -49,16 +49,13 @@
#include <dev/pci/i82365_pcivar.h>
void *
-pcic_pci_machdep_intr_est(pc)
- pci_chipset_tag_t pc;
+pcic_pci_machdep_intr_est(pci_chipset_tag_t pc)
{
return NULL;
}
void *
-pcic_pci_machdep_pcic_intr_establish(sc, fct)
- struct pcic_softc *sc;
- int (*fct)(void *);
+pcic_pci_machdep_pcic_intr_establish(struct pcic_softc *sc, int (*fct)(void *))
{
if (isa_intr_alloc(NULL, PCIC_CSC_INTR_IRQ_VALIDMASK & 0xffff,
IST_EDGE, &(sc->irq)))
@@ -69,21 +66,15 @@ pcic_pci_machdep_pcic_intr_establish(sc, fct)
}
void *
-pcic_pci_machdep_chip_intr_establish(pch, pf, ipl, fct, arg, xname)
- pcmcia_chipset_handle_t pch;
- struct pcmcia_function *pf;
- int ipl;
- int (*fct)(void *);
- void *arg;
- char *xname;
+pcic_pci_machdep_chip_intr_establish(pcmcia_chipset_handle_t pch,
+ struct pcmcia_function *pf, int ipl, int (*fct)(void *), void *arg,
+ char *xname)
{
return (pcic_isa_chip_intr_establish(pch, pf, ipl, fct, arg, xname));
}
void
-pcic_pci_machdep_chip_intr_disestablish(pch, ih)
- pcmcia_chipset_handle_t pch;
- void *ih;
+pcic_pci_machdep_chip_intr_disestablish(pcmcia_chipset_handle_t pch, void *ih)
{
pcic_isa_chip_intr_disestablish(pch, ih);
}
diff --git a/sys/arch/i386/pci/pciide_machdep.c b/sys/arch/i386/pci/pciide_machdep.c
index 072d7b6ba1f..6efa9eae90b 100644
--- a/sys/arch/i386/pci/pciide_machdep.c
+++ b/sys/arch/i386/pci/pciide_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pciide_machdep.c,v 1.5 2002/03/14 01:26:33 millert Exp $ */
+/* $OpenBSD: pciide_machdep.c,v 1.6 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: pciide_machdep.c,v 1.2 1999/02/19 18:01:27 mycroft Exp $ */
/*
@@ -53,12 +53,8 @@
#include <dev/isa/isavar.h>
void *
-pciide_machdep_compat_intr_establish(dev, pa, chan, func, arg)
- struct device *dev;
- struct pci_attach_args *pa;
- int chan;
- int (*func)(void *);
- void *arg;
+pciide_machdep_compat_intr_establish(struct device *dev,
+ struct pci_attach_args *pa, int chan, int (*func)(void *), void *arg)
{
int irq;
void *cookie;
diff --git a/sys/arch/i386/pci/piix.c b/sys/arch/i386/pci/piix.c
index 7e06b6499b0..e5dfe2dfa28 100644
--- a/sys/arch/i386/pci/piix.c
+++ b/sys/arch/i386/pci/piix.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: piix.c,v 1.7 2003/03/28 23:12:33 mickey Exp $ */
+/* $OpenBSD: piix.c,v 1.8 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: piix.c,v 1.1 1999/11/17 01:21:20 thorpej Exp $ */
/*-
@@ -105,12 +105,8 @@ const struct pciintr_icu piix_pci_icu = {
};
int
-piix_init(pc, iot, tag, ptagp, phandp)
- pci_chipset_tag_t pc;
- bus_space_tag_t iot;
- pcitag_t tag;
- pciintr_icu_tag_t *ptagp;
- pciintr_icu_handle_t *phandp;
+piix_init(pci_chipset_tag_t pc, bus_space_tag_t iot, pcitag_t tag,
+ pciintr_icu_tag_t *ptagp, pciintr_icu_handle_t *phandp)
{
struct piix_handle *ph;
@@ -137,9 +133,7 @@ piix_init(pc, iot, tag, ptagp, phandp)
}
int
-piix_getclink(v, link, clinkp)
- pciintr_icu_handle_t v;
- int link, *clinkp;
+piix_getclink(pciintr_icu_handle_t v, int link, int *clinkp)
{
DPRINTF(("PIIX link value 0x%x: ", link));
@@ -169,9 +163,7 @@ piix_getclink(v, link, clinkp)
}
int
-piix_get_intr(v, clink, irqp)
- pciintr_icu_handle_t v;
- int clink, *irqp;
+piix_get_intr(pciintr_icu_handle_t v, int clink, int *irqp)
{
struct piix_handle *ph = v;
int shift, off;
@@ -197,9 +189,7 @@ piix_get_intr(v, clink, irqp)
}
int
-piix_set_intr(v, clink, irq)
- pciintr_icu_handle_t v;
- int clink, irq;
+piix_set_intr(pciintr_icu_handle_t v, int clink, int irq)
{
struct piix_handle *ph = v;
int shift, off;
@@ -224,9 +214,7 @@ piix_set_intr(v, clink, irq)
}
int
-piix_get_trigger(v, irq, triggerp)
- pciintr_icu_handle_t v;
- int irq, *triggerp;
+piix_get_trigger(pciintr_icu_handle_t v, int irq, int *triggerp)
{
struct piix_handle *ph = v;
int off, bit;
@@ -248,9 +236,7 @@ piix_get_trigger(v, irq, triggerp)
}
int
-piix_set_trigger(v, irq, trigger)
- pciintr_icu_handle_t v;
- int irq, trigger;
+piix_set_trigger(pciintr_icu_handle_t v, int irq, int trigger)
{
struct piix_handle *ph = v;
int off, bit;
@@ -274,8 +260,7 @@ piix_set_trigger(v, irq, trigger)
#ifdef PIIX_DEBUG
void
-piix_pir_dump(ph)
- struct piix_handle *ph;
+piix_pir_dump(struct piix_handle *ph)
{
int i, irq;
pcireg_t irqs = pci_conf_read(ph->ph_pc, ph->ph_tag, PIIX_CFG_PIRQ);
diff --git a/sys/arch/i386/pci/sis85c503.c b/sys/arch/i386/pci/sis85c503.c
index 8e70cb53bb2..d1d46846f8b 100644
--- a/sys/arch/i386/pci/sis85c503.c
+++ b/sys/arch/i386/pci/sis85c503.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sis85c503.c,v 1.6 2002/03/14 01:26:33 millert Exp $ */
+/* $OpenBSD: sis85c503.c,v 1.7 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: sis85c503.c,v 1.2 2000/07/18 11:24:09 soda Exp $ */
/*-
@@ -95,12 +95,8 @@ const struct pciintr_icu sis85c503_pci_icu = {
};
int
-sis85c503_init(pc, iot, tag, ptagp, phandp)
- pci_chipset_tag_t pc;
- bus_space_tag_t iot;
- pcitag_t tag;
- pciintr_icu_tag_t *ptagp;
- pciintr_icu_handle_t *phandp;
+sis85c503_init(pci_chipset_tag_t pc, bus_space_tag_t iot, pcitag_t tag,
+ pciintr_icu_tag_t *ptagp, pciintr_icu_handle_t *phandp)
{
if (piix_init(pc, iot, tag, ptagp, phandp) == 0) {
@@ -112,9 +108,7 @@ sis85c503_init(pc, iot, tag, ptagp, phandp)
}
int
-sis85c503_getclink(v, link, clinkp)
- pciintr_icu_handle_t v;
- int link, *clinkp;
+sis85c503_getclink(pciintr_icu_handle_t v, int link, int *clinkp)
{
/* Pattern 1: simple. */
@@ -134,9 +128,7 @@ sis85c503_getclink(v, link, clinkp)
}
int
-sis85c503_get_intr(v, clink, irqp)
- pciintr_icu_handle_t v;
- int clink, *irqp;
+sis85c503_get_intr(pciintr_icu_handle_t v, int clink, int *irqp)
{
struct piix_handle *ph = v;
pcireg_t reg;
@@ -157,9 +149,7 @@ sis85c503_get_intr(v, clink, irqp)
}
int
-sis85c503_set_intr(v, clink, irq)
- pciintr_icu_handle_t v;
- int clink, irq;
+sis85c503_set_intr(pciintr_icu_handle_t v, int clink, int irq)
{
struct piix_handle *ph = v;
int shift;
diff --git a/sys/arch/i386/pci/via8231.c b/sys/arch/i386/pci/via8231.c
index aa3e529d384..73dd9070944 100644
--- a/sys/arch/i386/pci/via8231.c
+++ b/sys/arch/i386/pci/via8231.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: via8231.c,v 1.6 2005/10/27 16:41:06 mickey Exp $ */
+/* $OpenBSD: via8231.c,v 1.7 2006/09/19 11:06:34 jsg Exp $ */
/*-
* Copyright (c) 1999 The NetBSD Foundation, Inc.
@@ -140,12 +140,8 @@ static const struct mask_shft_pair via8231_routing_cnfg[VIA8231_LINK_MAX+1] = {
via8231_routing_cnfg[(pirq)].shft))
int
-via8231_init(pc, iot, tag, ptagp, phandp)
- pci_chipset_tag_t pc;
- bus_space_tag_t iot;
- pcitag_t tag;
- pciintr_icu_tag_t *ptagp;
- pciintr_icu_handle_t *phandp;
+via8231_init(pci_chipset_tag_t pc, bus_space_tag_t iot, pcitag_t tag,
+ pciintr_icu_tag_t *ptagp, pciintr_icu_handle_t *phandp)
{
struct via8231_handle *ph;
pcireg_t id;
@@ -172,9 +168,7 @@ via8231_init(pc, iot, tag, ptagp, phandp)
}
int
-via8231_getclink(v, link, clinkp)
- pciintr_icu_handle_t v;
- int link, *clinkp;
+via8231_getclink(pciintr_icu_handle_t v, int link, int *clinkp)
{
struct via8231_handle *ph = v;
@@ -189,9 +183,7 @@ via8231_getclink(v, link, clinkp)
}
int
-via8231_get_intr(v, clink, irqp)
- pciintr_icu_handle_t v;
- int clink, *irqp;
+via8231_get_intr(pciintr_icu_handle_t v, int clink, int *irqp)
{
struct via8231_handle *ph = v;
int reg, val;
@@ -214,9 +206,7 @@ via8231_get_intr(v, clink, irqp)
}
int
-via8231_set_intr(v, clink, irq)
- pciintr_icu_handle_t v;
- int clink, irq;
+via8231_set_intr(pciintr_icu_handle_t v, int clink, int irq)
{
struct via8231_handle *ph = v;
int reg;
@@ -243,9 +233,7 @@ via8231_set_intr(v, clink, irq)
}
int
-via8231_get_trigger(v, irq, triggerp)
- pciintr_icu_handle_t v;
- int irq, *triggerp;
+via8231_get_trigger(pciintr_icu_handle_t v, int irq, int *triggerp)
{
struct via8231_handle *ph = v;
int reg, clink, max, pciirq;
@@ -270,9 +258,7 @@ via8231_get_trigger(v, irq, triggerp)
}
int
-via8231_set_trigger(v, irq, trigger)
- pciintr_icu_handle_t v;
- int irq, trigger;
+via8231_set_trigger(pciintr_icu_handle_t v, int irq, int trigger)
{
struct via8231_handle *ph = v;
int reg, clink, max, pciirq;
@@ -317,9 +303,7 @@ via8231_set_trigger(v, irq, trigger)
#ifdef VIA8231_DEBUG
static void
-via8231_pir_dump(m, ph)
- const char* m;
- struct via8231_handle *ph;
+via8231_pir_dump(const char *m, struct via8231_handle *ph)
{
int a, b;
diff --git a/sys/arch/i386/pci/via82c586.c b/sys/arch/i386/pci/via82c586.c
index 6e1137ea241..ce45ddedcf3 100644
--- a/sys/arch/i386/pci/via82c586.c
+++ b/sys/arch/i386/pci/via82c586.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: via82c586.c,v 1.9 2002/03/14 01:26:33 millert Exp $ */
+/* $OpenBSD: via82c586.c,v 1.10 2006/09/19 11:06:34 jsg Exp $ */
/* $NetBSD: via82c586.c,v 1.2 2000/07/18 11:24:09 soda Exp $ */
/*-
@@ -120,12 +120,8 @@ const int vp3_cfg_intr_shift[] = {
VP3_CFG_INTR_MASK)
int
-via82c586_init(pc, iot, tag, ptagp, phandp)
- pci_chipset_tag_t pc;
- bus_space_tag_t iot;
- pcitag_t tag;
- pciintr_icu_tag_t *ptagp;
- pciintr_icu_handle_t *phandp;
+via82c586_init(pci_chipset_tag_t pc, bus_space_tag_t iot, pcitag_t tag,
+ pciintr_icu_tag_t *ptagp, pciintr_icu_handle_t *phandp)
{
pcireg_t reg;
@@ -147,9 +143,7 @@ via82c586_init(pc, iot, tag, ptagp, phandp)
}
int
-via82c586_getclink(v, link, clinkp)
- pciintr_icu_handle_t v;
- int link, *clinkp;
+via82c586_getclink(pciintr_icu_handle_t v, int link, int *clinkp)
{
if (VP3_LEGAL_LINK(link - 1)) {
@@ -161,9 +155,7 @@ via82c586_getclink(v, link, clinkp)
}
int
-via82c586_get_intr(v, clink, irqp)
- pciintr_icu_handle_t v;
- int clink, *irqp;
+via82c586_get_intr(pciintr_icu_handle_t v, int clink, int *irqp)
{
struct piix_handle *ph = v;
pcireg_t reg;
@@ -181,9 +173,7 @@ via82c586_get_intr(v, clink, irqp)
}
int
-via82c586_set_intr(v, clink, irq)
- pciintr_icu_handle_t v;
- int clink, irq;
+via82c586_set_intr(pciintr_icu_handle_t v, int clink, int irq)
{
struct piix_handle *ph = v;
int shift, val;
@@ -206,9 +196,7 @@ via82c586_set_intr(v, clink, irq)
}
int
-via82c586_get_trigger(v, irq, triggerp)
- pciintr_icu_handle_t v;
- int irq, *triggerp;
+via82c586_get_trigger(pciintr_icu_handle_t v, int irq, int *triggerp)
{
struct piix_handle *ph = v;
int i, error, check_consistency, pciirq, pcitrigger = IST_NONE;
@@ -239,9 +227,7 @@ via82c586_get_trigger(v, irq, triggerp)
}
int
-via82c586_set_trigger(v, irq, trigger)
- pciintr_icu_handle_t v;
- int irq, trigger;
+via82c586_set_trigger(pciintr_icu_handle_t v, int irq, int trigger)
{
struct piix_handle *ph = v;
int i, pciirq, shift, testtrig;