Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/lib/libp2k Pass VOP_PATHCONF to backend file server. inspir...



details:   https://anonhg.NetBSD.org/src/rev/b81b916ee47f
branches:  trunk
changeset: 755466:b81b916ee47f
user:      pooka <pooka%NetBSD.org@localhost>
date:      Sun Jun 06 22:46:17 2010 +0000

description:
Pass VOP_PATHCONF to backend file server.  inspired by njoly.

diffstat:

 lib/libp2k/p2k.c |  19 ++++++++++++++++++-
 1 files changed, 18 insertions(+), 1 deletions(-)

diffs (40 lines):

diff -r d3fa31339d50 -r b81b916ee47f lib/libp2k/p2k.c
--- a/lib/libp2k/p2k.c  Sun Jun 06 22:44:54 2010 +0000
+++ b/lib/libp2k/p2k.c  Sun Jun 06 22:46:17 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: p2k.c,v 1.38 2010/05/21 10:52:17 pooka Exp $   */
+/*     $NetBSD: p2k.c,v 1.39 2010/06/06 22:46:17 pooka Exp $   */
 
 /*
  * Copyright (c) 2007, 2008, 2009  Antti Kantee.  All Rights Reserved.
@@ -310,6 +310,8 @@
        PUFFSOP_SET(pops, p2k, node, read);
        PUFFSOP_SET(pops, p2k, node, write);
 
+       PUFFSOP_SET(pops, p2k, node, pathconf);
+
        PUFFSOP_SET(pops, p2k, node, inactive);
        PUFFSOP_SET(pops, p2k, node, reclaim);
        PUFFSOP_SET(pops, p2k, node, abortop);
@@ -1304,6 +1306,21 @@
 
 /*ARGSUSED*/
 int
+p2k_node_pathconf(struct puffs_usermount *pu, puffs_cookie_t opc,
+       int name, int *retval)
+{
+       struct vnode *vp = OPC2VP(opc);
+       int rv;
+
+       RUMP_VOP_LOCK(vp, LK_EXCLUSIVE);
+       rv = RUMP_VOP_PATHCONF(vp, name, (register_t *)retval);
+       RUMP_VOP_UNLOCK(vp, 0);
+
+       return rv;
+}
+
+/*ARGSUSED*/
+int
 p2k_node_getextattr(struct puffs_usermount *pu, puffs_cookie_t opc,
        int attrnamespace, const char *attrname, size_t *attrsize,
        uint8_t *attr, size_t *resid, const struct puffs_cred *pcr)



Home | Main Index | Thread Index | Old Index