Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev ANSIfy.
details: https://anonhg.NetBSD.org/src/rev/2f0b8a7e5036
branches: trunk
changeset: 515704:2f0b8a7e5036
user: augustss <augustss%NetBSD.org@localhost>
date: Tue Oct 02 22:41:22 2001 +0000
description:
ANSIfy.
diffstat:
sys/dev/midi.c | 128 +++++++++++++++-----------------------------------
sys/dev/midi_if.h | 30 +++++-----
sys/dev/midisyn.c | 77 +++++++++--------------------
sys/dev/midisynvar.h | 28 +++++-----
4 files changed, 92 insertions(+), 171 deletions(-)
diffs (truncated from 574 to 300 lines):
diff -r db6cf46e4a4a -r 2f0b8a7e5036 sys/dev/midi.c
--- a/sys/dev/midi.c Tue Oct 02 21:31:01 2001 +0000
+++ b/sys/dev/midi.c Tue Oct 02 22:41:22 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: midi.c,v 1.21 2001/01/31 16:19:35 tshiozak Exp $ */
+/* $NetBSD: midi.c,v 1.22 2001/10/02 22:41:22 augustss Exp $ */
/*
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -74,19 +74,19 @@
int midi_wait;
-void midi_in __P((void *, int));
-void midi_out __P((void *));
-int midi_start_output __P((struct midi_softc *, int));
-int midi_sleep_timo __P((int *, char *, int));
-int midi_sleep __P((int *, char *));
-void midi_wakeup __P((int *));
-void midi_initbuf __P((struct midi_buffer *));
-void midi_timeout __P((void *));
+void midi_in(void *, int);
+void midi_out(void *);
+int midi_start_output(struct midi_softc *, int);
+int midi_sleep_timo(int *, char *, int);
+int midi_sleep(int *, char *);
+void midi_wakeup(int *);
+void midi_initbuf(struct midi_buffer *);
+void midi_timeout(void *);
-int midiprobe __P((struct device *, struct cfdata *, void *));
-void midiattach __P((struct device *, struct device *, void *));
-int mididetach __P((struct device *, int));
-int midiactivate __P((struct device *, enum devact));
+int midiprobe(struct device *, struct cfdata *, void *);
+void midiattach(struct device *, struct device *, void *);
+int mididetach(struct device *, int);
+int midiactivate(struct device *, enum devact);
struct cfattach midi_ca = {
sizeof(struct midi_softc), midiprobe, midiattach,
@@ -107,10 +107,7 @@
extern struct cfdriver midi_cd;
int
-midiprobe(parent, match, aux)
- struct device *parent;
- struct cfdata *match;
- void *aux;
+midiprobe(struct device *parent, struct cfdata *match, void *aux)
{
struct audio_attach_args *sa = aux;
@@ -120,9 +117,7 @@
}
void
-midiattach(parent, self, aux)
- struct device *parent, *self;
- void *aux;
+midiattach(struct device *parent, struct device *self, void *aux)
{
struct midi_softc *sc = (void *)self;
struct audio_attach_args *sa = aux;
@@ -151,9 +146,7 @@
}
int
-midiactivate(self, act)
- struct device *self;
- enum devact act;
+midiactivate(struct device *self, enum devact act)
{
struct midi_softc *sc = (struct midi_softc *)self;
@@ -170,9 +163,7 @@
}
int
-mididetach(self, flags)
- struct device *self;
- int flags;
+mididetach(struct device *self, int flags)
{
struct midi_softc *sc = (struct midi_softc *)self;
int maj, mn;
@@ -197,9 +188,7 @@
}
void
-midi_attach(sc, parent)
- struct midi_softc *sc;
- struct device *parent;
+midi_attach(struct midi_softc *sc, struct device *parent)
{
struct midi_info mi;
@@ -216,14 +205,13 @@
}
int
-midi_unit_count()
+midi_unit_count(void)
{
return midi_cd.cd_ndevs;
}
void
-midi_initbuf(mb)
- struct midi_buffer *mb;
+midi_initbuf(struct midi_buffer *mb)
{
mb->used = 0;
mb->usedhigh = MIDI_BUFSIZE;
@@ -232,10 +220,7 @@
}
int
-midi_sleep_timo(chan, label, timo)
- int *chan;
- char *label;
- int timo;
+midi_sleep_timo(int *chan, char *label, int timo)
{
int st;
@@ -254,16 +239,13 @@
}
int
-midi_sleep(chan, label)
- int *chan;
- char *label;
+midi_sleep(int *chan, char *label)
{
return midi_sleep_timo(chan, label, 0);
}
void
-midi_wakeup(chan)
- int *chan;
+midi_wakeup(int *chan)
{
if (*chan) {
DPRINTFN(5, ("midi_wakeup: %p\n", chan));
@@ -277,9 +259,7 @@
#define MIDI_LENGTH(d) (midi_lengths[((d) >> 4) & 7])
void
-midi_in(addr, data)
- void *addr;
- int data;
+midi_in(void *addr, int data)
{
struct midi_softc *sc = addr;
struct midi_buffer *mb = &sc->inbuf;
@@ -353,7 +333,7 @@
sc->in_state = MIDI_IN_START;
#if NSEQUENCER > 0
if (sc->seqopen) {
- extern void midiseq_in __P((struct midi_dev *,u_char *,int));
+ extern void midiseq_in(struct midi_dev *,u_char *,int);
midiseq_in(sc->seq_md, sc->in_msg, sc->in_pos);
return;
}
@@ -377,8 +357,7 @@
}
void
-midi_out(addr)
- void *addr;
+midi_out(void *addr)
{
struct midi_softc *sc = addr;
@@ -389,10 +368,7 @@
}
int
-midiopen(dev, flags, ifmt, p)
- dev_t dev;
- int flags, ifmt;
- struct proc *p;
+midiopen(dev_t dev, int flags, int ifmt, struct proc *p)
{
struct midi_softc *sc;
struct midi_hw_if *hw;
@@ -436,10 +412,7 @@
}
int
-midiclose(dev, flags, ifmt, p)
- dev_t dev;
- int flags, ifmt;
- struct proc *p;
+midiclose(dev_t dev, int flags, int ifmt, struct proc *p)
{
int unit = MIDIUNIT(dev);
struct midi_softc *sc = midi_cd.cd_devs[unit];
@@ -466,10 +439,7 @@
}
int
-midiread(dev, uio, ioflag)
- dev_t dev;
- struct uio *uio;
- int ioflag;
+midiread(dev_t dev, struct uio *uio, int ioflag)
{
int unit = MIDIUNIT(dev);
struct midi_softc *sc = midi_cd.cd_devs[unit];
@@ -528,8 +498,7 @@
}
void
-midi_timeout(arg)
- void *arg;
+midi_timeout(void *arg)
{
struct midi_softc *sc = arg;
@@ -538,9 +507,7 @@
}
int
-midi_start_output(sc, intr)
- struct midi_softc *sc;
- int intr;
+midi_start_output(struct midi_softc *sc, int intr)
{
struct midi_buffer *mb = &sc->outbuf;
u_char out;
@@ -599,10 +566,7 @@
}
int
-midiwrite(dev, uio, ioflag)
- dev_t dev;
- struct uio *uio;
- int ioflag;
+midiwrite(dev_t dev, struct uio *uio, int ioflag)
{
int unit = MIDIUNIT(dev);
struct midi_softc *sc = midi_cd.cd_devs[unit];
@@ -671,10 +635,7 @@
* a write that is smaller than the MIDI buffer.
*/
int
-midi_writebytes(unit, buf, cc)
- int unit;
- u_char *buf;
- int cc;
+midi_writebytes(int unit, u_char *buf, int cc)
{
struct midi_softc *sc = midi_cd.cd_devs[unit];
struct midi_buffer *mb = &sc->outbuf;
@@ -710,12 +671,7 @@
}
int
-midiioctl(dev, cmd, addr, flag, p)
- dev_t dev;
- u_long cmd;
- caddr_t addr;
- int flag;
- struct proc *p;
+midiioctl(dev_t dev, u_long cmd, caddr_t addr, int flag, struct proc *p)
{
int unit = MIDIUNIT(dev);
struct midi_softc *sc = midi_cd.cd_devs[unit];
@@ -769,10 +725,7 @@
}
int
-midipoll(dev, events, p)
- dev_t dev;
- int events;
- struct proc *p;
+midipoll(dev_t dev, int events, struct proc *p)
{
int unit = MIDIUNIT(dev);
struct midi_softc *sc = midi_cd.cd_devs[unit];
@@ -805,9 +758,7 @@
}
void
-midi_getinfo(dev, mi)
- dev_t dev;
- struct midi_info *mi;
+midi_getinfo(dev_t dev, struct midi_info *mi)
{
struct midi_softc *sc;
@@ -824,13 +775,10 @@
#if NMIDI > 0 || NMIDIBUS > 0
-int audioprint __P((void *, const char *));
+int audioprint(void *, const char *);
Home |
Main Index |
Thread Index |
Old Index