这篇教程C++ vfs_unbusy函数代码示例写得很实用,希望能帮到您。
本文整理汇总了C++中vfs_unbusy函数的典型用法代码示例。如果您正苦于以下问题:C++ vfs_unbusy函数的具体用法?C++ vfs_unbusy怎么用?C++ vfs_unbusy使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。 在下文中一共展示了vfs_unbusy函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。 示例1: ext2fs_mountrootintext2fs_mountroot(void){ extern struct vnode *rootvp; struct m_ext2fs *fs; struct mount *mp; struct ufsmount *ump; int error; if (device_class(root_device) != DV_DISK) return ENODEV; if ((error = vfs_rootmountalloc(MOUNT_EXT2FS, "root_device", &mp))) { vrele(rootvp); return error; } if ((error = ext2fs_mountfs(rootvp, mp)) != 0) { vfs_unbusy(mp, false, NULL); vfs_destroy(mp); return error; } mountlist_append(mp); ump = VFSTOUFS(mp); fs = ump->um_e2fs; ext2fs_sb_setmountinfo(fs, mp); (void)ext2fs_statvfs(mp, &mp->mnt_stat); vfs_unbusy(mp, false, NULL); setrootfstime((time_t)fs->e2fs.e2fs_wtime); return 0;}
开发者ID:ryo,项目名称:netbsd-src,代码行数:31,
示例2: cd9660_mountrootintcd9660_mountroot(void){ struct mount *mp; struct lwp *l = curlwp; int error; struct iso_args args; if (device_class(root_device) != DV_DISK) return (ENODEV); if ((error = vfs_rootmountalloc(MOUNT_CD9660, "root_device", &mp)) != 0) { vrele(rootvp); return (error); } args.flags = ISOFSMNT_ROOT; if ((error = iso_mountfs(rootvp, mp, l, &args)) != 0) { vfs_unbusy(mp, false, NULL); vfs_destroy(mp); return (error); } mountlist_append(mp); (void)cd9660_statvfs(mp, &mp->mnt_stat); vfs_unbusy(mp, false, NULL); return (0);}
开发者ID:Hooman3,项目名称:minix,代码行数:28,
示例3: lfs_mountroot/* * Called by main() when ufs is going to be mounted as root. */lfs_mountroot(){ extern struct vnode *rootvp; struct fs *fs; struct mount *mp; struct proc *p = curproc; /* XXX */ int error; /* * Get vnodes for swapdev and rootdev. */ if ((error = bdevvp(swapdev, &swapdev_vp)) || (error = bdevvp(rootdev, &rootvp))) { printf("lfs_mountroot: can't setup bdevvp's"); return (error); } if (error = vfs_rootmountalloc("lfs", "root_device", &mp)) return (error); if (error = lfs_mountfs(rootvp, mp, p)) { mp->mnt_vfc->vfc_refcount--; vfs_unbusy(mp, p); free(mp, M_MOUNT); return (error); } simple_lock(&mountlist_slock); CIRCLEQ_INSERT_TAIL(&mountlist, mp, mnt_list); simple_unlock(&mountlist_slock); (void)lfs_statfs(mp, &mp->mnt_stat, p); vfs_unbusy(mp, p); return (0);}
开发者ID:adugeek,项目名称:4.4BSD-Lite2,代码行数:34,
示例4: cd9660_mountrootintcd9660_mountroot(void){ struct mount *mp; extern struct vnode *rootvp; struct proc *p = curproc; /* XXX */ int error; struct iso_args args; /* * Get vnodes for swapdev and rootdev. */ if ((error = bdevvp(swapdev, &swapdev_vp)) || (error = bdevvp(rootdev, &rootvp))) { printf("cd9660_mountroot: can't setup bdevvp's"); return (error); } if ((error = vfs_rootmountalloc("cd9660", "root_device", &mp)) != 0) return (error); args.flags = ISOFSMNT_ROOT; if ((error = iso_mountfs(rootvp, mp, p, &args)) != 0) { mp->mnt_vfc->vfc_refcount--; vfs_unbusy(mp); free(mp, M_MOUNT, 0); return (error); } TAILQ_INSERT_TAIL(&mountlist, mp, mnt_list); (void)cd9660_statfs(mp, &mp->mnt_stat, p); vfs_unbusy(mp); inittodr(0); return (0);}
开发者ID:darksoul42,项目名称:bitrig,代码行数:35,
示例5: ffs_mountroot/* * Called by main() when ufs is going to be mounted as root. */ffs_mountroot(){ extern struct vnode *rootvp; struct fs *fs; struct mount *mp; struct proc *p = current_proc(); /* XXX */ struct ufsmount *ump; u_int size; int error; /* * Get vnode for rootdev. */ if (error = bdevvp(rootdev, &rootvp)) { printf("ffs_mountroot: can't setup bdevvp"); return (error); } if (error = vfs_rootmountalloc("ufs", "root_device", &mp)) { vrele(rootvp); /* release the reference from bdevvp() */ return (error); } /* Must set the MNT_ROOTFS flag before doing the actual mount */ mp->mnt_flag |= MNT_ROOTFS; /* Set asynchronous flag by default */ mp->mnt_flag |= MNT_ASYNC; if (error = ffs_mountfs(rootvp, mp, p)) { mp->mnt_vfc->vfc_refcount--; if (mp->mnt_kern_flag & MNTK_IO_XINFO) FREE(mp->mnt_xinfo_ptr, M_TEMP); vfs_unbusy(mp, p); vrele(rootvp); /* release the reference from bdevvp() */ FREE_ZONE(mp, sizeof (struct mount), M_MOUNT); return (error); } simple_lock(&mountlist_slock); CIRCLEQ_INSERT_TAIL(&mountlist, mp, mnt_list); simple_unlock(&mountlist_slock); ump = VFSTOUFS(mp); fs = ump->um_fs; (void) copystr(mp->mnt_stat.f_mntonname, fs->fs_fsmnt, MNAMELEN - 1, 0); (void)ffs_statfs(mp, &mp->mnt_stat, p); vfs_unbusy(mp, p); inittodr(fs->fs_time); return (0);}
开发者ID:OpenDarwin-CVS,项目名称:SEDarwin,代码行数:53,
示例6: filesystem_syncstatic OSKIT_COMDECL filesystem_sync(oskit_filesystem_t *f, oskit_bool_t wait){ struct gfilesystem *fs = (struct gfilesystem *) f; struct mount *mp; struct proc *p; oskit_error_t ferror; int error, asyncflag; if (!fs || !fs->count || !fs->mp) return OSKIT_E_INVALIDARG; ferror = getproc(&p); if (ferror) return ferror; mp = fs->mp; error = 0; if ((mp->mnt_flag & (MNT_MLOCK|MNT_RDONLY|MNT_MPBUSY)) == 0 && !vfs_busy(mp)) { asyncflag = mp->mnt_flag & MNT_ASYNC; mp->mnt_flag &= ~MNT_ASYNC; error = VFS_SYNC(mp, wait ? MNT_WAIT : MNT_NOWAIT, p->p_ucred, p); if (asyncflag) mp->mnt_flag |= MNT_ASYNC; vfs_unbusy(mp); } prfree(p); if (error) return errno_to_oskit_error(error); return 0;}
开发者ID:dzavalishin,项目名称:oskit,代码行数:34,
示例7: ulfs_quotactl/* * Do operations associated with quotas */intulfs_quotactl(struct mount *mp, struct quotactl_args *args){#if !defined(LFS_QUOTA) && !defined(LFS_QUOTA2) (void) mp; (void) args; return (EOPNOTSUPP);#else struct lwp *l = curlwp; int error; /* Mark the mount busy, as we're passing it to kauth(9). */ error = vfs_busy(mp, NULL); if (error) { return (error); } mutex_enter(&mp->mnt_updating); error = lfsquota_handle_cmd(mp, l, args); mutex_exit(&mp->mnt_updating); vfs_unbusy(mp, false, NULL); return (error);#endif}
开发者ID:Stichting-MINIX-Research-Foundation,项目名称:minix,代码行数:29,
示例8: vfs_getrealpathstatic intvfs_getrealpath(const char * path, char * realpath, size_t bufsize, vfs_context_t ctx){ vnode_t vp; struct mount *mp = NULL; char *str; char ch; uint32_t id; ino64_t ino; int error; int length; /* Get file system id and move str to next component. */ id = strtoul(path, &str, 10); if (id == 0 || str[0] != '/') { return (EINVAL); } while (*str == '/') { str++; } ch = *str; mp = mount_lookupby_volfsid(id, 1); if (mp == NULL) { return (EINVAL); /* unexpected failure */ } /* Check for an alias to a file system root. */ if (ch == '@' && str[1] == '/0') { ino = 2; str++; } else { /* Get file id and move str to next component. */ ino = strtouq(str, &str, 10); } /* Get the target vnode. */ if (ino == 2) { error = VFS_ROOT(mp, &vp, ctx); } else { error = VFS_VGET(mp, ino, &vp, ctx); } vfs_unbusy(mp); if (error) { goto out; } realpath[0] = '/0'; /* Get the absolute path to this vnode. */ error = build_path(vp, realpath, bufsize, &length, 0, ctx); vnode_put(vp); if (error == 0 && *str != '/0') { int attempt = strlcat(realpath, str, MAXPATHLEN); if (attempt > MAXPATHLEN){ error = ENAMETOOLONG; } }out: return (error);}
开发者ID:Algozjb,项目名称:xnu,代码行数:60,
示例9: sync_fsync/* * Do a lazy sync of the filesystem. */intsync_fsync(void *v){ struct vop_fsync_args *ap = v; struct vnode *syncvp = ap->a_vp; struct mount *mp = syncvp->v_mount; int asyncflag; /* * We only need to do something if this is a lazy evaluation. */ if (ap->a_waitfor != MNT_LAZY) return (0); /* * Move ourselves to the back of the sync list. */ vn_syncer_add_to_worklist(syncvp, syncdelay); /* * Walk the list of vnodes pushing all that are dirty and * not already on the sync list. */ if (vfs_busy(mp, VB_READ|VB_NOWAIT) == 0) { asyncflag = mp->mnt_flag & MNT_ASYNC; mp->mnt_flag &= ~MNT_ASYNC; VFS_SYNC(mp, MNT_LAZY, ap->a_cred, ap->a_p); if (asyncflag) mp->mnt_flag |= MNT_ASYNC; vfs_unbusy(mp); } return (0);}
开发者ID:repos-holder,项目名称:openbsd-patches,代码行数:37,
示例10: mfs_mountrootintmfs_mountroot(void){ struct fs *fs; struct mount *mp; struct lwp *l = curlwp; /* XXX */ struct ufsmount *ump; struct mfsnode *mfsp; int error = 0; if ((error = vfs_rootmountalloc(MOUNT_MFS, "mfs_root", &mp))) { vrele(rootvp); return (error); } mfsp = kmem_alloc(sizeof(*mfsp), KM_SLEEP); rootvp->v_data = mfsp; rootvp->v_op = mfs_vnodeop_p; rootvp->v_tag = VT_MFS; mfsp->mfs_baseoff = mfs_rootbase; mfsp->mfs_size = mfs_rootsize; mfsp->mfs_vnode = rootvp; mfsp->mfs_proc = NULL; /* indicate kernel space */ mfsp->mfs_shutdown = 0; cv_init(&mfsp->mfs_cv, "mfs"); mfsp->mfs_refcnt = 1; bufq_alloc(&mfsp->mfs_buflist, "fcfs", 0); if ((error = ffs_mountfs(rootvp, mp, l)) != 0) { vfs_unbusy(mp, false, NULL); bufq_free(mfsp->mfs_buflist); vfs_destroy(mp); kmem_free(mfsp, sizeof(*mfsp)); return (error); } mutex_enter(&mountlist_lock); CIRCLEQ_INSERT_TAIL(&mountlist, mp, mnt_list); mutex_exit(&mountlist_lock); mp->mnt_vnodecovered = NULLVP; ump = VFSTOUFS(mp); fs = ump->um_fs; (void) copystr(mp->mnt_stat.f_mntonname, fs->fs_fsmnt, MNAMELEN - 1, 0); (void)ffs_statvfs(mp, &mp->mnt_stat); vfs_unbusy(mp, false, NULL); return (0);}
开发者ID:AgamAgarwal,项目名称:minix,代码行数:45,
示例11: fuse_internal_remove__private_extern__intfuse_internal_remove(vnode_t dvp, vnode_t vp, struct componentname *cnp, enum fuse_opcode op, vfs_context_t context){ struct fuse_dispatcher fdi; struct vnode_attr *vap = VTOVA(vp); int need_invalidate = 0; uint64_t target_nlink = 0; mount_t mp = vnode_mount(vp); int err = 0; fdisp_init(&fdi, cnp->cn_namelen + 1); fdisp_make_vp(&fdi, op, dvp, context); memcpy(fdi.indata, cnp->cn_nameptr, cnp->cn_namelen); ((char *)fdi.indata)[cnp->cn_namelen] = '/0'; if ((vap->va_nlink > 1) && vnode_isreg(vp)) { need_invalidate = 1; target_nlink = vap->va_nlink; } if (!(err = fdisp_wait_answ(&fdi))) { fuse_ticket_drop(fdi.tick); } fuse_invalidate_attr(dvp); fuse_invalidate_attr(vp); /* * XXX: M_MACFUSE_INVALIDATE_CACHED_VATTRS_UPON_UNLINK * * Consider the case where vap->va_nlink > 1 for the entity being * removed. In our world, other in-memory vnodes that share a link * count each with this one may not know right way that this one just * got deleted. We should let them know, say, through a vnode_iterate() * here and a callback that does fuse_invalidate_attr(vp) on each * relevant vnode. */ if (need_invalidate && !err) { if (!vfs_busy(mp, LK_NOWAIT)) { vnode_iterate(mp, 0, fuse_internal_remove_callback, (void *)&target_nlink); vfs_unbusy(mp); } else { IOLog("MacFUSE: skipping link count fixup upon remove/n"); } } return err;}
开发者ID:95rangerxlt,项目名称:macfuse,代码行数:57,
示例12: ext2fs_mountrootintext2fs_mountroot(void){ struct m_ext2fs *fs; struct mount *mp; struct proc *p = curproc; /* XXX */ struct ufsmount *ump; int error; /* * Get vnodes for swapdev and rootdev. */ if (bdevvp(swapdev, &swapdev_vp) || bdevvp(rootdev, &rootvp)) panic("ext2fs_mountroot: can't setup bdevvp's"); if ((error = vfs_rootmountalloc("ext2fs", "root_device", &mp)) != 0) { vrele(rootvp); return (error); } if ((error = ext2fs_mountfs(rootvp, mp, p)) != 0) { mp->mnt_vfc->vfc_refcount--; vfs_unbusy(mp); free(mp, M_MOUNT); vrele(rootvp); return (error); } TAILQ_INSERT_TAIL(&mountlist, mp, mnt_list); ump = VFSTOUFS(mp); fs = ump->um_e2fs; memset(fs->e2fs_fsmnt, 0, sizeof(fs->e2fs_fsmnt)); strlcpy(fs->e2fs_fsmnt, mp->mnt_stat.f_mntonname, sizeof(fs->e2fs_fsmnt)); if (fs->e2fs.e2fs_rev > E2FS_REV0) { memset(fs->e2fs.e2fs_fsmnt, 0, sizeof(fs->e2fs.e2fs_fsmnt)); strlcpy(fs->e2fs.e2fs_fsmnt, mp->mnt_stat.f_mntonname, sizeof(fs->e2fs.e2fs_fsmnt)); } (void)ext2fs_statfs(mp, &mp->mnt_stat, p); vfs_unbusy(mp); inittodr(fs->e2fs.e2fs_wtime); return (0);}
开发者ID:appleorange1,项目名称:bitrig,代码行数:43,
示例13: msdosfs_mountrootintmsdosfs_mountroot(void){ struct mount *mp; struct lwp *l = curlwp; /* XXX */ int error; struct msdosfs_args args; if (device_class(root_device) != DV_DISK) return (ENODEV); if ((error = vfs_rootmountalloc(MOUNT_MSDOS, "root_device", &mp))) { vrele(rootvp); return (error); } args.flags = MSDOSFSMNT_VERSIONED; args.uid = 0; args.gid = 0; args.mask = 0777; args.version = MSDOSFSMNT_VERSION; args.dirmask = 0777; if ((error = msdosfs_mountfs(rootvp, mp, l, &args)) != 0) { vfs_unbusy(mp, false, NULL); vfs_destroy(mp); return (error); } if ((error = update_mp(mp, &args)) != 0) { (void)msdosfs_unmount(mp, 0); vfs_unbusy(mp, false, NULL); vfs_destroy(mp); vrele(rootvp); return (error); } mountlist_append(mp); (void)msdosfs_statvfs(mp, &mp->mnt_stat); vfs_unbusy(mp, false, NULL); return (0);}
开发者ID:Hooman3,项目名称:minix,代码行数:42,
示例14: ext2fs_mountrootintext2fs_mountroot(void){ // printf("ext2fs_mountroot/n"); extern struct vnode *rootvp; struct m_ext2fs *fs; struct mount *mp; struct ufsmount *ump; int error; if (device_class(root_device) != DV_DISK) return (ENODEV); if ((error = vfs_rootmountalloc(MOUNT_EXT2FS, "root_device", &mp))) { vrele(rootvp); return (error); } if ((error = ext2fs_mountfs(rootvp, mp)) != 0) { vfs_unbusy(mp, false, NULL); vfs_destroy(mp); return (error); } mountlist_append(mp); ump = VFSTOUFS(mp); fs = ump->um_e2fs; memset(fs->e2fs_fsmnt, 0, sizeof(fs->e2fs_fsmnt)); (void) copystr(mp->mnt_stat.f_mntonname, fs->e2fs_fsmnt, sizeof(fs->e2fs_fsmnt) - 1, 0); if (fs->e2fs.e2fs_rev > E2FS_REV0) { memset(fs->e2fs.e2fs_fsmnt, 0, sizeof(fs->e2fs.e2fs_fsmnt)); (void) copystr(mp->mnt_stat.f_mntonname, fs->e2fs.e2fs_fsmnt, sizeof(fs->e2fs.e2fs_fsmnt) - 1, 0); } (void)ext2fs_statvfs(mp, &mp->mnt_stat); vfs_unbusy(mp, false, NULL); setrootfstime((time_t)fs->e2fs.e2fs_wtime); return (0);}
开发者ID:zoulasc,项目名称:ext2fs,代码行数:39,
示例15: ext2fs_mountrootint#define structext2fs_mountroot(struct mount *mp){ struct vnode *rootvp;#undef struct struct m_ext2fs *fs;// struct mount *mp; int error; DEBUG ((EFI_D_INFO, "mountroot 1/n")); if (device_class(root_device) != DV_DISK) return (ENONDEV); DEBUG ((EFI_D_INFO, "mountroot 2/n")); if ((error = vfs_rootmountalloc(MOUNT_EXT2FS, "root_device", &mp))) { vrele(rootvp); return (error); } DEBUG ((EFI_D_INFO, "mountroot 3/n")); if ((error = ext2fs_mountfs(rootvp, mp)) != 0) { vfs_unbusy(mp,false,NULL); vfs_destroy(mp); return (error); } DEBUG ((EFI_D_INFO, "mountroot 4/n")); fs = mp->fs; memset(fs->e2fs_fsmnt, 0, sizeof(fs->e2fs_fsmnt)); (void) copystr(mp->f_mntonname, fs->e2fs_fsmnt, sizeof(fs->e2fs_fsmnt) - 1, 0); if (fs->e2fs.e2fs_rev > E2FS_REV0) { memset(fs->e2fs.e2fs_fsmnt, 0, sizeof(fs->e2fs.e2fs_fsmnt)); (void) copystr(mp->f_mntonname, fs->e2fs.e2fs_fsmnt, sizeof(fs->e2fs.e2fs_fsmnt) - 1, 0); } vfs_unbusy(mp, false, NULL); return (0);
开发者ID:GunioRobot,项目名称:Ext2Pkg,代码行数:39,
示例16: traverseinttraverse(vnode_t **cvpp, int lktype){ vnode_t *cvp; vnode_t *tvp; vfs_t *vfsp; int error; cvp = *cvpp; tvp = NULL; /* * If this vnode is mounted on, then we transparently indirect * to the vnode which is the root of the mounted file system. * Before we do this we must check that an unmount is not in * progress on this vnode. */ for (;;) { /* * Reached the end of the mount chain? */ vfsp = vn_mountedvfs(cvp); if (vfsp == NULL) break; error = vfs_busy(vfsp, 0); /* * tvp is NULL for *cvpp vnode, which we can't unlock. */ if (tvp != NULL) vput(cvp); else vrele(cvp); if (error) return (error); /* * The read lock must be held across the call to VFS_ROOT() to * prevent a concurrent unmount from destroying the vfs. */ error = VFS_ROOT(vfsp, lktype, &tvp); vfs_unbusy(vfsp); if (error != 0) return (error); cvp = tvp; } *cvpp = cvp; return (0);}
开发者ID:151706061,项目名称:osv,代码行数:50,
示例17: ufs_quotactl/* * Do operations associated with quotas */intufs_quotactl(struct mount *mp, prop_dictionary_t dict){ struct lwp *l = curlwp;#if !defined(QUOTA) && !defined(QUOTA2) (void) mp; (void) dict; (void) l; return (EOPNOTSUPP);#else int error; prop_dictionary_t cmddict; prop_array_t commands; prop_object_iterator_t iter; /* Mark the mount busy, as we're passing it to kauth(9). */ error = vfs_busy(mp, NULL); if (error) return (error); error = quota_get_cmds(dict, &commands); if (error) goto out_vfs; iter = prop_array_iterator(commands); if (iter == NULL) { error = ENOMEM; goto out_vfs; } mutex_enter(&mp->mnt_updating); while ((cmddict = prop_object_iterator_next(iter)) != NULL) { if (prop_object_type(cmddict) != PROP_TYPE_DICTIONARY) continue; error = quota_handle_cmd(mp, l, cmddict); if (error) break; } prop_object_iterator_release(iter); mutex_exit(&mp->mnt_updating);out_vfs: vfs_unbusy(mp, false, NULL); return (error);#endif}
开发者ID:AgamAgarwal,项目名称:minix,代码行数:49,
示例18: vfs_getbyidintvfs_getbyid(fsid_t *fsid, ino64_t ino, vnode_t *vpp, vfs_context_t ctx){ mount_t mp; int error; mp = mount_lookupby_volfsid(fsid->val[0], 1); if (mp == NULL) { return EINVAL; } /* Get the target vnode. */ if (ino == 2) { error = VFS_ROOT(mp, vpp, ctx); } else { error = VFS_VGET(mp, ino, vpp, ctx); } vfs_unbusy(mp); return error;}
开发者ID:Algozjb,项目名称:xnu,代码行数:21,
示例19: sync_fsync/* * Do a lazy sync of the filesystem. * * sync_fsync { struct vnode *a_vp, int a_waitfor } */static intsync_fsync(struct vop_fsync_args *ap){ struct vnode *syncvp = ap->a_vp; struct mount *mp = syncvp->v_mount; int asyncflag; /* * We only need to do something if this is a lazy evaluation. */ if ((ap->a_waitfor & MNT_LAZY) == 0) return (0); /* * Move ourselves to the back of the sync list. */ vn_syncer_add(syncvp, syncdelay); /* * Walk the list of vnodes pushing all that are dirty and * not already on the sync list, and freeing vnodes which have * no refs and whos VM objects are empty. vfs_msync() handles * the VM issues and must be called whether the mount is readonly * or not. */ if (vfs_busy(mp, LK_NOWAIT) != 0) return (0); if (mp->mnt_flag & MNT_RDONLY) { vfs_msync(mp, MNT_NOWAIT); } else { asyncflag = mp->mnt_flag & MNT_ASYNC; mp->mnt_flag &= ~MNT_ASYNC; /* ZZZ hack */ vfs_msync(mp, MNT_NOWAIT); VFS_SYNC(mp, MNT_NOWAIT | MNT_LAZY); if (asyncflag) mp->mnt_flag |= MNT_ASYNC; } vfs_unbusy(mp); return (0);}
开发者ID:Gwenio,项目名称:DragonFlyBSD,代码行数:45,
示例20: nlookup_mp/* * Resolve a mount point's glue ncp. This ncp connects creates the illusion * of continuity in the namecache tree by connecting the ncp related to the * vnode under the mount to the ncp related to the mount's root vnode. * * If no error occured a locked, ref'd ncp is stored in *ncpp. */intnlookup_mp(struct mount *mp, struct nchandle *nch){ struct vnode *vp; int error; error = 0; cache_get(&mp->mnt_ncmountpt, nch); if (nch->ncp->nc_flag & NCF_UNRESOLVED) { while (vfs_busy(mp, 0)) ; error = VFS_ROOT(mp, &vp); vfs_unbusy(mp); if (error) { cache_put(nch); } else { cache_setvp(nch, vp); vput(vp); } } return(error);}
开发者ID:kusumi,项目名称:DragonFlyBSD,代码行数:29,
注:本文中的vfs_unbusy函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 C++ vfs_unlink函数代码示例 C++ vfs_sync函数代码示例 |