summaryrefslogtreecommitdiff
path: root/sys/nfs/nfs_vnops.c
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>2004-04-26 18:57:37 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>2004-04-26 18:57:37 +0000
commit299594b83473a24b996014df9d0155506c86fa1b (patch)
treebc42b90e66bd0885cd21cb343a13d574909ab3a4 /sys/nfs/nfs_vnops.c
parentc368588bbc1d38f53e616f88a16606af815dcedf (diff)
nfs_poll cannot simply be defined to seltrue so use a stub nfs_poll
duplicated from UFS. Closes PR 3757; OK deraadt@
Diffstat (limited to 'sys/nfs/nfs_vnops.c')
-rw-r--r--sys/nfs/nfs_vnops.c20
1 files changed, 19 insertions, 1 deletions
diff --git a/sys/nfs/nfs_vnops.c b/sys/nfs/nfs_vnops.c
index ad163a83a4f..4a8ce4e0fa9 100644
--- a/sys/nfs/nfs_vnops.c
+++ b/sys/nfs/nfs_vnops.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: nfs_vnops.c,v 1.58 2004/03/02 05:46:00 tedu Exp $ */
+/* $OpenBSD: nfs_vnops.c,v 1.59 2004/04/26 18:57:36 millert Exp $ */
/* $NetBSD: nfs_vnops.c,v 1.62.4.1 1996/07/08 20:26:52 jtc Exp $ */
/*
@@ -45,6 +45,7 @@
#include <sys/kernel.h>
#include <sys/systm.h>
#include <sys/resourcevar.h>
+#include <sys/poll.h>
#include <sys/proc.h>
#include <sys/mount.h>
#include <sys/buf.h>
@@ -3064,6 +3065,23 @@ nfsspec_access(v)
ap->a_cred));
}
+/* ARGSUSED */
+int
+nfs_poll(v)
+ void *v;
+{
+ struct vop_poll_args /* {
+ struct vnode *a_vp;
+ int a_events;
+ struct proc *a_p;
+ } */ *ap = v;
+
+ /*
+ * We should really check to see if I/O is possible.
+ */
+ return (ap->a_events & (POLLIN | POLLOUT | POLLRDNORM | POLLWRNORM));
+}
+
/*
* Read wrapper for special devices.
*/