equal
deleted
inserted
replaced
17 * information: Portions Copyright [yyyy] [name of copyright owner] |
17 * information: Portions Copyright [yyyy] [name of copyright owner] |
18 * |
18 * |
19 * CDDL HEADER END |
19 * CDDL HEADER END |
20 */ |
20 */ |
21 /* |
21 /* |
22 * Copyright 2007 Sun Microsystems, Inc. All rights reserved. |
22 * Copyright 2008 Sun Microsystems, Inc. All rights reserved. |
23 * Use is subject to license terms. |
23 * Use is subject to license terms. |
24 */ |
24 */ |
25 |
25 |
26 #pragma ident "%Z%%M% %I% %E% SMI" |
26 #pragma ident "%Z%%M% %I% %E% SMI" |
27 |
27 |
37 #include <sys/systm.h> |
37 #include <sys/systm.h> |
38 |
38 |
39 extern int last_module_id; |
39 extern int last_module_id; |
40 |
40 |
41 static int objfs_root_do_lookup(vnode_t *, const char *, vnode_t **, ino64_t *, |
41 static int objfs_root_do_lookup(vnode_t *, const char *, vnode_t **, ino64_t *, |
42 cred_t *); |
42 cred_t *, int, int *, pathname_t *); |
43 static int objfs_root_do_readdir(vnode_t *, void *, int *, |
43 static int objfs_root_do_readdir(vnode_t *, void *, int *, |
44 offset_t *, offset_t *, void *, int); |
44 offset_t *, offset_t *, void *, int); |
45 |
45 |
46 vnode_t * |
46 vnode_t * |
47 objfs_create_root(vfs_t *vfsp) |
47 objfs_create_root(vfs_t *vfsp) |
70 } |
70 } |
71 |
71 |
72 /* ARGSUSED */ |
72 /* ARGSUSED */ |
73 static int |
73 static int |
74 objfs_root_do_lookup(vnode_t *vp, const char *nm, vnode_t **vpp, ino64_t *inop, |
74 objfs_root_do_lookup(vnode_t *vp, const char *nm, vnode_t **vpp, ino64_t *inop, |
75 cred_t *cr) |
75 cred_t *cr, int flags, int *deflags, pathname_t *rpnp) |
76 { |
76 { |
77 int result = ENOENT; |
77 int result = ENOENT; |
78 struct modctl *mp; |
78 struct modctl *mp; |
79 |
79 |
80 /* |
80 /* |
110 { |
110 { |
111 struct modctl **mpp = data; |
111 struct modctl **mpp = data; |
112 struct modctl *mp = *mpp; |
112 struct modctl *mp = *mpp; |
113 struct dirent64 *odp = dp; |
113 struct dirent64 *odp = dp; |
114 |
114 |
115 /* objfs does not support V_RDDIR_ENTFLAGS */ |
115 ASSERT(!(flags & V_RDDIR_ENTFLAGS)); |
116 if (flags & V_RDDIR_ENTFLAGS) |
|
117 return (ENOTSUP); |
|
118 |
116 |
119 mutex_enter(&mod_lock); |
117 mutex_enter(&mod_lock); |
120 |
118 |
121 /* Check for EOF */ |
119 /* Check for EOF */ |
122 if (*offp >= last_module_id) { |
120 if (*offp >= last_module_id) { |