aboutsummaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorBruce Evans <bde@FreeBSD.org>1994-12-11 23:05:53 +0000
committerBruce Evans <bde@FreeBSD.org>1994-12-11 23:05:53 +0000
commit51cd3c966690c4f5665e9f8e1972620968e6afbb (patch)
tree17bcd5247b1b9c75b7f9a8eefca23558ae0eea14 /sys
parent9d93bf70ea18f22091a475439ec7fc062ad62df0 (diff)
downloadsrc-51cd3c966690c4f5665e9f8e1972620968e6afbb.tar.gz
src-51cd3c966690c4f5665e9f8e1972620968e6afbb.zip
Declare d_strategy_t here and use it to declare strategy functions.
Sort prototypes. Uniformize idempotency ifdef.
Notes
Notes: svn path=/head/; revision=5051
Diffstat (limited to 'sys')
-rw-r--r--sys/sys/conf.h20
-rw-r--r--sys/sys/linedisc.h20
2 files changed, 22 insertions, 18 deletions
diff --git a/sys/sys/conf.h b/sys/sys/conf.h
index 899167184d90..0b47c8f204e5 100644
--- a/sys/sys/conf.h
+++ b/sys/sys/conf.h
@@ -36,11 +36,11 @@
* SUCH DAMAGE.
*
* @(#)conf.h 8.3 (Berkeley) 1/21/94
- * $Id: conf.h,v 1.4 1994/10/08 22:22:56 phk Exp $
+ * $Id: conf.h,v 1.5 1994/12/05 01:34:54 jkh Exp $
*/
#ifndef _SYS_CONF_H_
-#define _SYS_CONF_H_
+#define _SYS_CONF_H_
/*
* Definitions of device driver entry switches
@@ -52,12 +52,14 @@ struct tty;
struct uio;
struct vnode;
+typedef void d_strategy_t __P((struct buf *));
+
struct bdevsw {
int (*d_open) __P((dev_t dev, int oflags, int devtype,
struct proc *p));
int (*d_close) __P((dev_t dev, int fflag, int devtype,
struct proc *p));
- int (*d_strategy) __P((struct buf *bp));
+ d_strategy_t *d_strategy;
int (*d_ioctl) __P((dev_t dev, int cmd, caddr_t data,
int fflag, struct proc *p));
int (*d_dump) (); /* parameters vary by architecture */
@@ -83,7 +85,7 @@ struct cdevsw {
struct tty *d_ttys;
int (*d_select) __P((dev_t dev, int which, struct proc *p));
int (*d_mmap) __P(());
- int (*d_strategy) __P((struct buf *bp));
+ d_strategy_t *d_strategy;
};
#ifdef KERNEL
@@ -125,10 +127,10 @@ struct swdevt {
#ifdef KERNEL
extern struct swdevt swdevt[];
-int iskmemdev __P((dev_t));
-int iszerodev __P((dev_t));
-int isdisk __P((dev_t, int));
-dev_t chrtoblk __P((dev_t));
+dev_t chrtoblk __P((dev_t dev));
+int isdisk __P((dev_t dev, int type));
+int iskmemdev __P((dev_t dev));
+int iszerodev __P((dev_t dev));
#endif
-#endif
+#endif /* !_SYS_CONF_H_ */
diff --git a/sys/sys/linedisc.h b/sys/sys/linedisc.h
index 899167184d90..0b47c8f204e5 100644
--- a/sys/sys/linedisc.h
+++ b/sys/sys/linedisc.h
@@ -36,11 +36,11 @@
* SUCH DAMAGE.
*
* @(#)conf.h 8.3 (Berkeley) 1/21/94
- * $Id: conf.h,v 1.4 1994/10/08 22:22:56 phk Exp $
+ * $Id: conf.h,v 1.5 1994/12/05 01:34:54 jkh Exp $
*/
#ifndef _SYS_CONF_H_
-#define _SYS_CONF_H_
+#define _SYS_CONF_H_
/*
* Definitions of device driver entry switches
@@ -52,12 +52,14 @@ struct tty;
struct uio;
struct vnode;
+typedef void d_strategy_t __P((struct buf *));
+
struct bdevsw {
int (*d_open) __P((dev_t dev, int oflags, int devtype,
struct proc *p));
int (*d_close) __P((dev_t dev, int fflag, int devtype,
struct proc *p));
- int (*d_strategy) __P((struct buf *bp));
+ d_strategy_t *d_strategy;
int (*d_ioctl) __P((dev_t dev, int cmd, caddr_t data,
int fflag, struct proc *p));
int (*d_dump) (); /* parameters vary by architecture */
@@ -83,7 +85,7 @@ struct cdevsw {
struct tty *d_ttys;
int (*d_select) __P((dev_t dev, int which, struct proc *p));
int (*d_mmap) __P(());
- int (*d_strategy) __P((struct buf *bp));
+ d_strategy_t *d_strategy;
};
#ifdef KERNEL
@@ -125,10 +127,10 @@ struct swdevt {
#ifdef KERNEL
extern struct swdevt swdevt[];
-int iskmemdev __P((dev_t));
-int iszerodev __P((dev_t));
-int isdisk __P((dev_t, int));
-dev_t chrtoblk __P((dev_t));
+dev_t chrtoblk __P((dev_t dev));
+int isdisk __P((dev_t dev, int type));
+int iskmemdev __P((dev_t dev));
+int iszerodev __P((dev_t dev));
#endif
-#endif
+#endif /* !_SYS_CONF_H_ */