summaryrefslogtreecommitdiff
path: root/sys/miscfs
diff options
context:
space:
mode:
authorkstailey <kstailey@cvs.openbsd.org>1997-04-26 12:10:01 +0000
committerkstailey <kstailey@cvs.openbsd.org>1997-04-26 12:10:01 +0000
commit6bdc1ce3a8ccaf3a9fec3bcb79ef0e745806e9f5 (patch)
treefa9d6eca57d81b45d1026c8e2406c41f548d6436 /sys/miscfs
parentfde59d5afa8e9ed4e948148b279890aef07dbbc1 (diff)
struct definitions in .h files and instances in .c file please.
Vic Able: > While <miscfs/kernfs/kernfs.h> has a kernfs_node, it depends > on a structure that's defined in <miscfs/kernfs/kernfs_vnops.c>. > Oops! That's not very social. :-) [I built a new kernel fine, but don't have time to run "make build" it is my intuition that this will not have any bad effects, but I didn't test. Just back it out if it hurts you and I'll try again.]
Diffstat (limited to 'sys/miscfs')
-rw-r--r--sys/miscfs/kernfs/kernfs.h26
-rw-r--r--sys/miscfs/kernfs/kernfs_vnops.c25
2 files changed, 27 insertions, 24 deletions
diff --git a/sys/miscfs/kernfs/kernfs.h b/sys/miscfs/kernfs/kernfs.h
index c6c8cfb4273..2360f925262 100644
--- a/sys/miscfs/kernfs/kernfs.h
+++ b/sys/miscfs/kernfs/kernfs.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: kernfs.h,v 1.2 1996/02/27 07:55:17 niklas Exp $ */
+/* $OpenBSD: kernfs.h,v 1.3 1997/04/26 12:09:58 kstailey Exp $ */
/* $NetBSD: kernfs.h,v 1.10 1996/02/09 22:40:21 christos Exp $ */
/*
@@ -42,6 +42,30 @@
#define _PATH_KERNFS "/kern" /* Default mountpoint */
#ifdef _KERNEL
+
+struct kern_target {
+ u_char kt_type;
+ u_char kt_namlen;
+ char *kt_name;
+ void *kt_data;
+#define KTT_NULL 1
+#define KTT_TIME 5
+#define KTT_INT 17
+#define KTT_STRING 31
+#define KTT_HOSTNAME 47
+#define KTT_AVENRUN 53
+#define KTT_DEVICE 71
+#define KTT_MSGBUF 89
+#define KTT_USERMEM 91
+#define KTT_DOMAIN 95
+#ifdef IPSEC
+#define KTT_IPSECSPI 107
+#endif
+ u_char kt_tag;
+ u_char kt_vtype;
+ mode_t kt_mode;
+};
+
struct kernfs_mount {
struct vnode *kf_root; /* Root node */
};
diff --git a/sys/miscfs/kernfs/kernfs_vnops.c b/sys/miscfs/kernfs/kernfs_vnops.c
index 8b7f2f814eb..6dd8ca16353 100644
--- a/sys/miscfs/kernfs/kernfs_vnops.c
+++ b/sys/miscfs/kernfs/kernfs_vnops.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: kernfs_vnops.c,v 1.8 1997/03/27 04:39:39 millert Exp $ */
+/* $OpenBSD: kernfs_vnops.c,v 1.9 1997/04/26 12:10:00 kstailey Exp $ */
/* $NetBSD: kernfs_vnops.c,v 1.43 1996/03/16 23:52:47 christos Exp $ */
/*
@@ -79,28 +79,7 @@ extern char ostype[], osrelease[];
extern int ipsp_kern __P((int, char **, int));
#endif
-struct kern_target {
- u_char kt_type;
- u_char kt_namlen;
- char *kt_name;
- void *kt_data;
-#define KTT_NULL 1
-#define KTT_TIME 5
-#define KTT_INT 17
-#define KTT_STRING 31
-#define KTT_HOSTNAME 47
-#define KTT_AVENRUN 53
-#define KTT_DEVICE 71
-#define KTT_MSGBUF 89
-#define KTT_USERMEM 91
-#define KTT_DOMAIN 95
-#ifdef IPSEC
-#define KTT_IPSECSPI 107
-#endif
- u_char kt_tag;
- u_char kt_vtype;
- mode_t kt_mode;
-} kern_targets[] = {
+struct kern_target kern_targets[] = {
/* NOTE: The name must be less than UIO_MX-16 chars in length */
#define N(s) sizeof(s)-1, s
/* name data tag type ro/rw */