summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
Diffstat (limited to 'sys')
-rw-r--r--sys/miscfs/procfs/procfs.h4
-rw-r--r--sys/miscfs/procfs/procfs_ctl.c8
-rw-r--r--sys/miscfs/procfs/procfs_subr.c9
3 files changed, 10 insertions, 11 deletions
diff --git a/sys/miscfs/procfs/procfs.h b/sys/miscfs/procfs/procfs.h
index e731edcdc32..0608ca7f035 100644
--- a/sys/miscfs/procfs/procfs.h
+++ b/sys/miscfs/procfs/procfs.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: procfs.h,v 1.19 2003/08/05 20:47:36 tedu Exp $ */
+/* $OpenBSD: procfs.h,v 1.20 2003/08/11 10:08:04 mickey Exp $ */
/* $NetBSD: procfs.h,v 1.17 1996/02/12 15:01:41 christos Exp $ */
/*
@@ -108,7 +108,7 @@ struct vfs_namemap {
};
int vfs_getuserstr(struct uio *, char *, int *);
-vfs_namemap_t *vfs_findname(vfs_namemap_t *, char *, int);
+const vfs_namemap_t *vfs_findname(const vfs_namemap_t *, char *, int);
int procfs_allocvp(struct mount *, struct vnode **, long, pfstype);
int procfs_checkioperm(struct proc *p, struct proc *t);
diff --git a/sys/miscfs/procfs/procfs_ctl.c b/sys/miscfs/procfs/procfs_ctl.c
index 046b301bd52..53cec8ee556 100644
--- a/sys/miscfs/procfs/procfs_ctl.c
+++ b/sys/miscfs/procfs/procfs_ctl.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: procfs_ctl.c,v 1.11 2003/06/02 23:28:11 millert Exp $ */
+/* $OpenBSD: procfs_ctl.c,v 1.12 2003/08/11 10:08:04 mickey Exp $ */
/* $NetBSD: procfs_ctl.c,v 1.14 1996/02/09 22:40:48 christos Exp $ */
/*
@@ -67,7 +67,7 @@
#define PROCFS_CTL_RUN 4
#define PROCFS_CTL_WAIT 5
-static vfs_namemap_t ctlnames[] = {
+static const vfs_namemap_t ctlnames[] = {
/* special /proc commands */
{ "attach", PROCFS_CTL_ATTACH },
{ "detach", PROCFS_CTL_DETACH },
@@ -79,7 +79,7 @@ static vfs_namemap_t ctlnames[] = {
#endif
-static vfs_namemap_t signames[] = {
+static const vfs_namemap_t signames[] = {
/* regular signal names */
{ "hup", SIGHUP }, { "int", SIGINT },
{ "quit", SIGQUIT }, { "ill", SIGILL },
@@ -266,7 +266,7 @@ procfs_doctl(curp, p, pfs, uio)
int xlen;
int error;
char msg[PROCFS_CTLLEN+1];
- vfs_namemap_t *nm;
+ const vfs_namemap_t *nm;
if (uio->uio_rw != UIO_WRITE)
return (EOPNOTSUPP);
diff --git a/sys/miscfs/procfs/procfs_subr.c b/sys/miscfs/procfs/procfs_subr.c
index 5398c4e4134..38723b253b4 100644
--- a/sys/miscfs/procfs/procfs_subr.c
+++ b/sys/miscfs/procfs/procfs_subr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: procfs_subr.c,v 1.19 2003/06/02 23:28:11 millert Exp $ */
+/* $OpenBSD: procfs_subr.c,v 1.20 2003/08/11 10:08:04 mickey Exp $ */
/* $NetBSD: procfs_subr.c,v 1.15 1996/02/12 15:01:42 christos Exp $ */
/*
@@ -298,16 +298,15 @@ vfs_getuserstr(uio, buf, buflenp)
return (0);
}
-vfs_namemap_t *
+const vfs_namemap_t *
vfs_findname(nm, buf, buflen)
- vfs_namemap_t *nm;
+ const vfs_namemap_t *nm;
char *buf;
int buflen;
{
for (; nm->nm_name; nm++)
- if (bcmp((const void *) buf, (const void *) nm->nm_name,
- buflen + 1) == 0)
+ if (bcmp(buf, nm->nm_name, buflen + 1) == 0)
return (nm);
return (0);