220 int smbfs_smb_setsec_m(struct smb_share *ssp, uint16_t fid,
221 struct smb_cred *scrp, uint32_t selector, mblk_t **mp);
222
223 /*
224 * VFS-level init, fini stuff
225 */
226
227 int smbfs_vfsinit(void);
228 void smbfs_vfsfini(void);
229 int smbfs_subrinit(void);
230 void smbfs_subrfini(void);
231 int smbfs_clntinit(void);
232 void smbfs_clntfini(void);
233
234 void smbfs_zonelist_add(smbmntinfo_t *smi);
235 void smbfs_zonelist_remove(smbmntinfo_t *smi);
236
237 int smbfs_check_table(struct vfs *vfsp, struct smbnode *srp);
238 void smbfs_destroy_table(struct vfs *vfsp);
239 void smbfs_rflush(struct vfs *vfsp, cred_t *cr);
240
241 uint32_t smbfs_newnum(void);
242 int smbfs_newname(char *buf, size_t buflen);
243
244 /*
245 * Function definitions - those having to do with
246 * smbfs nodes, vnodes, etc
247 */
248
249 void smbfs_attrcache_prune(struct smbnode *np);
250 void smbfs_attrcache_remove(struct smbnode *np);
251 void smbfs_attrcache_rm_locked(struct smbnode *np);
252 #ifndef DEBUG
253 #define smbfs_attrcache_rm_locked(np) (np)->r_attrtime = gethrtime()
254 #endif
255 void smbfs_attr_touchdir(struct smbnode *dnp);
256 void smbfs_attrcache_fa(vnode_t *vp, struct smbfattr *fap);
257 void smbfs_cache_check(struct vnode *vp, struct smbfattr *fap);
258
259 void smbfs_addfree(struct smbnode *sp);
260 void smbfs_rmhash(struct smbnode *);
261
262 /* See avl_create in smbfs_vfsops.c */
263 void smbfs_init_hash_avl(avl_tree_t *);
264
265 uint32_t smbfs_gethash(const char *rpath, int prlen);
266 uint32_t smbfs_getino(struct smbnode *dnp, const char *name, int nmlen);
267
268 extern struct smbfattr smbfs_fattr0;
269 smbnode_t *smbfs_node_findcreate(smbmntinfo_t *mi,
270 const char *dir, int dirlen,
271 const char *name, int nmlen,
272 char sep, struct smbfattr *fap);
273
274 int smbfs_nget(vnode_t *dvp, const char *name, int nmlen,
275 struct smbfattr *fap, vnode_t **vpp);
276
277 void smbfs_fname_tolocal(struct smbfs_fctx *ctx);
278 char *smbfs_name_alloc(const char *name, int nmlen);
279 void smbfs_name_free(const char *name, int nmlen);
280
281 int smbfs_readvnode(vnode_t *, uio_t *, cred_t *, struct vattr *);
282 int smbfs_writevnode(vnode_t *vp, uio_t *uiop, cred_t *cr,
283 int ioflag, int timo);
284 int smbfsgetattr(vnode_t *vp, struct vattr *vap, cred_t *cr);
285
286 /* smbfs ACL support */
287 int smbfs_acl_getids(vnode_t *, cred_t *);
288 int smbfs_acl_setids(vnode_t *, vattr_t *, cred_t *);
289 int smbfs_acl_getvsa(vnode_t *, vsecattr_t *, int, cred_t *);
290 int smbfs_acl_setvsa(vnode_t *, vsecattr_t *, int, cred_t *);
291 int smbfs_acl_iocget(vnode_t *, intptr_t, int, cred_t *);
292 int smbfs_acl_iocset(vnode_t *, intptr_t, int, cred_t *);
293
294 /* smbfs_xattr.c */
295 int smbfs_get_xattrdir(vnode_t *dvp, vnode_t **vpp, cred_t *cr, int);
296 int smbfs_xa_parent(vnode_t *vp, vnode_t **vpp);
297 int smbfs_xa_exists(vnode_t *vp, cred_t *cr);
298 int smbfs_xa_getfattr(struct smbnode *np, struct smbfattr *fap,
299 struct smb_cred *scrp);
300 int smbfs_xa_findopen(struct smbfs_fctx *ctx, struct smbnode *dnp,
301 const char *name, int nmlen);
302 int smbfs_xa_findnext(struct smbfs_fctx *ctx, uint16_t limit);
303 int smbfs_xa_findclose(struct smbfs_fctx *ctx);
304
305 /* For Solaris, interruptible rwlock */
|
220 int smbfs_smb_setsec_m(struct smb_share *ssp, uint16_t fid,
221 struct smb_cred *scrp, uint32_t selector, mblk_t **mp);
222
223 /*
224 * VFS-level init, fini stuff
225 */
226
227 int smbfs_vfsinit(void);
228 void smbfs_vfsfini(void);
229 int smbfs_subrinit(void);
230 void smbfs_subrfini(void);
231 int smbfs_clntinit(void);
232 void smbfs_clntfini(void);
233
234 void smbfs_zonelist_add(smbmntinfo_t *smi);
235 void smbfs_zonelist_remove(smbmntinfo_t *smi);
236
237 int smbfs_check_table(struct vfs *vfsp, struct smbnode *srp);
238 void smbfs_destroy_table(struct vfs *vfsp);
239 void smbfs_rflush(struct vfs *vfsp, cred_t *cr);
240 void smbfs_flushall(cred_t *cr);
241
242 int smbfs_directio(vnode_t *vp, int cmd, cred_t *cr);
243
244 uint32_t smbfs_newnum(void);
245 int smbfs_newname(char *buf, size_t buflen);
246
247 /*
248 * Function definitions - those having to do with
249 * smbfs nodes, vnodes, etc
250 */
251
252 void smbfs_attrcache_prune(struct smbnode *np);
253 void smbfs_attrcache_remove(struct smbnode *np);
254 void smbfs_attrcache_rm_locked(struct smbnode *np);
255 #ifndef DEBUG
256 #define smbfs_attrcache_rm_locked(np) (np)->r_attrtime = gethrtime()
257 #endif
258 void smbfs_attr_touchdir(struct smbnode *dnp);
259 void smbfs_attrcache_fa(vnode_t *vp, struct smbfattr *fap);
260
261 int smbfs_validate_caches(struct vnode *vp, cred_t *cr);
262 void smbfs_purge_caches(struct vnode *vp, cred_t *cr);
263
264 void smbfs_addfree(struct smbnode *sp);
265 void smbfs_rmhash(struct smbnode *);
266
267 /* See avl_create in smbfs_vfsops.c */
268 void smbfs_init_hash_avl(avl_tree_t *);
269
270 uint32_t smbfs_gethash(const char *rpath, int prlen);
271 uint32_t smbfs_getino(struct smbnode *dnp, const char *name, int nmlen);
272
273 extern struct smbfattr smbfs_fattr0;
274 smbnode_t *smbfs_node_findcreate(smbmntinfo_t *mi,
275 const char *dir, int dirlen,
276 const char *name, int nmlen,
277 char sep, struct smbfattr *fap);
278
279 int smbfs_nget(vnode_t *dvp, const char *name, int nmlen,
280 struct smbfattr *fap, vnode_t **vpp);
281
282 void smbfs_fname_tolocal(struct smbfs_fctx *ctx);
283 char *smbfs_name_alloc(const char *name, int nmlen);
284 void smbfs_name_free(const char *name, int nmlen);
285
286 int smbfs_readvnode(vnode_t *, uio_t *, cred_t *, struct vattr *);
287 int smbfs_writevnode(vnode_t *vp, uio_t *uiop, cred_t *cr,
288 int ioflag, int timo);
289 int smbfsgetattr(vnode_t *vp, struct vattr *vap, cred_t *cr);
290
291 /* nfs: writerp writenp */
292 /* nfs_putpages? */
293 void smbfs_invalidate_pages(vnode_t *vp, u_offset_t off, cred_t *cr);
294
295 /* smbfs ACL support */
296 int smbfs_acl_getids(vnode_t *, cred_t *);
297 int smbfs_acl_setids(vnode_t *, vattr_t *, cred_t *);
298 int smbfs_acl_getvsa(vnode_t *, vsecattr_t *, int, cred_t *);
299 int smbfs_acl_setvsa(vnode_t *, vsecattr_t *, int, cred_t *);
300 int smbfs_acl_iocget(vnode_t *, intptr_t, int, cred_t *);
301 int smbfs_acl_iocset(vnode_t *, intptr_t, int, cred_t *);
302
303 /* smbfs_xattr.c */
304 int smbfs_get_xattrdir(vnode_t *dvp, vnode_t **vpp, cred_t *cr, int);
305 int smbfs_xa_parent(vnode_t *vp, vnode_t **vpp);
306 int smbfs_xa_exists(vnode_t *vp, cred_t *cr);
307 int smbfs_xa_getfattr(struct smbnode *np, struct smbfattr *fap,
308 struct smb_cred *scrp);
309 int smbfs_xa_findopen(struct smbfs_fctx *ctx, struct smbnode *dnp,
310 const char *name, int nmlen);
311 int smbfs_xa_findnext(struct smbfs_fctx *ctx, uint16_t limit);
312 int smbfs_xa_findclose(struct smbfs_fctx *ctx);
313
314 /* For Solaris, interruptible rwlock */
|