Moved the typedefs of d_<foo>_t into sys/sys/conf.h and used them in
the definition of struct [cb]devsw. Guess Bruce never got around to complete this (?) Poul-Henning
This commit is contained in:
parent
6b21ba4ff4
commit
9e2429f597
|
@ -41,7 +41,7 @@
|
||||||
* SUCH DAMAGE.
|
* SUCH DAMAGE.
|
||||||
*
|
*
|
||||||
* from: @(#)conf.c 5.8 (Berkeley) 5/12/91
|
* from: @(#)conf.c 5.8 (Berkeley) 5/12/91
|
||||||
* $Id: conf.c,v 1.52 1995/01/20 08:35:02 sos Exp $
|
* $Id: conf.c,v 1.53 1995/01/23 02:36:22 phk Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sys/param.h>
|
#include <sys/param.h>
|
||||||
|
@ -53,22 +53,6 @@
|
||||||
#include <sys/tty.h>
|
#include <sys/tty.h>
|
||||||
#include <sys/conf.h>
|
#include <sys/conf.h>
|
||||||
|
|
||||||
/*
|
|
||||||
* XXX move these to conf.h as in 1.1.5.
|
|
||||||
* d_strategy_t has already been moved (and fixed).
|
|
||||||
*/
|
|
||||||
typedef int d_open_t __P((dev_t, int, int, struct proc *));
|
|
||||||
typedef int d_close_t __P((dev_t, int, int, struct proc *));
|
|
||||||
typedef int d_ioctl_t __P((dev_t, int, caddr_t, int, struct proc *));
|
|
||||||
typedef int d_dump_t __P(());
|
|
||||||
typedef int d_psize_t __P((dev_t));
|
|
||||||
|
|
||||||
typedef int d_rdwr_t __P((dev_t, struct uio *, int));
|
|
||||||
typedef int d_stop_t __P((struct tty *, int));
|
|
||||||
typedef int d_reset_t __P((int));
|
|
||||||
typedef int d_select_t __P((dev_t, int, struct proc *));
|
|
||||||
typedef int d_mmap_t __P((/* XXX */));
|
|
||||||
|
|
||||||
d_rdwr_t rawread, rawwrite;
|
d_rdwr_t rawread, rawwrite;
|
||||||
d_strategy_t swstrategy;
|
d_strategy_t swstrategy;
|
||||||
|
|
||||||
|
|
|
@ -36,7 +36,7 @@
|
||||||
* SUCH DAMAGE.
|
* SUCH DAMAGE.
|
||||||
*
|
*
|
||||||
* @(#)conf.h 8.3 (Berkeley) 1/21/94
|
* @(#)conf.h 8.3 (Berkeley) 1/21/94
|
||||||
* $Id: conf.h,v 1.5 1994/12/05 01:34:54 jkh Exp $
|
* $Id: conf.h,v 1.6 1994/12/11 23:05:53 bde Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef _SYS_CONF_H_
|
#ifndef _SYS_CONF_H_
|
||||||
|
@ -53,17 +53,25 @@ struct uio;
|
||||||
struct vnode;
|
struct vnode;
|
||||||
|
|
||||||
typedef void d_strategy_t __P((struct buf *));
|
typedef void d_strategy_t __P((struct buf *));
|
||||||
|
typedef int d_open_t __P((dev_t, int, int, struct proc *));
|
||||||
|
typedef int d_close_t __P((dev_t, int, int, struct proc *));
|
||||||
|
typedef int d_ioctl_t __P((dev_t, int, caddr_t, int, struct proc *));
|
||||||
|
typedef int d_dump_t __P(());
|
||||||
|
typedef int d_psize_t __P((dev_t));
|
||||||
|
|
||||||
|
typedef int d_rdwr_t __P((dev_t, struct uio *, int));
|
||||||
|
typedef int d_stop_t __P((struct tty *, int));
|
||||||
|
typedef int d_reset_t __P((int));
|
||||||
|
typedef int d_select_t __P((dev_t, int, struct proc *));
|
||||||
|
typedef int d_mmap_t __P((/* XXX */));
|
||||||
|
|
||||||
struct bdevsw {
|
struct bdevsw {
|
||||||
int (*d_open) __P((dev_t dev, int oflags, int devtype,
|
d_open_t *d_open;
|
||||||
struct proc *p));
|
d_close_t *d_close;
|
||||||
int (*d_close) __P((dev_t dev, int fflag, int devtype,
|
|
||||||
struct proc *p));
|
|
||||||
d_strategy_t *d_strategy;
|
d_strategy_t *d_strategy;
|
||||||
int (*d_ioctl) __P((dev_t dev, int cmd, caddr_t data,
|
d_ioctl_t *d_ioctl;
|
||||||
int fflag, struct proc *p));
|
d_dump_t *d_dump;
|
||||||
int (*d_dump) (); /* parameters vary by architecture */
|
d_psize_t *d_psize;
|
||||||
int (*d_psize) __P((dev_t dev));
|
|
||||||
int d_flags;
|
int d_flags;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -72,19 +80,16 @@ extern struct bdevsw bdevsw[];
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
struct cdevsw {
|
struct cdevsw {
|
||||||
int (*d_open) __P((dev_t dev, int oflags, int devtype,
|
d_open_t *d_open;
|
||||||
struct proc *p));
|
d_close_t *d_close;
|
||||||
int (*d_close) __P((dev_t dev, int fflag, int devtype,
|
d_rdwr_t *d_read;
|
||||||
struct proc *));
|
d_rdwr_t *d_write;
|
||||||
int (*d_read) __P((dev_t dev, struct uio *uio, int ioflag));
|
d_ioctl_t *d_ioctl;
|
||||||
int (*d_write) __P((dev_t dev, struct uio *uio, int ioflag));
|
d_stop_t *d_stop;
|
||||||
int (*d_ioctl) __P((dev_t dev, int cmd, caddr_t data,
|
d_reset_t *d_reset;
|
||||||
int fflag, struct proc *p));
|
|
||||||
int (*d_stop) __P((struct tty *tp, int rw));
|
|
||||||
int (*d_reset) __P((int uban)); /* XXX */
|
|
||||||
struct tty *d_ttys;
|
struct tty *d_ttys;
|
||||||
int (*d_select) __P((dev_t dev, int which, struct proc *p));
|
d_select_t *d_select;
|
||||||
int (*d_mmap) __P(());
|
d_mmap_t *d_mmap;
|
||||||
d_strategy_t *d_strategy;
|
d_strategy_t *d_strategy;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -36,7 +36,7 @@
|
||||||
* SUCH DAMAGE.
|
* SUCH DAMAGE.
|
||||||
*
|
*
|
||||||
* @(#)conf.h 8.3 (Berkeley) 1/21/94
|
* @(#)conf.h 8.3 (Berkeley) 1/21/94
|
||||||
* $Id: conf.h,v 1.5 1994/12/05 01:34:54 jkh Exp $
|
* $Id: conf.h,v 1.6 1994/12/11 23:05:53 bde Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef _SYS_CONF_H_
|
#ifndef _SYS_CONF_H_
|
||||||
|
@ -53,17 +53,25 @@ struct uio;
|
||||||
struct vnode;
|
struct vnode;
|
||||||
|
|
||||||
typedef void d_strategy_t __P((struct buf *));
|
typedef void d_strategy_t __P((struct buf *));
|
||||||
|
typedef int d_open_t __P((dev_t, int, int, struct proc *));
|
||||||
|
typedef int d_close_t __P((dev_t, int, int, struct proc *));
|
||||||
|
typedef int d_ioctl_t __P((dev_t, int, caddr_t, int, struct proc *));
|
||||||
|
typedef int d_dump_t __P(());
|
||||||
|
typedef int d_psize_t __P((dev_t));
|
||||||
|
|
||||||
|
typedef int d_rdwr_t __P((dev_t, struct uio *, int));
|
||||||
|
typedef int d_stop_t __P((struct tty *, int));
|
||||||
|
typedef int d_reset_t __P((int));
|
||||||
|
typedef int d_select_t __P((dev_t, int, struct proc *));
|
||||||
|
typedef int d_mmap_t __P((/* XXX */));
|
||||||
|
|
||||||
struct bdevsw {
|
struct bdevsw {
|
||||||
int (*d_open) __P((dev_t dev, int oflags, int devtype,
|
d_open_t *d_open;
|
||||||
struct proc *p));
|
d_close_t *d_close;
|
||||||
int (*d_close) __P((dev_t dev, int fflag, int devtype,
|
|
||||||
struct proc *p));
|
|
||||||
d_strategy_t *d_strategy;
|
d_strategy_t *d_strategy;
|
||||||
int (*d_ioctl) __P((dev_t dev, int cmd, caddr_t data,
|
d_ioctl_t *d_ioctl;
|
||||||
int fflag, struct proc *p));
|
d_dump_t *d_dump;
|
||||||
int (*d_dump) (); /* parameters vary by architecture */
|
d_psize_t *d_psize;
|
||||||
int (*d_psize) __P((dev_t dev));
|
|
||||||
int d_flags;
|
int d_flags;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -72,19 +80,16 @@ extern struct bdevsw bdevsw[];
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
struct cdevsw {
|
struct cdevsw {
|
||||||
int (*d_open) __P((dev_t dev, int oflags, int devtype,
|
d_open_t *d_open;
|
||||||
struct proc *p));
|
d_close_t *d_close;
|
||||||
int (*d_close) __P((dev_t dev, int fflag, int devtype,
|
d_rdwr_t *d_read;
|
||||||
struct proc *));
|
d_rdwr_t *d_write;
|
||||||
int (*d_read) __P((dev_t dev, struct uio *uio, int ioflag));
|
d_ioctl_t *d_ioctl;
|
||||||
int (*d_write) __P((dev_t dev, struct uio *uio, int ioflag));
|
d_stop_t *d_stop;
|
||||||
int (*d_ioctl) __P((dev_t dev, int cmd, caddr_t data,
|
d_reset_t *d_reset;
|
||||||
int fflag, struct proc *p));
|
|
||||||
int (*d_stop) __P((struct tty *tp, int rw));
|
|
||||||
int (*d_reset) __P((int uban)); /* XXX */
|
|
||||||
struct tty *d_ttys;
|
struct tty *d_ttys;
|
||||||
int (*d_select) __P((dev_t dev, int which, struct proc *p));
|
d_select_t *d_select;
|
||||||
int (*d_mmap) __P(());
|
d_mmap_t *d_mmap;
|
||||||
d_strategy_t *d_strategy;
|
d_strategy_t *d_strategy;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue