Sun Mar 15 15:52:12 2009 UTC ()
ansify function definitions


(cegger)
diff -r1.16 -r1.17 src/sys/dev/ic/aic79xx_inline.h
diff -r1.16 -r1.17 src/sys/dev/ic/esiopvar.h
diff -r1.13 -r1.14 src/sys/dev/ic/aic7xxx_inline.h
diff -r1.20 -r1.21 src/sys/dev/ic/aic7xxx_osm.h
diff -r1.44 -r1.45 src/sys/dev/ic/esiop.c
diff -r1.86 -r1.87 src/sys/dev/ic/midway.c
diff -r1.18 -r1.19 src/sys/dev/ic/pcdisplayvar.h

cvs diff -r1.16 -r1.17 src/sys/dev/ic/aic79xx_inline.h (expand / switch to context diff)
--- src/sys/dev/ic/aic79xx_inline.h 2008/03/21 08:17:30 1.16
+++ src/sys/dev/ic/aic79xx_inline.h 2009/03/15 15:52:12 1.17
@@ -1,4 +1,4 @@
-/*	$NetBSD: aic79xx_inline.h,v 1.16 2008/03/21 08:17:30 dyoung Exp $	*/
+/*	$NetBSD: aic79xx_inline.h,v 1.17 2009/03/15 15:52:12 cegger Exp $	*/
 
 /*
  * Inline routines shareable across OS platforms.
@@ -969,8 +969,7 @@
 }
 
 static __inline void
-ahd_minphys(bp)
-        struct buf *bp;
+ahd_minphys(struct buf *bp)
 {
 /*
  * Even though the card can transfer up to 16megs per command

cvs diff -r1.16 -r1.17 src/sys/dev/ic/esiopvar.h (expand / switch to context diff)
--- src/sys/dev/ic/esiopvar.h 2007/12/25 18:33:38 1.16
+++ src/sys/dev/ic/esiopvar.h 2009/03/15 15:52:12 1.17
@@ -1,4 +1,4 @@
-/*	$NetBSD: esiopvar.h,v 1.16 2007/12/25 18:33:38 perry Exp $	*/
+/*	$NetBSD: esiopvar.h,v 1.17 2009/03/15 15:52:12 cegger Exp $	*/
 
 /*
  * Copyright (c) 2002 Manuel Bouyer.
@@ -123,9 +123,7 @@
 
 static __inline void esiop_table_sync(struct esiop_cmd *, int);
 static __inline void
-esiop_table_sync(esiop_cmd, ops)
-	struct esiop_cmd *esiop_cmd;
-	int ops;
+esiop_table_sync(struct esiop_cmd *esiop_cmd, int ops)
 {
 	struct siop_common_softc *sc  = esiop_cmd->cmd_c.siop_sc;
 	bus_addr_t offset;

cvs diff -r1.13 -r1.14 src/sys/dev/ic/aic7xxx_inline.h (expand / switch to context diff)
--- src/sys/dev/ic/aic7xxx_inline.h 2008/02/11 21:43:46 1.13
+++ src/sys/dev/ic/aic7xxx_inline.h 2009/03/15 15:52:12 1.14
@@ -1,4 +1,4 @@
-/*	$NetBSD: aic7xxx_inline.h,v 1.13 2008/02/11 21:43:46 dyoung Exp $	*/
+/*	$NetBSD: aic7xxx_inline.h,v 1.14 2009/03/15 15:52:12 cegger Exp $	*/
 
 /*
  * Inline routines shareable across OS platforms.
@@ -506,8 +506,7 @@
 static __inline void	ahc_minphys(struct buf *bp);
 
 static __inline void
-ahc_minphys(bp)
-	struct buf *bp;
+ahc_minphys(struct buf *bp)
 {
 /*
  * Even though the card can transfer up to 16megs per command

cvs diff -r1.20 -r1.21 src/sys/dev/ic/aic7xxx_osm.h (expand / switch to context diff)
--- src/sys/dev/ic/aic7xxx_osm.h 2008/04/08 12:07:25 1.20
+++ src/sys/dev/ic/aic7xxx_osm.h 2009/03/15 15:52:12 1.21
@@ -1,4 +1,4 @@
-/*	$NetBSD: aic7xxx_osm.h,v 1.20 2008/04/08 12:07:25 cegger Exp $	*/
+/*	$NetBSD: aic7xxx_osm.h,v 1.21 2009/03/15 15:52:12 cegger Exp $	*/
 
 /*
  * NetBSD platform specific driver option settings, data structures,
@@ -297,7 +297,7 @@
 
 /* Lock held during ahc_list manipulation and ahc softc frees */
 static __inline void
-ahc_list_lockinit()
+ahc_list_lockinit(void)
 {
 }
 

cvs diff -r1.44 -r1.45 src/sys/dev/ic/esiop.c (expand / switch to context diff)
--- src/sys/dev/ic/esiop.c 2009/03/14 21:04:19 1.44
+++ src/sys/dev/ic/esiop.c 2009/03/15 15:52:12 1.45
@@ -1,4 +1,4 @@
-/*	$NetBSD: esiop.c,v 1.44 2009/03/14 21:04:19 dsl Exp $	*/
+/*	$NetBSD: esiop.c,v 1.45 2009/03/15 15:52:12 cegger Exp $	*/
 
 /*
  * Copyright (c) 2002 Manuel Bouyer.
@@ -33,7 +33,7 @@
 /* SYM53c7/8xx PCI-SCSI I/O Processors driver */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: esiop.c,v 1.44 2009/03/14 21:04:19 dsl Exp $");
+__KERNEL_RCSID(0, "$NetBSD: esiop.c,v 1.45 2009/03/15 15:52:12 cegger Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -2155,7 +2155,7 @@
 
 #ifdef SIOP_STATS
 void
-esiop_printstats()
+esiop_printstats(void)
 {
 	printf("esiop_stat_intr %d\n", esiop_stat_intr);
 	printf("esiop_stat_intr_shortxfer %d\n", esiop_stat_intr_shortxfer);

cvs diff -r1.86 -r1.87 src/sys/dev/ic/Attic/midway.c (expand / switch to context diff)
--- src/sys/dev/ic/Attic/midway.c 2009/03/14 15:36:17 1.86
+++ src/sys/dev/ic/Attic/midway.c 2009/03/15 15:52:12 1.87
@@ -1,4 +1,4 @@
-/*	$NetBSD: midway.c,v 1.86 2009/03/14 15:36:17 dsl Exp $	*/
+/*	$NetBSD: midway.c,v 1.87 2009/03/15 15:52:12 cegger Exp $	*/
 /*	(sync'd to midway.c 1.68)	*/
 
 /*
@@ -68,7 +68,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: midway.c,v 1.86 2009/03/14 15:36:17 dsl Exp $");
+__KERNEL_RCSID(0, "$NetBSD: midway.c,v 1.87 2009/03/15 15:52:12 cegger Exp $");
 
 #include "opt_natm.h"
 
@@ -495,11 +495,7 @@
  * that reads from the card.
  */
 
-STATIC INLINE u_int32_t en_read(sc, r)
-
-struct en_softc *sc;
-u_int32_t r;
-
+STATIC INLINE u_int32_t en_read(struct en_softc *sc, uint32_t r)
 {
 
 #ifdef EN_DEBUG_RANGE
@@ -515,11 +511,7 @@
  * writes to the card.
  */
 
-STATIC INLINE void en_write(sc, r, v)
-
-struct en_softc *sc;
-u_int32_t r, v;
-
+STATIC INLINE void en_write(struct en_softc *sc, uint32_t r, uint32_t v)
 {
 #ifdef EN_DEBUG_RANGE
   if (r > MID_MAXOFF || (r % 4))
@@ -533,10 +525,7 @@
  * en_k2sz: convert KBytes to a size parameter (a log2)
  */
 
-STATIC INLINE int en_k2sz(k)
-
-int k;
-
+STATIC INLINE int en_k2sz(int k)
 {
   switch(k) {
     case 1:   return(0);
@@ -558,10 +547,7 @@
  * en_b2sz: convert a DMA burst code to its byte size
  */
 
-STATIC INLINE int en_b2sz(b)
-
-int b;
-
+STATIC INLINE int en_b2sz(int b)
 {
   switch (b) {
     case MIDDMA_WORD:   return(1*4);
@@ -583,10 +569,7 @@
  * en_sz2b: convert a burst size (bytes) to DMA burst code
  */
 
-STATIC INLINE int en_sz2b(sz)
-
-int sz;
-
+STATIC INLINE int en_sz2b(int sz)
 {
   switch (sz) {
     case 1*4:  return(MIDDMA_WORD);
@@ -604,12 +587,7 @@
  * en_dqneed: calculate number of DTQ/DRQ's needed for a buffer
  */
 
-STATIC INLINE int en_dqneed(sc, data, len, tx)
-
-struct en_softc *sc;
-void *data;
-u_int len, tx;
-
+STATIC INLINE int en_dqneed(struct en_softc *sc, void *data, u_int len, u_int tx)
 {
   int result, needalign, sz;
 
@@ -670,11 +648,7 @@
  * after this call the sum of all the m_len's in the chain will be totlen.
  */
 
-STATIC INLINE struct mbuf *en_mget(sc, totlen, drqneed)
-
-struct en_softc *sc;
-u_int totlen, *drqneed;
-
+STATIC INLINE struct mbuf *en_mget(struct en_softc *sc, u_int totlen, u_int *drqneed)
 {
   struct mbuf *m;
   struct mbuf *top, **mp;
@@ -725,10 +699,7 @@
  * autoconfig stuff
  */
 
-void en_attach(sc)
-
-struct en_softc *sc;
-
+void en_attach(struct en_softc *sc)
 {
   struct ifnet *ifp = &sc->enif;
   int sz;
@@ -934,10 +905,7 @@
  * p166:   bestburstlen=64, alburst=0
  */
 
-STATIC void en_dmaprobe(sc)
-
-struct en_softc *sc;
-
+STATIC void en_dmaprobe(struct en_softc *sc)
 {
   u_int32_t srcbuf[64], dstbuf[64];
   u_int8_t *sp, *dp;
@@ -1009,12 +977,7 @@
  */
 
 int
-en_dmaprobe_doit(sc, sp, dp, wmtry)
-
-struct en_softc *sc;
-u_int8_t *sp, *dp;
-int wmtry;
-
+en_dmaprobe_doit(struct en_softc *sc, uint8_t *sp, uint8_t *dp, int wmtry)
 {
   int lcv, retval = 4, cnt, count;
   u_int32_t reg, bcode, midvloc;
@@ -1145,12 +1108,7 @@
  * txspeed[vci].
  */
 
-STATIC int en_ioctl(ifp, cmd, data)
-
-struct ifnet *ifp;
-EN_IOCTL_CMDT cmd;
-void *data;
-
+STATIC int en_ioctl(struct ifnet *ifp, EN_IOCTL_CMDT cmd, void *data)
 {
 #ifdef MISSING_IF_SOFTC
     struct en_softc *sc = (struct en_softc *)device_lookup_private(&en_cd, ifp->if_unit);
@@ -1347,12 +1305,7 @@
  * en_rxctl: turn on and off VCs for recv.
  */
 
-STATIC int en_rxctl(sc, pi, on)
-
-struct en_softc *sc;
-struct atm_pseudoioctl *pi;
-int on;
-
+STATIC int en_rxctl(struct en_softc *sc, struct atm_pseudoioctl *pi, int on)
 {
   u_int s, vci, flags, slot;
   u_int32_t oldmode, newmode;
@@ -1445,10 +1398,7 @@
  * must en_init to recover.
  */
 
-void en_reset(sc)
-
-struct en_softc *sc;
-
+void en_reset(struct en_softc *sc)
 {
   struct mbuf *m;
   int lcv, slot;
@@ -1520,10 +1470,7 @@
  * en_init: init board and sync the card with the data in the softc.
  */
 
-STATIC void en_init(sc)
-
-struct en_softc *sc;
-
+STATIC void en_init(struct en_softc *sc)
 {
   int vc, slot;
   u_int32_t loc;
@@ -1641,11 +1588,7 @@
  * en_loadvc: load a vc tab entry from a slot
  */
 
-STATIC void en_loadvc(sc, vc)
-
-struct en_softc *sc;
-int vc;
-
+STATIC void en_loadvc(struct en_softc *sc, int vc)
 {
   int slot;
   u_int32_t reg = EN_READ(sc, MID_VC(vc));
@@ -1674,10 +1617,7 @@
  * if there is one.    note that atm_output() has already splnet()'d us.
  */
 
-STATIC void en_start(ifp)
-
-struct ifnet *ifp;
-
+STATIC void en_start(struct ifnet *ifp)
 {
 #ifdef MISSING_IF_SOFTC
     struct en_softc *sc = (struct en_softc *)device_lookup_private(&en_cd, ifp->if_unit);
@@ -1868,11 +1808,7 @@
 
 #ifndef __FreeBSD__
 
-STATIC int en_mfix(sc, mm, prev)
-
-struct en_softc *sc;
-struct mbuf **mm, *prev;
-
+STATIC int en_mfix(struct en_softc *sc, struct mbuf **mm, struct mbuf *prev)
 {
   struct mbuf *m, *new;
   u_char *d, *cp;
@@ -2076,11 +2012,7 @@
  * en_txdma: start transmit DMA, if possible
  */
 
-STATIC void en_txdma(sc, chan)
-
-struct en_softc *sc;
-int chan;
-
+STATIC void en_txdma(struct en_softc *sc, int chan)
 {
   struct mbuf *tmp;
   struct atm_pseudohdr *ap;
@@ -2307,12 +2239,7 @@
  * en_txlaunch: launch an mbuf into the DMA pool!
  */
 
-STATIC void en_txlaunch(sc, chan, l)
-
-struct en_softc *sc;
-int chan;
-struct en_launch *l;
-
+STATIC void en_txlaunch(struct en_softc *sc, int chan, struct en_launch *l)
 {
   struct mbuf *tmp;
   u_int32_t cur = sc->txslot[chan].cur,
@@ -2664,10 +2591,7 @@
  * interrupt handler
  */
 
-EN_INTR_TYPE en_intr(arg)
-
-void *arg;
-
+EN_INTR_TYPE en_intr(void *arg)
 {
   struct en_softc *sc = (struct en_softc *) arg;
   struct mbuf *m;
@@ -2970,10 +2894,7 @@
  *
  */
 
-STATIC void en_service(sc)
-
-struct en_softc *sc;
-
+STATIC void en_service(struct en_softc *sc)
 {
   struct mbuf *m, *tmp;
   u_int32_t cur, dstart, rbd, pdu, *sav, dma, bcode, count, *data, *datastop;
@@ -3403,10 +3324,7 @@
 
 #define END_BITS "\20\7SWSL\6DRQ\5DTQ\4RX\3TX\2MREGS\1STATS"
 
-int en_dump(unit, level)
-
-int unit, level;
-
+int en_dump(int unit, int level)
 {
   struct en_softc *sc;
   int lcv, cnt, slot;
@@ -3573,10 +3491,7 @@
  * en_dumpmem: dump the memory
  */
 
-int en_dumpmem(unit, addr, len)
-
-int unit, addr, len;
-
+int en_dumpmem(int unit, int addr, int len)
 {
   struct en_softc *sc;
   u_int32_t reg;
@@ -3612,9 +3527,7 @@
  * a round-robin fashion when en_start is called from tx complete
  * interrupts.
  */
-static void rrp_add(sc, ifp)
-	struct en_softc *sc;
-	struct ifnet *ifp;
+static void rrp_add(struct en_softc *sc, struct ifnet *ifp)
 {
 	struct rrp *head, *p, *new;
 
@@ -3655,9 +3568,7 @@
 }
 
 #if 0 /* not used */
-static void rrp_delete(sc, ifp)
-	struct en_softc *sc;
-	struct ifnet *ifp;
+static void rrp_delete(struct en_softc *sc, struct ifnet *ifp)
 {
 	struct rrp *head, *p, *prev;
 
@@ -3747,8 +3658,7 @@
    by Werner Almesberger, EPFL LRC */
 static const int pre_div[] = { 4,16,128,2048 };
 
-static int en_pcr2txspeed(pcr)
-	int pcr;
+static int en_pcr2txspeed(int pcr)
 {
 	int pre, res, div;
 
@@ -3777,8 +3687,7 @@
 	return ((pre << 6) + res);
 }
 
-static int en_txspeed2pcr(txspeed)
-	int txspeed;
+static int en_txspeed2pcr(int txspeed)
 {
 	int pre, res, pcr;
 
@@ -3794,11 +3703,7 @@
  * since it assumes a transmit channel is already assigned by en_rxctl
  * to the vc.
  */
-static int en_txctl(sc, vci, joint_vci, pcr)
-	struct en_softc *sc;
-	int vci;
-	int joint_vci;
-	int pcr;
+static int en_txctl(struct en_softc *sc, int vci, int joint_vci, int pcr)
 {
 	int txspeed, txchan, s;
 
@@ -3856,9 +3761,7 @@
 	return (0);
 }
 
-static int en_pvctx(sc, pvcreq)
-	struct en_softc *sc;
-	struct pvctxreq *pvcreq;
+static int en_pvctx(struct en_softc *sc, struct pvctxreq *pvcreq)
 {
 	struct ifnet *ifp;
 	struct atm_pseudoioctl api;
@@ -3963,9 +3866,7 @@
 	return error;
 }
 
-static int en_pvctxget(sc, pvcreq)
-	struct en_softc *sc;
-	struct pvctxreq *pvcreq;
+static int en_pvctxget(struct en_softc *sc, struct pvctxreq *pvcreq)
 {
 	struct pvcsif *pvcsif;
 	struct ifnet *ifp;

cvs diff -r1.18 -r1.19 src/sys/dev/ic/pcdisplayvar.h (expand / switch to context diff)
--- src/sys/dev/ic/pcdisplayvar.h 2006/05/14 21:42:27 1.18
+++ src/sys/dev/ic/pcdisplayvar.h 2009/03/15 15:52:12 1.19
@@ -1,4 +1,4 @@
-/* $NetBSD: pcdisplayvar.h,v 1.18 2006/05/14 21:42:27 elad Exp $ */
+/* $NetBSD: pcdisplayvar.h,v 1.19 2009/03/15 15:52:12 cegger Exp $ */
 
 /*
  * Copyright (c) 1998
@@ -55,18 +55,14 @@
 static __inline void _pcdisplay_6845_write(struct pcdisplay_handle *, int,
 					 u_int8_t);
 
-static __inline u_int8_t _pcdisplay_6845_read(ph, reg)
-	struct pcdisplay_handle *ph;
-	int reg;
+static __inline u_int8_t _pcdisplay_6845_read(struct pcdisplay_handle *ph, int reg)
 {
 	bus_space_write_1(ph->ph_iot, ph->ph_ioh_6845, MC6845_INDEX, reg);
 	return (bus_space_read_1(ph->ph_iot, ph->ph_ioh_6845, MC6845_DATA));
 }
 
-static __inline void _pcdisplay_6845_write(ph, reg, val)
-	struct pcdisplay_handle *ph;
-	int reg;
-	u_int8_t val;
+static __inline void _pcdisplay_6845_write(struct pcdisplay_handle *ph,
+					int reg, uint8_t val)
 {
 	bus_space_write_1(ph->ph_iot, ph->ph_ioh_6845, MC6845_INDEX, reg);
 	bus_space_write_1(ph->ph_iot, ph->ph_ioh_6845, MC6845_DATA, val);