mirror of
https://git.hardenedbsd.org/hardenedbsd/HardenedBSD.git
synced 2025-01-01 00:18:15 +01:00
Fix benign type mismatches in devsw functions. 82 out of 299 devsw
functions were wrong.
This commit is contained in:
parent
6ad37c02fb
commit
6003967057
@ -38,7 +38,7 @@
|
||||
*
|
||||
* from: Utah $Hdr: mem.c 1.13 89/10/08$
|
||||
* from: @(#)mem.c 7.2 (Berkeley) 5/9/91
|
||||
* $Id: mem.c,v 1.9 1994/08/06 10:25:34 davidg Exp $
|
||||
* $Id: mem.c,v 1.10 1995/09/03 05:43:04 julian Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -85,10 +85,11 @@ SYSINIT(memdev,SI_SUB_DEVFS, SI_ORDER_ANY, memdev_init, NULL)
|
||||
extern char *ptvmmap; /* poor name! */
|
||||
/*ARGSUSED*/
|
||||
int
|
||||
mmclose(dev, uio, flags)
|
||||
mmclose(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
struct uio *uio;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
struct trapframe *fp;
|
||||
|
||||
@ -104,10 +105,11 @@ mmclose(dev, uio, flags)
|
||||
}
|
||||
/*ARGSUSED*/
|
||||
int
|
||||
mmopen(dev, uio, flags)
|
||||
mmopen(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
struct uio *uio;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
struct trapframe *fp;
|
||||
|
||||
|
@ -40,7 +40,7 @@
|
||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* $Id: mcd.c,v 1.44 1995/05/30 08:02:44 rgrimes Exp $
|
||||
* $Id: mcd.c,v 1.45 1995/08/15 19:56:59 joerg Exp $
|
||||
*/
|
||||
static char COPYRIGHT[] = "mcd-driver (C)1993 by H.Veit & B.Moore";
|
||||
|
||||
@ -164,10 +164,10 @@ struct mcd_data {
|
||||
#define MCD_S_WAITREAD 4
|
||||
|
||||
/* prototypes */
|
||||
int mcdopen(dev_t dev);
|
||||
int mcdclose(dev_t dev);
|
||||
int mcdopen(dev_t dev, int flags, int fmt, struct proc *p);
|
||||
int mcdclose(dev_t dev, int flags, int fmt, struct proc *p);
|
||||
void mcdstrategy(struct buf *bp);
|
||||
int mcdioctl(dev_t dev, int cmd, caddr_t addr, int flags);
|
||||
int mcdioctl(dev_t dev, int cmd, caddr_t addr, int flags, struct proc *p);
|
||||
int mcdsize(dev_t dev);
|
||||
static void mcd_done(struct mcd_mbx *mbx);
|
||||
static void mcd_start(int unit);
|
||||
@ -265,7 +265,7 @@ int mcd_attach(struct isa_device *dev)
|
||||
return 1;
|
||||
}
|
||||
|
||||
int mcdopen(dev_t dev)
|
||||
int mcdopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int unit,part,phys,r,retry;
|
||||
struct mcd_data *cd;
|
||||
@ -341,7 +341,7 @@ MCD_TRACE("open: partition=%d, disksize = %ld, blksize=%d\n",
|
||||
return ENXIO;
|
||||
}
|
||||
|
||||
int mcdclose(dev_t dev)
|
||||
int mcdclose(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int unit,part,phys;
|
||||
struct mcd_data *cd;
|
||||
@ -491,7 +491,7 @@ static void mcd_start(int unit)
|
||||
return;
|
||||
}
|
||||
|
||||
int mcdioctl(dev_t dev, int cmd, caddr_t addr, int flags)
|
||||
int mcdioctl(dev_t dev, int cmd, caddr_t addr, int flags, struct proc *p)
|
||||
{
|
||||
struct mcd_data *cd;
|
||||
int unit,part;
|
||||
|
@ -11,7 +11,7 @@
|
||||
* this software for any purpose. It is provided "as is"
|
||||
* without express or implied warranty.
|
||||
*
|
||||
* $Id: mse.c,v 1.12 1995/05/30 08:02:47 rgrimes Exp $
|
||||
* $Id: mse.c,v 1.13 1995/07/16 10:12:06 bde Exp $
|
||||
*/
|
||||
/*
|
||||
* Driver for the Logitech and ATI Inport Bus mice for use with 386bsd and
|
||||
@ -241,9 +241,11 @@ mseattach(idp)
|
||||
* Exclusive open the mouse, initialize it and enable interrupts.
|
||||
*/
|
||||
int
|
||||
mseopen(dev, flag)
|
||||
mseopen(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
int flag;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
register struct mse_softc *sc;
|
||||
int s;
|
||||
@ -272,9 +274,11 @@ mseopen(dev, flag)
|
||||
* mseclose: just turn off mouse innterrupts.
|
||||
*/
|
||||
int
|
||||
mseclose(dev, flag)
|
||||
mseclose(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
int flag;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
struct mse_softc *sc = &mse_sc[MSE_UNIT(dev)];
|
||||
int s;
|
||||
@ -293,9 +297,10 @@ mseclose(dev, flag)
|
||||
* (Yes this is cheesy, but it makes the X386 server happy, so...)
|
||||
*/
|
||||
int
|
||||
mseread(dev, uio)
|
||||
mseread(dev, uio, ioflag)
|
||||
dev_t dev;
|
||||
struct uio *uio;
|
||||
int ioflag;
|
||||
{
|
||||
register struct mse_softc *sc = &mse_sc[MSE_UNIT(dev)];
|
||||
int xfer, s, error;
|
||||
|
@ -41,7 +41,7 @@
|
||||
*/
|
||||
|
||||
|
||||
/* $Id: scd.c,v 1.4 1995/05/09 12:25:58 rgrimes Exp $ */
|
||||
/* $Id: scd.c,v 1.5 1995/05/30 08:03:02 rgrimes Exp $ */
|
||||
|
||||
/* Please send any comments to micke@dynas.se */
|
||||
|
||||
@ -142,10 +142,10 @@ struct scd_data {
|
||||
} scd_data[NSCD];
|
||||
|
||||
/* prototypes */
|
||||
int scdopen(dev_t dev);
|
||||
int scdclose(dev_t dev);
|
||||
int scdopen(dev_t dev, int flags, int fmt, struct proc *p);
|
||||
int scdclose(dev_t dev, int flags, int fmt, struct proc *p);
|
||||
void scdstrategy(struct buf *bp);
|
||||
int scdioctl(dev_t dev, int cmd, caddr_t addr, int flags);
|
||||
int scdioctl(dev_t dev, int cmd, caddr_t addr, int flags, struct proc *p);
|
||||
int scdsize(dev_t dev);
|
||||
|
||||
static int bcd2bin(bcd_t b);
|
||||
@ -230,7 +230,7 @@ int scd_attach(struct isa_device *dev)
|
||||
}
|
||||
|
||||
int
|
||||
scdopen(dev_t dev)
|
||||
scdopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int unit,part,phys;
|
||||
int rc;
|
||||
@ -283,7 +283,7 @@ scdopen(dev_t dev)
|
||||
}
|
||||
|
||||
int
|
||||
scdclose(dev_t dev)
|
||||
scdclose(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int unit,part,phys;
|
||||
struct scd_data *cd;
|
||||
@ -419,7 +419,7 @@ scd_start(int unit)
|
||||
}
|
||||
|
||||
int
|
||||
scdioctl(dev_t dev, int cmd, caddr_t addr, int flags)
|
||||
scdioctl(dev_t dev, int cmd, caddr_t addr, int flags, struct proc *p)
|
||||
{
|
||||
struct scd_data *cd;
|
||||
int unit,part;
|
||||
|
@ -339,9 +339,11 @@ detach_notty:
|
||||
}
|
||||
|
||||
int
|
||||
snpclose(dev, flag)
|
||||
snpclose(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
int flag;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
register int unit = minor(dev);
|
||||
struct snoop *snp = &snoopsw[unit];
|
||||
@ -367,11 +369,12 @@ snpdown(snp)
|
||||
|
||||
|
||||
int
|
||||
snpioctl(dev, cmd, data, flag)
|
||||
snpioctl(dev, cmd, data, flags, p)
|
||||
dev_t dev;
|
||||
int cmd;
|
||||
caddr_t data;
|
||||
int flag;
|
||||
int flags;
|
||||
struct proc *p;
|
||||
{
|
||||
int unit = minor(dev), s;
|
||||
dev_t tdev;
|
||||
|
@ -4,7 +4,7 @@
|
||||
* v1.4 by Eric S. Raymond (esr@snark.thyrsus.com) Aug 1993
|
||||
* modified for FreeBSD by Andrew A. Chernov <ache@astral.msk.su>
|
||||
*
|
||||
* $Id: spkr.c,v 1.14 1995/05/30 08:03:09 rgrimes Exp $
|
||||
* $Id: spkr.c,v 1.15 1995/09/03 05:43:31 julian Exp $
|
||||
*/
|
||||
|
||||
#include "speaker.h"
|
||||
@ -451,8 +451,11 @@ size_t slen;
|
||||
static int spkr_active = FALSE; /* exclusion flag */
|
||||
static struct buf *spkr_inbuf; /* incoming buf */
|
||||
|
||||
int spkropen(dev)
|
||||
dev_t dev;
|
||||
int spkropen(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
#ifdef DEBUG
|
||||
(void) printf("spkropen: entering with dev = %x\n", dev);
|
||||
@ -474,9 +477,10 @@ dev_t dev;
|
||||
}
|
||||
}
|
||||
|
||||
int spkrwrite(dev, uio)
|
||||
int spkrwrite(dev, uio, ioflag)
|
||||
dev_t dev;
|
||||
struct uio *uio;
|
||||
int ioflag;
|
||||
{
|
||||
#ifdef DEBUG
|
||||
printf("spkrwrite: entering with dev = %x, count = %d\n",
|
||||
@ -501,8 +505,11 @@ struct uio *uio;
|
||||
}
|
||||
}
|
||||
|
||||
int spkrclose(dev)
|
||||
dev_t dev;
|
||||
int spkrclose(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
#ifdef DEBUG
|
||||
(void) printf("spkrclose: entering with dev = %x\n", dev);
|
||||
@ -520,10 +527,12 @@ dev_t dev;
|
||||
}
|
||||
}
|
||||
|
||||
int spkrioctl(dev, cmd, cmdarg)
|
||||
dev_t dev;
|
||||
int cmd;
|
||||
caddr_t cmdarg;
|
||||
int spkrioctl(dev, cmd, cmdarg, flags, p)
|
||||
dev_t dev;
|
||||
int cmd;
|
||||
caddr_t cmdarg;
|
||||
int flags;
|
||||
struct proc *p;
|
||||
{
|
||||
#ifdef DEBUG
|
||||
(void) printf("spkrioctl: entering with dev = %x, cmd = %x\n");
|
||||
|
@ -129,12 +129,12 @@ u_long vn_options;
|
||||
int vnclose __P((dev_t dev, int flags, int mode, struct proc *p));
|
||||
int vnopen __P((dev_t dev, int flags, int mode, struct proc *p));
|
||||
void vnstrategy __P((struct buf *bp));
|
||||
int vnioctl __P((dev_t dev, u_long cmd, caddr_t data, int flag, struct proc *p));
|
||||
int vnioctl __P((dev_t dev, int cmd, caddr_t data, int flag, struct proc *p));
|
||||
void vniodone __P((struct buf *bp));
|
||||
int vnsetcred __P((struct vn_softc *vn, struct ucred *cred));
|
||||
void vnshutdown __P((void));
|
||||
void vnclear __P((struct vn_softc *vn));
|
||||
size_t vnsize __P((dev_t dev));
|
||||
int vnsize __P((dev_t dev));
|
||||
int vndump __P((dev_t dev));
|
||||
|
||||
int
|
||||
@ -377,7 +377,7 @@ vniodone( struct buf *bp) {
|
||||
|
||||
/* ARGSUSED */
|
||||
int
|
||||
vnioctl(dev_t dev, u_long cmd, caddr_t data, int flag, struct proc *p)
|
||||
vnioctl(dev_t dev, int cmd, caddr_t data, int flag, struct proc *p)
|
||||
{
|
||||
struct vn_softc *vn = vn_softc[vnunit(dev)];
|
||||
struct vn_ioctl *vio;
|
||||
@ -577,7 +577,7 @@ vnclear(struct vn_softc *vn)
|
||||
dsgone(&vn->sc_slices);
|
||||
}
|
||||
|
||||
size_t
|
||||
int
|
||||
vnsize(dev_t dev)
|
||||
{
|
||||
int unit = vnunit(dev);
|
||||
|
@ -1,6 +1,6 @@
|
||||
static char nic38_id[] = "@(#)$Id: nic3008.c,v 1.5 1995/05/11 19:25:55 rgrimes Exp $";
|
||||
static char nic38_id[] = "@(#)$Id: nic3008.c,v 1.6 1995/05/30 07:57:57 rgrimes Exp $";
|
||||
/*******************************************************************************
|
||||
* II - Version 0.1 $Revision: 1.5 $ $State: Exp $
|
||||
* II - Version 0.1 $Revision: 1.6 $ $State: Exp $
|
||||
*
|
||||
* Copyright 1994 Dietmar Friede
|
||||
*******************************************************************************
|
||||
@ -10,6 +10,9 @@ static char nic38_id[] = "@(#)$Id: nic3008.c,v 1.5 1995/05/11 19:25:55 rgrim
|
||||
*
|
||||
*******************************************************************************
|
||||
* $Log: nic3008.c,v $
|
||||
* Revision 1.6 1995/05/30 07:57:57 rgrimes
|
||||
* Remove trailing whitespace.
|
||||
*
|
||||
* Revision 1.5 1995/05/11 19:25:55 rgrimes
|
||||
* Fix -Wformat warnings from LINT kernel.
|
||||
*
|
||||
@ -548,7 +551,7 @@ reset_card(struct nic_softc * sc)
|
||||
* We forbid all but first open
|
||||
*/
|
||||
int
|
||||
nicopen(dev_t dev, int flag)
|
||||
nicopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
struct nic_softc *sc;
|
||||
u_char unit;
|
||||
@ -579,7 +582,7 @@ nicopen(dev_t dev, int flag)
|
||||
* nicclose() Close device
|
||||
*/
|
||||
int
|
||||
nicclose(dev_t dev, int flag)
|
||||
nicclose(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
struct nic_softc *sc = &nic_sc[minor(dev)];
|
||||
|
||||
@ -588,7 +591,7 @@ nicclose(dev_t dev, int flag)
|
||||
}
|
||||
|
||||
int
|
||||
nicioctl(dev_t dev, int cmd, caddr_t data, int flag)
|
||||
nicioctl(dev_t dev, int cmd, caddr_t data, int flags, struct proc *p)
|
||||
{
|
||||
int error;
|
||||
u_char unit;
|
||||
|
@ -1,6 +1,6 @@
|
||||
static char nic39_id[] = "@(#)$Id: nic3009.c,v 1.5 1995/03/28 07:54:33 bde Exp $";
|
||||
static char nic39_id[] = "@(#)$Id: nic3009.c,v 1.6 1995/05/11 19:25:56 rgrimes Exp $";
|
||||
/*******************************************************************************
|
||||
* II - Version 0.1 $Revision: 1.5 $ $State: Exp $
|
||||
* II - Version 0.1 $Revision: 1.6 $ $State: Exp $
|
||||
*
|
||||
* Copyright 1994 Dietmar Friede
|
||||
*******************************************************************************
|
||||
@ -10,6 +10,9 @@ static char nic39_id[] = "@(#)$Id: nic3009.c,v 1.5 1995/03/28 07:54:33 bde E
|
||||
*
|
||||
*******************************************************************************
|
||||
* $Log: nic3009.c,v $
|
||||
* Revision 1.6 1995/05/11 19:25:56 rgrimes
|
||||
* Fix -Wformat warnings from LINT kernel.
|
||||
*
|
||||
* Revision 1.5 1995/03/28 07:54:33 bde
|
||||
* Add and move declarations to fix all of the warnings from `gcc -Wimplicit'
|
||||
* (except in netccitt, netiso and netns) that I didn't notice when I fixed
|
||||
@ -498,7 +501,7 @@ nnic_accept(int cn, int an, int rea)
|
||||
}
|
||||
|
||||
int
|
||||
nnicopen(dev_t dev, int flag)
|
||||
nnicopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
struct nnic_softc *sc;
|
||||
u_char unit;
|
||||
@ -528,7 +531,7 @@ nnicopen(dev_t dev, int flag)
|
||||
}
|
||||
|
||||
int
|
||||
nnicclose(dev_t dev, int flag)
|
||||
nnicclose(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
struct nnic_softc *sc = &nnic_sc[minor(dev)];
|
||||
|
||||
@ -537,7 +540,7 @@ nnicclose(dev_t dev, int flag)
|
||||
}
|
||||
|
||||
int
|
||||
nnicioctl(dev_t dev, int cmd, caddr_t data, int flag)
|
||||
nnicioctl(dev_t dev, int cmd, caddr_t data, int flags, struct proc *pr)
|
||||
{
|
||||
int error;
|
||||
int i, x;
|
||||
|
@ -1,6 +1,6 @@
|
||||
static char _ispyid[] = "@(#)$Id: iispy.c,v 1.2 1995/02/15 06:28:27 jkh Exp $";
|
||||
static char _ispyid[] = "@(#)$Id: iispy.c,v 1.3 1995/03/28 07:54:40 bde Exp $";
|
||||
/*******************************************************************************
|
||||
* II - Version 0.1 $Revision: 1.2 $ $State: Exp $
|
||||
* II - Version 0.1 $Revision: 1.3 $ $State: Exp $
|
||||
*
|
||||
* Copyright 1994 Dietmar Friede
|
||||
*******************************************************************************
|
||||
@ -10,6 +10,11 @@ static char _ispyid[] = "@(#)$Id: iispy.c,v 1.2 1995/02/15 06:28:27 jkh Exp
|
||||
*
|
||||
*******************************************************************************
|
||||
* $Log: iispy.c,v $
|
||||
* Revision 1.3 1995/03/28 07:54:40 bde
|
||||
* Add and move declarations to fix all of the warnings from `gcc -Wimplicit'
|
||||
* (except in netccitt, netiso and netns) that I didn't notice when I fixed
|
||||
* "all" such warnings before.
|
||||
*
|
||||
* Revision 1.2 1995/02/15 06:28:27 jkh
|
||||
* Fix up include paths, nuke some warnings.
|
||||
*
|
||||
@ -104,7 +109,7 @@ ispy_input(int no, int len, char *buf, int out)
|
||||
}
|
||||
|
||||
int
|
||||
ispyopen(dev_t dev, int flag)
|
||||
ispyopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int err;
|
||||
struct ispy_data *ispy;
|
||||
@ -121,7 +126,7 @@ ispyopen(dev_t dev, int flag)
|
||||
}
|
||||
|
||||
int
|
||||
ispyclose(dev_t dev, int flag)
|
||||
ispyclose(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
struct ispy_data *ispy= &ispy_data[minor(dev)];
|
||||
|
||||
@ -132,10 +137,7 @@ ispyclose(dev_t dev, int flag)
|
||||
}
|
||||
|
||||
int
|
||||
ispyioctl (dev, cmd, data, flag)
|
||||
dev_t dev;
|
||||
caddr_t data;
|
||||
int cmd, flag;
|
||||
ispyioctl (dev_t dev, int cmd, caddr_t data, int flags, struct proc *p)
|
||||
{
|
||||
int unit = minor(dev);
|
||||
|
||||
@ -147,7 +149,7 @@ int cmd, flag;
|
||||
}
|
||||
|
||||
int
|
||||
ispyread(dev_t dev, struct uio * uio)
|
||||
ispyread(dev_t dev, struct uio * uio, int ioflag)
|
||||
{
|
||||
int x;
|
||||
int error = 0;
|
||||
|
@ -1,6 +1,6 @@
|
||||
static char _itelid[] = "@(#)$Id: iitel.c,v 1.3 1995/03/28 07:54:41 bde Exp $";
|
||||
static char _itelid[] = "@(#)$Id: iitel.c,v 1.4 1995/07/16 10:11:10 bde Exp $";
|
||||
/*******************************************************************************
|
||||
* II - Version 0.1 $Revision: 1.3 $ $State: Exp $
|
||||
* II - Version 0.1 $Revision: 1.4 $ $State: Exp $
|
||||
*
|
||||
* Copyright 1994 Dietmar Friede
|
||||
*******************************************************************************
|
||||
@ -10,6 +10,10 @@ static char _itelid[] = "@(#)$Id: iitel.c,v 1.3 1995/03/28 07:54:41 bde Exp
|
||||
*
|
||||
*******************************************************************************
|
||||
* $Log: iitel.c,v $
|
||||
* Revision 1.4 1995/07/16 10:11:10 bde
|
||||
* Don't include <sys/tty.h> in drivers that aren't tty drivers or in general
|
||||
* files that don't depend on the internals of <sys/tty.h>
|
||||
*
|
||||
* Revision 1.3 1995/03/28 07:54:41 bde
|
||||
* Add and move declarations to fix all of the warnings from `gcc -Wimplicit'
|
||||
* (except in netccitt, netiso and netns) that I didn't notice when I fixed
|
||||
@ -139,7 +143,7 @@ itel_disconnect(int no)
|
||||
}
|
||||
|
||||
int
|
||||
itelopen(dev_t dev, int flag)
|
||||
itelopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int err;
|
||||
struct itel_data *itel;
|
||||
@ -159,7 +163,7 @@ itelopen(dev_t dev, int flag)
|
||||
}
|
||||
|
||||
int
|
||||
itelclose(dev_t dev, int flag)
|
||||
itelclose(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
struct itel_data *itel= &itel_data[minor(dev)];
|
||||
|
||||
@ -172,10 +176,7 @@ itelclose(dev_t dev, int flag)
|
||||
}
|
||||
|
||||
int
|
||||
itelioctl (dev, cmd, data, flag)
|
||||
dev_t dev;
|
||||
caddr_t data;
|
||||
int cmd, flag;
|
||||
itelioctl (dev_t dev, int cmd, caddr_t data, int flags, struct proc *p)
|
||||
{
|
||||
int unit = minor(dev);
|
||||
|
||||
@ -187,7 +188,7 @@ int cmd, flag;
|
||||
}
|
||||
|
||||
int
|
||||
itelread(dev_t dev, struct uio * uio)
|
||||
itelread(dev_t dev, struct uio * uio, int ioflag)
|
||||
{
|
||||
int x;
|
||||
int error = 0;
|
||||
@ -213,7 +214,7 @@ itelread(dev_t dev, struct uio * uio)
|
||||
}
|
||||
|
||||
int
|
||||
itelwrite(dev_t dev, struct uio * uio)
|
||||
itelwrite(dev_t dev, struct uio * uio, int ioflag)
|
||||
{
|
||||
int x;
|
||||
int error = 0;
|
||||
|
@ -1,6 +1,6 @@
|
||||
static char _isdnid[] = "@(#)$Id: isdn.c,v 1.3 1995/03/28 07:54:44 bde Exp $";
|
||||
static char _isdnid[] = "@(#)$Id: isdn.c,v 1.4 1995/05/30 07:58:02 rgrimes Exp $";
|
||||
/*******************************************************************************
|
||||
* II - Version 0.1 $Revision: 1.3 $ $State: Exp $
|
||||
* II - Version 0.1 $Revision: 1.4 $ $State: Exp $
|
||||
*
|
||||
* Copyright 1994 Dietmar Friede
|
||||
*******************************************************************************
|
||||
@ -10,6 +10,9 @@ static char _isdnid[] = "@(#)$Id: isdn.c,v 1.3 1995/03/28 07:54:44 bde Exp $
|
||||
*
|
||||
*******************************************************************************
|
||||
* $Log: isdn.c,v $
|
||||
* Revision 1.4 1995/05/30 07:58:02 rgrimes
|
||||
* Remove trailing whitespace.
|
||||
*
|
||||
* Revision 1.3 1995/03/28 07:54:44 bde
|
||||
* Add and move declarations to fix all of the warnings from `gcc -Wimplicit'
|
||||
* (except in netccitt, netiso and netns) that I didn't notice when I fixed
|
||||
@ -197,7 +200,7 @@ isdn_ctrl_attach(int n)
|
||||
* isdn device are the ISDN-daemon
|
||||
*/
|
||||
int
|
||||
isdnopen(dev_t dev, int flag)
|
||||
isdnopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int err;
|
||||
|
||||
@ -214,14 +217,14 @@ isdnopen(dev_t dev, int flag)
|
||||
}
|
||||
|
||||
int
|
||||
isdnclose(dev_t dev, int flag)
|
||||
isdnclose(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
o_flags &= ~(1 << minor(dev));
|
||||
return (0);
|
||||
}
|
||||
|
||||
int
|
||||
isdnread(dev_t dev, struct uio * uio)
|
||||
isdnread(dev_t dev, struct uio * uio, int ioflag)
|
||||
{
|
||||
int x;
|
||||
int error = 0;
|
||||
@ -246,7 +249,7 @@ isdnread(dev_t dev, struct uio * uio)
|
||||
}
|
||||
|
||||
int
|
||||
isdnioctl(dev_t dev, int cmd, caddr_t data, int flag)
|
||||
isdnioctl(dev_t dev, int cmd, caddr_t data, int flags, struct proc *p)
|
||||
{
|
||||
int err, x, i;
|
||||
isdn_appl_t *appl;
|
||||
|
@ -38,7 +38,7 @@
|
||||
*
|
||||
* from: Utah $Hdr: mem.c 1.13 89/10/08$
|
||||
* from: @(#)mem.c 7.2 (Berkeley) 5/9/91
|
||||
* $Id: mem.c,v 1.9 1994/08/06 10:25:34 davidg Exp $
|
||||
* $Id: mem.c,v 1.10 1995/09/03 05:43:04 julian Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -85,10 +85,11 @@ SYSINIT(memdev,SI_SUB_DEVFS, SI_ORDER_ANY, memdev_init, NULL)
|
||||
extern char *ptvmmap; /* poor name! */
|
||||
/*ARGSUSED*/
|
||||
int
|
||||
mmclose(dev, uio, flags)
|
||||
mmclose(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
struct uio *uio;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
struct trapframe *fp;
|
||||
|
||||
@ -104,10 +105,11 @@ mmclose(dev, uio, flags)
|
||||
}
|
||||
/*ARGSUSED*/
|
||||
int
|
||||
mmopen(dev, uio, flags)
|
||||
mmopen(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
struct uio *uio;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
struct trapframe *fp;
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
* of this software, nor does the author assume any responsibility
|
||||
* for damages incurred with its use.
|
||||
*
|
||||
* $Id: ctx.c,v 1.5 1995/04/12 20:47:40 wollman Exp $
|
||||
* $Id: ctx.c,v 1.6 1995/05/30 08:01:27 rgrimes Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -206,7 +206,7 @@ ctxattach(struct isa_device * devp)
|
||||
}
|
||||
|
||||
int
|
||||
ctxopen(dev_t dev, int flag)
|
||||
ctxopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
struct ctx_soft_registers *sr;
|
||||
u_char unit;
|
||||
@ -262,7 +262,7 @@ ctxopen(dev_t dev, int flag)
|
||||
}
|
||||
|
||||
int
|
||||
ctxclose(dev_t dev, int flag)
|
||||
ctxclose(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int unit;
|
||||
|
||||
@ -275,7 +275,7 @@ ctxclose(dev_t dev, int flag)
|
||||
}
|
||||
|
||||
int
|
||||
ctxwrite(dev_t dev, struct uio * uio)
|
||||
ctxwrite(dev_t dev, struct uio * uio, int ioflag)
|
||||
{
|
||||
int unit, status = 0;
|
||||
int page, count, offset;
|
||||
@ -320,7 +320,7 @@ ctxwrite(dev_t dev, struct uio * uio)
|
||||
}
|
||||
|
||||
int
|
||||
ctxread(dev_t dev, struct uio * uio)
|
||||
ctxread(dev_t dev, struct uio * uio, int ioflag)
|
||||
{
|
||||
int unit, status = 0;
|
||||
int page, count, offset;
|
||||
@ -363,7 +363,7 @@ ctxread(dev_t dev, struct uio * uio)
|
||||
}
|
||||
|
||||
int
|
||||
ctxioctl(dev_t dev, int cmd, caddr_t data, int flag)
|
||||
ctxioctl(dev_t dev, int cmd, caddr_t data, int flags, struct proc *p)
|
||||
{
|
||||
int error;
|
||||
int unit, i;
|
||||
|
@ -138,9 +138,11 @@ gpattach(isdp)
|
||||
* i.e. even if gpib5 is open, we can't open another minor device
|
||||
*/
|
||||
int
|
||||
gpopen(dev, flag)
|
||||
gpopen(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
int flag;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
struct gpib_softc *sc = &gpib_sc;
|
||||
int delay; /* slept time in 1/hz seconds of tsleep */
|
||||
@ -217,10 +219,11 @@ enableremote(unit);
|
||||
* Close gpib device.
|
||||
*/
|
||||
int
|
||||
gpclose(dev, flag)
|
||||
gpclose(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
int flag;
|
||||
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
struct gpib_softc *sc = &gpib_sc;
|
||||
unsigned char unit;
|
||||
@ -319,9 +322,10 @@ while (!(inb(ISR1)&2)&&(status==EWOULDBLOCK));
|
||||
* by minor(dev).
|
||||
*/
|
||||
int
|
||||
gpwrite(dev, uio)
|
||||
gpwrite(dev, uio, ioflag)
|
||||
dev_t dev;
|
||||
struct uio *uio;
|
||||
int ioflag;
|
||||
{
|
||||
int err,count;
|
||||
|
||||
@ -371,8 +375,9 @@ gpwrite(dev, uio)
|
||||
write to using a minor device = its GPIB address */
|
||||
|
||||
int
|
||||
gpioctl(dev_t dev, int cmd, struct gpibdata *gd)
|
||||
gpioctl(dev_t dev, int cmd, caddr_t data, int flags, struct proc *p)
|
||||
{
|
||||
struct gpibdata *gd = (struct gpibdata *)data;
|
||||
int error,result;
|
||||
error = 0;
|
||||
|
||||
|
@ -511,7 +511,7 @@ gscattach(struct isa_device *isdp)
|
||||
* don't switch scanner on, wait until first read ioctls go before
|
||||
*/
|
||||
|
||||
int gscopen (dev_t dev, int flag)
|
||||
int gscopen (dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int unit = UNIT(minor(dev)) & UNIT_MASK;
|
||||
struct gsc_unit *scu = unittab + unit;
|
||||
@ -564,7 +564,7 @@ int gscopen (dev_t dev, int flag)
|
||||
* release the buffer
|
||||
*/
|
||||
|
||||
int gscclose (dev_t dev, int flag)
|
||||
int gscclose (dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int unit = UNIT(minor(dev));
|
||||
struct gsc_unit *scu = unittab + unit;
|
||||
@ -597,7 +597,7 @@ int gscclose (dev_t dev, int flag)
|
||||
* gscread
|
||||
*/
|
||||
|
||||
int gscread (dev_t dev, struct uio *uio)
|
||||
int gscread (dev_t dev, struct uio *uio, int ioflag)
|
||||
{
|
||||
int unit = UNIT(minor(dev));
|
||||
struct gsc_unit *scu = unittab + unit;
|
||||
|
@ -46,7 +46,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* from: unknown origin, 386BSD 0.1
|
||||
* $Id: lpt.c,v 1.32 1995/06/22 07:03:20 davidg Exp $
|
||||
* $Id: lpt.c,v 1.33 1995/07/16 10:12:04 bde Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -442,7 +442,7 @@ lptattach(struct isa_device *isdp)
|
||||
*/
|
||||
|
||||
int
|
||||
lptopen (dev_t dev, int flag)
|
||||
lptopen (dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
struct lpt_softc *sc;
|
||||
int s;
|
||||
@ -576,7 +576,7 @@ lptout (struct lpt_softc * sc)
|
||||
*/
|
||||
|
||||
int
|
||||
lptclose(dev_t dev, int flag)
|
||||
lptclose(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
struct lpt_softc *sc = lpt_sc + LPTUNIT(minor(dev));
|
||||
int port = sc->sc_port;
|
||||
@ -675,7 +675,7 @@ pushbytes(struct lpt_softc * sc)
|
||||
*/
|
||||
|
||||
int
|
||||
lptwrite(dev_t dev, struct uio * uio)
|
||||
lptwrite(dev_t dev, struct uio * uio, int ioflag)
|
||||
{
|
||||
register unsigned n;
|
||||
int pl, err;
|
||||
@ -773,7 +773,7 @@ lptintr(int unit)
|
||||
}
|
||||
|
||||
int
|
||||
lptioctl(dev_t dev, int cmd, caddr_t data, int flag)
|
||||
lptioctl(dev_t dev, int cmd, caddr_t data, int flags, struct proc *p)
|
||||
{
|
||||
int error = 0;
|
||||
struct lpt_softc *sc;
|
||||
|
@ -477,10 +477,10 @@ static struct kern_devconf kdc_matcd[TOTALDRIVES] = { { /*<12>*/
|
||||
Entry points and other connections to/from kernel - see conf.c
|
||||
---------------------------------------------------------------------------*/
|
||||
|
||||
int matcdopen(dev_t dev);
|
||||
int matcdclose(dev_t dev);
|
||||
int matcdopen(dev_t dev, int flags, int fmt, struct proc *p);
|
||||
int matcdclose(dev_t dev, int flags, int fmt, struct proc *p);
|
||||
void matcdstrategy(struct buf *bp);
|
||||
int matcdioctl(dev_t dev, int command, caddr_t addr, int flags);
|
||||
int matcdioctl(dev_t dev, int command, caddr_t addr, int flags, struct proc *p);
|
||||
int matcdsize(dev_t dev);
|
||||
extern int hz;
|
||||
extern int matcd_probe(struct isa_device *dev);
|
||||
@ -558,7 +558,7 @@ static int docmd(char * cmd, int ldrive, int cdrive, /*<14>*/
|
||||
<15> If LOCKDRIVE is enabled, additional minor number devices allow
|
||||
<15> the drive to be locked while being accessed.
|
||||
---------------------------------------------------------------------------*/
|
||||
int matcdopen(dev_t dev)
|
||||
int matcdopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int cdrive,ldrive,partition,controller;
|
||||
struct matcd_data *cd;
|
||||
@ -751,7 +751,7 @@ int matcdopen(dev_t dev)
|
||||
<15> the drive.
|
||||
---------------------------------------------------------------------------*/
|
||||
|
||||
int matcdclose(dev_t dev)
|
||||
int matcdclose(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int ldrive,cdrive,port,partition,controller;
|
||||
struct matcd_data *cd;
|
||||
@ -960,7 +960,7 @@ static void matcd_start(struct buf *dp)
|
||||
things that don't fit into the block read scheme of things.
|
||||
---------------------------------------------------------------------------*/
|
||||
|
||||
int matcdioctl(dev_t dev, int command, caddr_t addr, int flags)
|
||||
int matcdioctl(dev_t dev, int command, caddr_t addr, int flags, struct proc *p)
|
||||
{
|
||||
struct matcd_data *cd;
|
||||
int ldrive,cdrive,partition;
|
||||
|
@ -40,7 +40,7 @@
|
||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* $Id: mcd.c,v 1.44 1995/05/30 08:02:44 rgrimes Exp $
|
||||
* $Id: mcd.c,v 1.45 1995/08/15 19:56:59 joerg Exp $
|
||||
*/
|
||||
static char COPYRIGHT[] = "mcd-driver (C)1993 by H.Veit & B.Moore";
|
||||
|
||||
@ -164,10 +164,10 @@ struct mcd_data {
|
||||
#define MCD_S_WAITREAD 4
|
||||
|
||||
/* prototypes */
|
||||
int mcdopen(dev_t dev);
|
||||
int mcdclose(dev_t dev);
|
||||
int mcdopen(dev_t dev, int flags, int fmt, struct proc *p);
|
||||
int mcdclose(dev_t dev, int flags, int fmt, struct proc *p);
|
||||
void mcdstrategy(struct buf *bp);
|
||||
int mcdioctl(dev_t dev, int cmd, caddr_t addr, int flags);
|
||||
int mcdioctl(dev_t dev, int cmd, caddr_t addr, int flags, struct proc *p);
|
||||
int mcdsize(dev_t dev);
|
||||
static void mcd_done(struct mcd_mbx *mbx);
|
||||
static void mcd_start(int unit);
|
||||
@ -265,7 +265,7 @@ int mcd_attach(struct isa_device *dev)
|
||||
return 1;
|
||||
}
|
||||
|
||||
int mcdopen(dev_t dev)
|
||||
int mcdopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int unit,part,phys,r,retry;
|
||||
struct mcd_data *cd;
|
||||
@ -341,7 +341,7 @@ MCD_TRACE("open: partition=%d, disksize = %ld, blksize=%d\n",
|
||||
return ENXIO;
|
||||
}
|
||||
|
||||
int mcdclose(dev_t dev)
|
||||
int mcdclose(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int unit,part,phys;
|
||||
struct mcd_data *cd;
|
||||
@ -491,7 +491,7 @@ static void mcd_start(int unit)
|
||||
return;
|
||||
}
|
||||
|
||||
int mcdioctl(dev_t dev, int cmd, caddr_t addr, int flags)
|
||||
int mcdioctl(dev_t dev, int cmd, caddr_t addr, int flags, struct proc *p)
|
||||
{
|
||||
struct mcd_data *cd;
|
||||
int unit,part;
|
||||
|
@ -11,7 +11,7 @@
|
||||
* this software for any purpose. It is provided "as is"
|
||||
* without express or implied warranty.
|
||||
*
|
||||
* $Id: mse.c,v 1.12 1995/05/30 08:02:47 rgrimes Exp $
|
||||
* $Id: mse.c,v 1.13 1995/07/16 10:12:06 bde Exp $
|
||||
*/
|
||||
/*
|
||||
* Driver for the Logitech and ATI Inport Bus mice for use with 386bsd and
|
||||
@ -241,9 +241,11 @@ mseattach(idp)
|
||||
* Exclusive open the mouse, initialize it and enable interrupts.
|
||||
*/
|
||||
int
|
||||
mseopen(dev, flag)
|
||||
mseopen(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
int flag;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
register struct mse_softc *sc;
|
||||
int s;
|
||||
@ -272,9 +274,11 @@ mseopen(dev, flag)
|
||||
* mseclose: just turn off mouse innterrupts.
|
||||
*/
|
||||
int
|
||||
mseclose(dev, flag)
|
||||
mseclose(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
int flag;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
struct mse_softc *sc = &mse_sc[MSE_UNIT(dev)];
|
||||
int s;
|
||||
@ -293,9 +297,10 @@ mseclose(dev, flag)
|
||||
* (Yes this is cheesy, but it makes the X386 server happy, so...)
|
||||
*/
|
||||
int
|
||||
mseread(dev, uio)
|
||||
mseread(dev, uio, ioflag)
|
||||
dev_t dev;
|
||||
struct uio *uio;
|
||||
int ioflag;
|
||||
{
|
||||
register struct mse_softc *sc = &mse_sc[MSE_UNIT(dev)];
|
||||
int xfer, s, error;
|
||||
|
@ -25,7 +25,7 @@
|
||||
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
|
||||
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* $Id: pcaudio.c,v 1.13 1995/05/30 08:02:55 rgrimes Exp $
|
||||
* $Id: pcaudio.c,v 1.14 1995/09/03 05:43:30 julian Exp $
|
||||
*/
|
||||
|
||||
#include "pca.h"
|
||||
@ -81,8 +81,8 @@ static int pca_initialized = 0;
|
||||
void pcaintr(struct clockframe *frame);
|
||||
int pcaprobe(struct isa_device *dvp);
|
||||
int pcaattach(struct isa_device *dvp);
|
||||
int pcaclose(dev_t dev, int flag);
|
||||
int pcaopen(dev_t dev, int flag);
|
||||
int pcaclose(dev_t dev, int flags, int fmt, struct proc *p);
|
||||
int pcaopen(dev_t dev, int flags, int fmt, struct proc *p);
|
||||
int pcawrite(dev_t dev, struct uio *uio, int flag);
|
||||
int pcaioctl(dev_t dev, int cmd, caddr_t data, int flag, struct proc *p);
|
||||
int pcaselect(dev_t dev, int rw, struct proc *p);
|
||||
@ -272,7 +272,7 @@ pcaattach(struct isa_device *dvp)
|
||||
|
||||
|
||||
int
|
||||
pcaopen(dev_t dev, int flag)
|
||||
pcaopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
/* audioctl device can always be opened */
|
||||
if (minor(dev) == 128)
|
||||
@ -300,7 +300,7 @@ pcaopen(dev_t dev, int flag)
|
||||
|
||||
|
||||
int
|
||||
pcaclose(dev_t dev, int flag)
|
||||
pcaclose(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
/* audioctl device can always be closed */
|
||||
if (minor(dev) == 128)
|
||||
|
@ -41,7 +41,7 @@
|
||||
*/
|
||||
|
||||
|
||||
/* $Id: scd.c,v 1.4 1995/05/09 12:25:58 rgrimes Exp $ */
|
||||
/* $Id: scd.c,v 1.5 1995/05/30 08:03:02 rgrimes Exp $ */
|
||||
|
||||
/* Please send any comments to micke@dynas.se */
|
||||
|
||||
@ -142,10 +142,10 @@ struct scd_data {
|
||||
} scd_data[NSCD];
|
||||
|
||||
/* prototypes */
|
||||
int scdopen(dev_t dev);
|
||||
int scdclose(dev_t dev);
|
||||
int scdopen(dev_t dev, int flags, int fmt, struct proc *p);
|
||||
int scdclose(dev_t dev, int flags, int fmt, struct proc *p);
|
||||
void scdstrategy(struct buf *bp);
|
||||
int scdioctl(dev_t dev, int cmd, caddr_t addr, int flags);
|
||||
int scdioctl(dev_t dev, int cmd, caddr_t addr, int flags, struct proc *p);
|
||||
int scdsize(dev_t dev);
|
||||
|
||||
static int bcd2bin(bcd_t b);
|
||||
@ -230,7 +230,7 @@ int scd_attach(struct isa_device *dev)
|
||||
}
|
||||
|
||||
int
|
||||
scdopen(dev_t dev)
|
||||
scdopen(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int unit,part,phys;
|
||||
int rc;
|
||||
@ -283,7 +283,7 @@ scdopen(dev_t dev)
|
||||
}
|
||||
|
||||
int
|
||||
scdclose(dev_t dev)
|
||||
scdclose(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int unit,part,phys;
|
||||
struct scd_data *cd;
|
||||
@ -419,7 +419,7 @@ scd_start(int unit)
|
||||
}
|
||||
|
||||
int
|
||||
scdioctl(dev_t dev, int cmd, caddr_t addr, int flags)
|
||||
scdioctl(dev_t dev, int cmd, caddr_t addr, int flags, struct proc *p)
|
||||
{
|
||||
struct scd_data *cd;
|
||||
int unit,part;
|
||||
|
@ -156,7 +156,7 @@ struct spigot_softc *ss=(struct spigot_softc *)&spigot_softc[devp->id_unit];
|
||||
}
|
||||
|
||||
int
|
||||
spigot_open(dev_t dev, int flag)
|
||||
spigot_open(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
struct spigot_softc *ss = (struct spigot_softc *)&spigot_softc[UNIT(dev)];
|
||||
|
||||
@ -174,7 +174,7 @@ struct spigot_softc *ss = (struct spigot_softc *)&spigot_softc[UNIT(dev)];
|
||||
}
|
||||
|
||||
int
|
||||
spigot_close(dev_t dev, int flag)
|
||||
spigot_close(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
struct spigot_softc *ss = (struct spigot_softc *)&spigot_softc[UNIT(dev)];
|
||||
|
||||
|
@ -4,7 +4,7 @@
|
||||
* v1.4 by Eric S. Raymond (esr@snark.thyrsus.com) Aug 1993
|
||||
* modified for FreeBSD by Andrew A. Chernov <ache@astral.msk.su>
|
||||
*
|
||||
* $Id: spkr.c,v 1.14 1995/05/30 08:03:09 rgrimes Exp $
|
||||
* $Id: spkr.c,v 1.15 1995/09/03 05:43:31 julian Exp $
|
||||
*/
|
||||
|
||||
#include "speaker.h"
|
||||
@ -451,8 +451,11 @@ size_t slen;
|
||||
static int spkr_active = FALSE; /* exclusion flag */
|
||||
static struct buf *spkr_inbuf; /* incoming buf */
|
||||
|
||||
int spkropen(dev)
|
||||
dev_t dev;
|
||||
int spkropen(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
#ifdef DEBUG
|
||||
(void) printf("spkropen: entering with dev = %x\n", dev);
|
||||
@ -474,9 +477,10 @@ dev_t dev;
|
||||
}
|
||||
}
|
||||
|
||||
int spkrwrite(dev, uio)
|
||||
int spkrwrite(dev, uio, ioflag)
|
||||
dev_t dev;
|
||||
struct uio *uio;
|
||||
int ioflag;
|
||||
{
|
||||
#ifdef DEBUG
|
||||
printf("spkrwrite: entering with dev = %x, count = %d\n",
|
||||
@ -501,8 +505,11 @@ struct uio *uio;
|
||||
}
|
||||
}
|
||||
|
||||
int spkrclose(dev)
|
||||
dev_t dev;
|
||||
int spkrclose(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
#ifdef DEBUG
|
||||
(void) printf("spkrclose: entering with dev = %x\n", dev);
|
||||
@ -520,10 +527,12 @@ dev_t dev;
|
||||
}
|
||||
}
|
||||
|
||||
int spkrioctl(dev, cmd, cmdarg)
|
||||
dev_t dev;
|
||||
int cmd;
|
||||
caddr_t cmdarg;
|
||||
int spkrioctl(dev, cmd, cmdarg, flags, p)
|
||||
dev_t dev;
|
||||
int cmd;
|
||||
caddr_t cmdarg;
|
||||
int flags;
|
||||
struct proc *p;
|
||||
{
|
||||
#ifdef DEBUG
|
||||
(void) printf("spkrioctl: entering with dev = %x, cmd = %x\n");
|
||||
|
@ -383,9 +383,10 @@ int twclose(dev, flag, mode, p)
|
||||
return(0);
|
||||
}
|
||||
|
||||
int twread(dev, uio)
|
||||
int twread(dev, uio, ioflag)
|
||||
dev_t dev;
|
||||
struct uio *uio;
|
||||
int ioflag;
|
||||
{
|
||||
u_char buf[3];
|
||||
struct tw_sc *sc = &tw_sc[TWUNIT(dev)];
|
||||
@ -400,9 +401,10 @@ int twread(dev, uio)
|
||||
return(error);
|
||||
}
|
||||
|
||||
int twwrite(dev, uio)
|
||||
int twwrite(dev, uio, ioflag)
|
||||
dev_t dev;
|
||||
struct uio *uio;
|
||||
int ioflag;
|
||||
{
|
||||
struct tw_sc *sc;
|
||||
int house, key, reps;
|
||||
|
@ -19,7 +19,7 @@
|
||||
* the original CMU copyright notice.
|
||||
*
|
||||
* Version 1.3, Thu Nov 11 12:09:13 MSK 1993
|
||||
* $Id: wt.c,v 1.17 1995/05/30 08:03:22 rgrimes Exp $
|
||||
* $Id: wt.c,v 1.18 1995/09/05 05:45:34 julian Exp $
|
||||
*
|
||||
*/
|
||||
|
||||
@ -264,13 +264,13 @@ int wtattach (struct isa_device *id)
|
||||
|
||||
struct isa_driver wtdriver = { wtprobe, wtattach, "wt", };
|
||||
|
||||
int wtdump (int dev)
|
||||
int wtdump (dev_t dev)
|
||||
{
|
||||
/* Not implemented */
|
||||
return (EINVAL);
|
||||
}
|
||||
|
||||
int wtsize (int dev)
|
||||
int wtsize (dev_t dev)
|
||||
{
|
||||
/* Not implemented */
|
||||
return (-1);
|
||||
@ -279,7 +279,7 @@ int wtsize (int dev)
|
||||
/*
|
||||
* Open routine, called on every device open.
|
||||
*/
|
||||
int wtopen (int dev, int flag)
|
||||
int wtopen (dev_t dev, int flag, int fmt, struct proc *p)
|
||||
{
|
||||
int u = minor (dev) & T_UNIT;
|
||||
wtinfo_t *t = wttab + u;
|
||||
@ -357,7 +357,7 @@ int wtopen (int dev, int flag)
|
||||
/*
|
||||
* Close routine, called on last device close.
|
||||
*/
|
||||
int wtclose (int dev)
|
||||
int wtclose (dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
int u = minor (dev) & T_UNIT;
|
||||
wtinfo_t *t = wttab + u;
|
||||
@ -407,7 +407,7 @@ done:
|
||||
* ioctl (int fd, MTIOCTOP, struct mtop *buf) -- do BSD-like op
|
||||
* ioctl (int fd, WTQICMD, int qicop) -- do QIC op
|
||||
*/
|
||||
int wtioctl (int dev, int cmd, void *arg, int mode)
|
||||
int wtioctl (dev_t dev, int cmd, caddr_t arg, int flags, struct proc *p)
|
||||
{
|
||||
int u = minor (dev) & T_UNIT;
|
||||
wtinfo_t *t = wttab + u;
|
||||
|
@ -30,7 +30,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $Id: kern_lkm.c,v 1.13 1995/05/30 08:05:30 rgrimes Exp $
|
||||
* $Id: kern_lkm.c,v 1.14 1995/08/25 20:03:02 bde Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -174,11 +174,12 @@ lkmcclose(dev, flag, mode, p)
|
||||
|
||||
/*ARGSUSED*/
|
||||
int
|
||||
lkmcioctl(dev, cmd, data, flag)
|
||||
lkmcioctl(dev, cmd, data, flag, p)
|
||||
dev_t dev;
|
||||
int cmd;
|
||||
caddr_t data;
|
||||
int flag;
|
||||
struct proc *p;
|
||||
{
|
||||
int err = 0;
|
||||
int i;
|
||||
@ -481,7 +482,11 @@ lkmnosys(p, args, retval)
|
||||
* Place holder for device switch slots reserved for loadable modules.
|
||||
*/
|
||||
int
|
||||
lkmenodev()
|
||||
lkmenodev(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
|
||||
return(enodev());
|
||||
|
@ -16,7 +16,7 @@
|
||||
* 4. Modifications may be freely made to this file if the above conditions
|
||||
* are met.
|
||||
*
|
||||
* $Id: kern_physio.c,v 1.10 1995/03/16 18:12:34 bde Exp $
|
||||
* $Id: kern_physio.c,v 1.11 1995/05/30 08:05:36 rgrimes Exp $
|
||||
*/
|
||||
|
||||
#include <sys/param.h>
|
||||
@ -165,14 +165,14 @@ minphys(struct buf *bp)
|
||||
}
|
||||
|
||||
int
|
||||
rawread(dev_t dev, struct uio *uio)
|
||||
rawread(dev_t dev, struct uio *uio, int ioflag)
|
||||
{
|
||||
return (physio(cdevsw[major(dev)].d_strategy, (struct buf *)NULL,
|
||||
dev, 1, minphys, uio));
|
||||
}
|
||||
|
||||
int
|
||||
rawwrite(dev_t dev, struct uio *uio)
|
||||
rawwrite(dev_t dev, struct uio *uio, int ioflag)
|
||||
{
|
||||
return (physio(cdevsw[major(dev)].d_strategy, (struct buf *)NULL,
|
||||
dev, 0, minphys, uio));
|
||||
|
@ -31,7 +31,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)tty_pty.c 8.2 (Berkeley) 9/23/93
|
||||
* $Id: tty_pty.c,v 1.17 1995/08/02 02:55:47 bde Exp $
|
||||
* $Id: tty_pty.c,v 1.19 1995/08/02 11:26:50 ache Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -296,8 +296,11 @@ ptcopen(dev, flag, devtype, p)
|
||||
}
|
||||
|
||||
int
|
||||
ptcclose(dev)
|
||||
ptcclose(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
register struct tty *tp;
|
||||
|
||||
|
@ -339,9 +339,11 @@ detach_notty:
|
||||
}
|
||||
|
||||
int
|
||||
snpclose(dev, flag)
|
||||
snpclose(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
int flag;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
register int unit = minor(dev);
|
||||
struct snoop *snp = &snoopsw[unit];
|
||||
@ -367,11 +369,12 @@ snpdown(snp)
|
||||
|
||||
|
||||
int
|
||||
snpioctl(dev, cmd, data, flag)
|
||||
snpioctl(dev, cmd, data, flags, p)
|
||||
dev_t dev;
|
||||
int cmd;
|
||||
caddr_t data;
|
||||
int flag;
|
||||
int flags;
|
||||
struct proc *p;
|
||||
{
|
||||
int unit = minor(dev), s;
|
||||
dev_t tdev;
|
||||
|
@ -37,7 +37,7 @@
|
||||
*
|
||||
* @(#)bpf.c 8.2 (Berkeley) 3/28/94
|
||||
*
|
||||
* $Id: bpf.c,v 1.9 1995/07/16 10:13:08 bde Exp $
|
||||
* $Id: bpf.c,v 1.10 1995/07/31 10:35:36 peter Exp $
|
||||
*/
|
||||
|
||||
#include "bpfilter.h"
|
||||
@ -308,9 +308,11 @@ bpf_detachd(d)
|
||||
*/
|
||||
/* ARGSUSED */
|
||||
int
|
||||
bpfopen(dev, flag)
|
||||
bpfopen(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
int flag;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
register struct bpf_d *d;
|
||||
|
||||
@ -338,9 +340,11 @@ bpfopen(dev, flag)
|
||||
*/
|
||||
/* ARGSUSED */
|
||||
int
|
||||
bpfclose(dev, flag)
|
||||
bpfclose(dev, flags, fmt, p)
|
||||
dev_t dev;
|
||||
int flag;
|
||||
int flags;
|
||||
int fmt;
|
||||
struct proc *p;
|
||||
{
|
||||
register struct bpf_d *d = &bpf_dtab[minor(dev)];
|
||||
register int s;
|
||||
@ -408,9 +412,10 @@ bpf_sleep(d)
|
||||
* bpfread - read next chunk of packets from buffers
|
||||
*/
|
||||
int
|
||||
bpfread(dev, uio)
|
||||
bpfread(dev, uio, ioflag)
|
||||
dev_t dev;
|
||||
register struct uio *uio;
|
||||
int ioflag;
|
||||
{
|
||||
register struct bpf_d *d = &bpf_dtab[minor(dev)];
|
||||
int error;
|
||||
@ -522,9 +527,10 @@ bpf_wakeup(d)
|
||||
}
|
||||
|
||||
int
|
||||
bpfwrite(dev, uio)
|
||||
bpfwrite(dev, uio, ioflag)
|
||||
dev_t dev;
|
||||
struct uio *uio;
|
||||
int ioflag;
|
||||
{
|
||||
register struct bpf_d *d = &bpf_dtab[minor(dev)];
|
||||
struct ifnet *ifp;
|
||||
@ -598,11 +604,12 @@ reset_d(d)
|
||||
*/
|
||||
/* ARGSUSED */
|
||||
int
|
||||
bpfioctl(dev, cmd, addr, flag)
|
||||
bpfioctl(dev, cmd, addr, flags, p)
|
||||
dev_t dev;
|
||||
int cmd;
|
||||
caddr_t addr;
|
||||
int flag;
|
||||
int flags;
|
||||
struct proc *p;
|
||||
{
|
||||
register struct bpf_d *d = &bpf_dtab[minor(dev)];
|
||||
int s, error = 0;
|
||||
|
@ -37,7 +37,7 @@
|
||||
*
|
||||
* @(#)bpf.h 8.1 (Berkeley) 6/10/93
|
||||
*
|
||||
* $Id: bpf.h,v 1.4 1995/05/30 08:07:52 rgrimes Exp $
|
||||
* $Id: bpf.h,v 1.5 1995/06/15 18:10:59 pst Exp $
|
||||
*/
|
||||
|
||||
#ifndef _NET_BPF_H_
|
||||
@ -239,11 +239,11 @@ struct bpf_insn {
|
||||
|
||||
#ifdef KERNEL
|
||||
int bpf_validate __P((struct bpf_insn *, int));
|
||||
int bpfopen __P((dev_t, int));
|
||||
int bpfclose __P((dev_t, int));
|
||||
int bpfread __P((dev_t, struct uio *));
|
||||
int bpfwrite __P((dev_t, struct uio *));
|
||||
int bpfioctl __P((dev_t, int, caddr_t, int));
|
||||
int bpfopen __P((dev_t, int, int, struct proc *));
|
||||
int bpfclose __P((dev_t, int, int, struct proc *));
|
||||
int bpfread __P((dev_t, struct uio *, int));
|
||||
int bpfwrite __P((dev_t, struct uio *, int));
|
||||
int bpfioctl __P((dev_t, int, caddr_t, int, struct proc *));
|
||||
int bpf_select __P((dev_t, int, struct proc *));
|
||||
void bpf_tap __P((caddr_t, u_char *, u_int));
|
||||
void bpf_mtap __P((caddr_t, struct mbuf *));
|
||||
|
@ -630,7 +630,7 @@ meteor_reset(meteor_reg_t * const sc)
|
||||
#define UNIT(x) ((x) & 0x07)
|
||||
|
||||
int
|
||||
meteor_open(dev_t dev, int flag)
|
||||
meteor_open(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
meteor_reg_t *mtr;
|
||||
int unit;
|
||||
@ -664,7 +664,7 @@ meteor_open(dev_t dev, int flag)
|
||||
}
|
||||
|
||||
int
|
||||
meteor_close(dev_t dev, int flag)
|
||||
meteor_close(dev_t dev, int flags, int fmt, struct proc *p)
|
||||
{
|
||||
meteor_reg_t *mtr;
|
||||
int unit;
|
||||
@ -730,7 +730,7 @@ meteor_close(dev_t dev, int flag)
|
||||
}
|
||||
|
||||
int
|
||||
meteor_read(dev_t dev, struct uio *uio)
|
||||
meteor_read(dev_t dev, struct uio *uio, int ioflag)
|
||||
{
|
||||
meteor_reg_t *mtr;
|
||||
int unit;
|
||||
@ -768,7 +768,7 @@ meteor_read(dev_t dev, struct uio *uio)
|
||||
}
|
||||
|
||||
int
|
||||
meteor_write()
|
||||
meteor_write(dev_t dev, struct uio *uio, int ioflag)
|
||||
{
|
||||
return(0);
|
||||
}
|
||||
|
@ -70,12 +70,12 @@ struct snoop {
|
||||
|
||||
#ifdef KERNEL
|
||||
/* XXX several wrong storage classes and types here. */
|
||||
int snpclose __P((dev_t dev, int flag));
|
||||
int snpclose __P((dev_t dev, int flags, int fmt, struct proc *p));
|
||||
int snp_detach __P((struct snoop *snp));
|
||||
int snpdown __P((struct snoop *snp));
|
||||
int snpin __P((struct snoop *snp, char *buf, int n));
|
||||
int snpinc __P((struct snoop *snp, char c));
|
||||
int snpioctl __P((dev_t dev, int cmd, caddr_t data, int flag));
|
||||
int snpioctl __P((dev_t dev, int cmd, caddr_t data, int flags, struct proc *p));
|
||||
int snpopen __P((dev_t dev, int flag, int mode, struct proc *p));
|
||||
int snpread __P((dev_t dev, struct uio *uio, int flag));
|
||||
int snpselect __P((dev_t dev, int rw, struct proc *p));
|
||||
|
Loading…
Reference in New Issue
Block a user