/illumos-gate/usr/src/contrib/ast/src/cmd/ksh93/edit/ |
H A D | vi.c | 135 #define editb (*vp->ed) 138 #define putchar(c) ed_putchar(vp->ed,c) 217 register Vi_t *vp = ed->e_vi; in ed_viread() local 235 if(!vp) in ed_viread() 237 ed->e_vi = vp = newof(0,Vi_t,1,0); in ed_viread() 238 vp->lastline = (genchar*)malloc(MAXLINE*CHARSIZE); in ed_viread() 239 vp->direction = -1; in ed_viread() 240 vp->ed = ed; in ed_viread() 246 ed_setup(vp->ed,fd, reedit); in ed_viread() 258 ioctl(fd,FIORDCHK,&vp->typeahead); in ed_viread() [all …]
|
/illumos-gate/usr/src/lib/smbclnt/libfksmbfs/common/ |
H A D | fake_vnode.c | 82 #define ISROFILE(vp) \ argument 83 ((vp)->v_type != VCHR && (vp)->v_type != VBLK && \ 84 (vp)->v_type != VFIFO && vn_is_readonly(vp)) 86 #define VOPSTATS_UPDATE(vp, counter) ((void)vp) argument 87 #define VOPSTATS_UPDATE_IO(vp, counter, bytecounter, bytesval) \ argument 88 ((void)vp, (void)bytesval) 89 #define VOPXID_MAP_CR(vp, cr) ((void)vp) argument 317 struct vnode *vp, in vn_rdwr() argument 332 if (rw == UIO_WRITE && ISROFILE(vp)) in vn_rdwr() 338 VOPXID_MAP_CR(vp, cr); in vn_rdwr() [all …]
|
/illumos-gate/usr/src/uts/common/fs/lofs/ |
H A D | lofs_vnops.c | 52 vnode_t *vp = *vpp; in lo_open() local 59 vp, vp->v_count, realvp(vp), realvp(vp)->v_count); in lo_open() 62 oldvp = vp; in lo_open() 63 vp = rvp = realvp(vp); in lo_open() 68 VN_HOLD(vp); in lo_open() 71 if (!error && rvp != vp) { in lo_open() 104 vnode_t *vp, in lo_close() argument 112 lo_dprint(4, "lo_close vp %p realvp %p\n", vp, realvp(vp)); in lo_close() 114 vp = realvp(vp); in lo_close() 115 return (VOP_CLOSE(vp, flag, count, offset, cr, ct)); in lo_close() [all …]
|
/illumos-gate/usr/src/uts/common/fs/ |
H A D | vnode.c | 77 #define ISROFILE(vp) \ argument 78 ((vp)->v_type != VCHR && (vp)->v_type != VBLK && \ 79 (vp)->v_type != VFIFO && vn_is_readonly(vp)) 168 #define VOPSTATS_UPDATE(vp, counter) { \ argument 169 vfs_t *vfsp = (vp)->v_vfsp; \ 171 (vfsp->vfs_flag & VFS_STATS) && (vp)->v_type != VBAD) { \ 176 __dtrace_probe___fsinfo_##counter(vp, 0, stataddr); \ 184 #define VOPSTATS_UPDATE_IO(vp, counter, bytecounter, bytesval) { \ argument 185 vfs_t *vfsp = (vp)->v_vfsp; \ 187 (vfsp->vfs_flag & VFS_STATS) && (vp)->v_type != VBAD) { \ [all …]
|
H A D | lookup.c | 148 vnode_t *vp; /* current directory vp */ in lookuppnatcred() local 162 vp = rootvp; in lookuppnatcred() 164 vp = (startvp == NULL) ? PTOU(p)->u_cdir : startvp; in lookuppnatcred() 166 VN_HOLD(vp); in lookuppnatcred() 180 compvpp, rootvp, vp, cr)); in lookuppnatcred() 219 vnode_t *vp, /* directory to start search at */ in lookuppnvp() argument 253 audit_anchorpath(pnp, vp == rootvp); in lookuppnvp() 265 startvp = vp; in lookuppnvp() 272 if (vp->v_type != VDIR) { in lookuppnvp() 277 if (rpnp && VN_CMP(vp, rootvp)) in lookuppnvp() [all …]
|
/illumos-gate/usr/src/cmd/csh/ |
H A D | sh.exp.c | 100 exp(tchar ***vp) in exp() argument 106 return (exp0(vp, 0)); in exp() 110 exp0(tchar ***vp, bool ignore) in exp0() argument 112 int p1 = exp1(vp, ignore); in exp0() 118 etraci("exp0 p1", p1, vp); in exp0() 120 if (**vp && eq(**vp, S_BARBAR /* "||" */)) { in exp0() 123 (*vp)++; in exp0() 124 p2 = exp0(vp, (ignore&IGNORE) || p1); in exp0() 126 etraci("exp0 p2", p2, vp); in exp0() 134 exp1(tchar ***vp, bool ignore) in exp1() argument [all …]
|
H A D | sh.set.c | 40 tchar *vp, op; in doset() local 62 for (vp = p; alnum(*p); p++) in doset() 64 if (vp == p || !letter(*vp)) in doset() 66 if ((p - vp) > MAX_VAR_LEN) in doset() 99 set1(vp, vecp, &shvhed); in doset() 104 asx(vp, subscr, retp); in doset() 108 set(vp, savestr(p)); in doset() 109 if (eq(vp, S_path /* "path" */)) { in doset() 112 } else if (eq(vp, S_histchars /* "histchars" */)) { in doset() 116 } else if (eq(vp, S_user /* "user" */)) in doset() [all …]
|
/illumos-gate/usr/src/cmd/awk/ |
H A D | tran.c | 106 setfree(Cell *vp) in setfree() argument 108 if (&vp->sval == FS || &vp->sval == RS || in setfree() 109 &vp->sval == OFS || &vp->sval == ORS || in setfree() 110 &vp->sval == OFMT || &vp->sval == CONVFMT || in setfree() 111 &vp->sval == FILENAME || &vp->sval == SUBSEP) in setfree() 112 vp->tval |= DONTFREE; in setfree() 114 vp->tval &= ~DONTFREE; in setfree() 362 setfval(Cell *vp, Awkfloat f) /* set float val of a Cell */ in setfval() argument 367 if ((vp->tval & (NUM | STR)) == 0) in setfval() 368 funnyvar(vp, "assign to"); in setfval() [all …]
|
/illumos-gate/usr/src/cmd/oawk/ |
H A D | tran.c | 191 setfval(CELL *vp, awkfloat f) in setfval() argument 193 dprintf("setfval: %o %g\n", vp, f, NULL); in setfval() 195 if (vp->tval & ARR) in setfval() 196 error(FATAL, "illegal reference to array %s", vp->nval); in setfval() 197 if ((vp->tval & (NUM | STR)) == 0) in setfval() 198 error(FATAL, "funny variable %o: %ws %ws %g %o", vp, vp->nval, in setfval() 199 vp->sval, vp->fval, vp->tval); in setfval() 201 if (vp == recloc) in setfval() 203 vp->tval &= ~STR; /* mark string invalid */ in setfval() 204 vp->tval |= NUM; /* mark number ok */ in setfval() [all …]
|
/illumos-gate/usr/src/contrib/ast/src/cmd/ksh93/sh/ |
H A D | env.c | 90 register Evar_t *vp; in env_get() local 103 for(vp=(Evar_t*)dtfirst(ep->dt);vp; vp=(Evar_t*)dtnext(ep->dt,vp)) in env_get() 105 vp->index = (n<<ENV_BITS) | (vp->index&((1<<ENV_BITS)-1)); in env_get() 106 ep->env[n++] = vp->un.ptr; in env_get() 122 Evar_t *vp = (Evar_t*)dtmatch(ep->dt,(void*)str); in env_add() local 123 if(vp && strcmp(str,vp->un.ptr)==0) in env_add() 127 if(vp) in env_add() 129 if(vp->index&ENV_PMALLOC) in env_add() 130 free((void*)vp->un.ptr); in env_add() 131 vp->un.ptr = (char*)str; in env_add() [all …]
|
H A D | streval.c | 92 #define getchr(vp) (*(vp)->nextchr++) argument 93 #define peekchr(vp) (*(vp)->nextchr) argument 94 #define ungetchr(vp) ((vp)->nextchr--) argument 113 #define ERROR(vp,msg) return(seterror((vp),msg)) argument 118 static int _seterror(struct vars *vp,const char *msg) in _seterror() argument 120 if(!vp->errmsg.value) in _seterror() 121 vp->errmsg.value = (char*)msg; in _seterror() 122 vp->errchr = vp->nextchr; in _seterror() 123 vp->nextchr = ""; in _seterror() 510 static int gettok(register struct vars *vp) in gettok() argument [all …]
|
/illumos-gate/usr/src/contrib/ast/src/lib/libast/astsa/ |
H A D | vmalloc.c | 36 Vmalloc_t* vp; in _vm_open() local 38 if (vp = newof(0, Vmalloc_t, 1, 0)) in _vm_open() 40 vp->current = &vp->base; in _vm_open() 41 vp->data = vp->current->data; in _vm_open() 42 vp->size = sizeof(vp->current->data); in _vm_open() 44 return vp; in _vm_open() 48 _vm_close(register Vmalloc_t* vp) in _vm_close() argument 53 if (!vp) in _vm_close() 55 np = vp->base.next; in _vm_close() 61 free(vp); in _vm_close() [all …]
|
/illumos-gate/usr/src/uts/common/sys/ |
H A D | vfstab.h | 43 #define vfsnull(vp) ((vp)->vfs_special = (vp)->vfs_fsckdev = \ argument 44 (vp)->vfs_mountp = (vp)->vfs_fstype = \ 45 (vp)->vfs_fsckpass = (vp)->vfs_automnt = \ 46 (vp)->vfs_mntopts = NULL) 48 #define putvfsent(fd, vp)\ argument 50 (vp)->vfs_special ? (vp)->vfs_special : "-", \ 51 (vp)->vfs_fsckdev ? (vp)->vfs_fsckdev : "-", \ 52 (vp)->vfs_mountp ? (vp)->vfs_mountp : "-", \ 53 (vp)->vfs_fstype ? (vp)->vfs_fstype : "-", \ 54 (vp)->vfs_fsckpass ? (vp)->vfs_fsckpass : "-", \ [all …]
|
H A D | vnode.h | 319 #define IS_DEVVP(vp) \ argument 320 ((vp)->v_type == VCHR || (vp)->v_type == VBLK || (vp)->v_type == VFIFO) 342 #define IS_SWAPVP(vp) (((vp)->v_flag & (VISSWAP | VSWAPLIKE)) != 0) argument 380 #define IS_PXFSVP(vp) ((vp)->v_flag & VPXFS) argument 384 #define IS_XATTRDIR(vp) ((vp)->v_flag & V_XATTRDIR) argument 395 #define IS_VMODSORT(vp) \ argument 396 (pvn_vmodsort_supported != 0 && ((vp)->v_flag & VMODSORT) != 0) 405 #define IS_SWAPFSVP(vp) (((vp)->v_flag & VISSWAPFS) != 0) argument 786 #define MANDLOCK(vp, mode) ((vp)->v_type == VREG && MANDMODE(mode)) argument 1045 extern int fop_remove(vnode_t *vp, char *, cred_t *, caller_context_t *, [all …]
|
/illumos-gate/usr/src/lib/libc/port/gen/ |
H A D | nftw.c | 171 int depth, struct Save *last, struct Var *vp) in walk() argument 190 if ((vp->curflags & FTW_CHDIR) && last) in walk() 193 comp = vp->tmppath; in walk() 195 if (vp->savedstatf == NULL) in walk() 196 vp->savedstatf = vp->statf; in walk() 198 if ((vp->walklevel++ == 0) && (vp->curflags & FTW_HOPTION)) { in walk() 199 if (((vp->curflags & FTW_CHDIR) == 0) && (depth >= 2)) { in walk() 200 vp->statf = nocdstat; in walk() 202 vp->statf = cdstat; in walk() 205 vp->statf = vp->savedstatf; in walk() [all …]
|
/illumos-gate/usr/src/uts/common/fs/nfs/ |
H A D | nfs_acl_srv.c | 83 vnode_t *vp; in acl2_getacl() local 86 vp = nfs_fhtovp(&args->fh, exi); in acl2_getacl() 87 if (vp == NULL) { in acl2_getacl() 96 error = VOP_GETSECATTR(vp, &resp->resok.acl, 0, cr, NULL); in acl2_getacl() 114 error = fs_fab_acl(vp, &resp->resok.acl, 0, cr, NULL); in acl2_getacl() 118 VN_RELE(vp); in acl2_getacl() 124 error = rfs4_delegated_getattr(vp, &va, 0, cr); in acl2_getacl() 126 VN_RELE(vp); in acl2_getacl() 197 vnode_t *vp; in acl2_setacl() local 200 vp = nfs_fhtovp(&args->fh, exi); in acl2_setacl() [all …]
|
H A D | nfs4_rnode.c | 173 nfs4_dross_pages(vnode_t *vp) in nfs4_dross_pages() argument 178 vphm = page_vnode_mutex(vp); in nfs4_dross_pages() 180 if ((pp = vp->v_pages) != NULL) { in nfs4_dross_pages() 187 } while ((pp = pp->p_vpnext) != vp->v_pages); in nfs4_dross_pages() 200 vnode_t *vp; in r4flushpages() local 217 vp = RTOV4(rp); in r4flushpages() 218 if (nfs4_has_pages(vp)) { in r4flushpages() 219 ASSERT(vp->v_type != VCHR); in r4flushpages() 221 error = VOP_PUTPAGE(vp, (u_offset_t)0, 0, 0, cr, NULL); in r4flushpages() 229 nfs4_invalidate_pages(vp, (u_offset_t)0, cr); in r4flushpages() [all …]
|
/illumos-gate/usr/src/lib/smbsrv/libfksmbsrv/common/ |
H A D | vncache.c | 55 #define VTOF(vp) ((struct fakefs_node *)(vp)->v_data) argument 116 vn_recycle(vnode_t *vp) in vn_recycle() argument 118 fakefs_node_t *fnp = VTOF(vp); in vn_recycle() 122 vp->v_rdcnt = 0; in vn_recycle() 123 vp->v_wrcnt = 0; in vn_recycle() 125 if (vp->v_path) { in vn_recycle() 126 strfree(vp->v_path); in vn_recycle() 127 vp->v_path = NULL; in vn_recycle() 143 vn_reinit(vnode_t *vp) in vn_reinit() argument 145 vp->v_count = 1; in vn_reinit() [all …]
|
H A D | fake_vop.c | 94 vnode_t *vp, in fop_close() argument 108 if ((vp->v_type == VREG) && (count == 1)) { in fop_close() 110 ASSERT(vp->v_rdcnt > 0); in fop_close() 111 atomic_add_32(&(vp->v_rdcnt), -1); in fop_close() 114 ASSERT(vp->v_wrcnt > 0); in fop_close() 115 atomic_add_32(&(vp->v_wrcnt), -1); in fop_close() 124 vnode_t *vp, in fop_read() argument 135 int fd = vncache_getfd(vp); in fop_read() 220 vnode_t *vp, in fop_write() argument 229 int fd = vncache_getfd(vp); in fop_write() [all …]
|
/illumos-gate/usr/src/uts/common/fs/doorfs/ |
H A D | door_vnops.c | 44 static int door_close(struct vnode *vp, int flag, int count, 46 static int door_getattr(struct vnode *vp, struct vattr *vap, 48 static void door_inactive(struct vnode *vp, struct cred *cr, 50 static int door_access(struct vnode *vp, int mode, int flags, 52 static int door_realvp(vnode_t *vp, vnode_t **vpp, caller_context_t *ct); 104 door_close(struct vnode *vp, int flag, int count, offset_t offset, in door_close() argument 107 door_node_t *dp = VTOD(vp); in door_close() 126 if (count == 2 && vp->v_count == 1 && in door_close() 143 door_getattr(struct vnode *vp, struct vattr *vap, int flags, struct cred *cr, in door_getattr() argument 150 vap->va_type = vp->v_type; /* vnode type (for create) */ in door_getattr() [all …]
|
/illumos-gate/usr/src/cmd/mailx/ |
H A D | vars.c | 59 register struct var *vp; in assign() local 68 vp = lookup(name); in assign() 69 if (vp == NOVAR) { in assign() 70 if ((vp = (struct var *) in assign() 71 calloc(sizeof (*vp), 1)) == NULL) in assign() 73 vp->v_name = vcopy(name); in assign() 74 vp->v_link = variables[h]; in assign() 75 variables[h] = vp; in assign() 77 vfree(vp->v_value); in assign() 78 vp->v_value = vcopy(value); in assign() [all …]
|
/illumos-gate/usr/src/uts/common/fs/pcfs/ |
H A D | pc_node.c | 93 struct vnode *vp; in pc_getnode() local 144 vp = vn_alloc(KM_SLEEP); in pc_getnode() 145 pcp->pc_vn = vp; in pc_getnode() 154 vn_setops(vp, pcfs_dvnodeops); in pc_getnode() 155 vp->v_type = VDIR; in pc_getnode() 157 vp->v_flag = VROOT; in pc_getnode() 185 vn_setops(vp, pcfs_fvnodeops); in pc_getnode() 186 vp->v_type = VREG; in pc_getnode() 187 vp->v_flag = VNOSWAP; in pc_getnode() 193 vp->v_data = (caddr_t)pcp; in pc_getnode() [all …]
|
/illumos-gate/usr/src/uts/common/fs/smbclnt/smbfs/ |
H A D | smbfs_subr2.c | 167 vnode_t *vp; in sn_inactive() local 191 vp = SMBTOV(np); in sn_inactive() 192 if (vn_has_cached_data(vp)) { in sn_inactive() 193 ASSERT3P(vp,==,NULL); in sn_inactive() 235 vnode_t *vp; in smbfs_node_findcreate() local 299 vp = SMBTOV(np); in smbfs_node_findcreate() 300 smbfs_attrcache_fa(vp, fap); in smbfs_node_findcreate() 329 vnode_t *vp; in make_smbnode() local 356 vp = SMBTOV(np); in make_smbnode() 362 mutex_enter(&vp->v_lock); in make_smbnode() [all …]
|
/illumos-gate/usr/src/uts/common/fs/sockfs/ |
H A D | sockcommon_vnops.c | 122 struct vnode *vp = *vpp; in socket_vop_open() local 123 struct sonode *so = VTOSO(vp); in socket_vop_open() 131 ASSERT(vp->v_type == VSOCK); in socket_vop_open() 138 socket_vop_close(struct vnode *vp, int flag, int count, offset_t offset, in socket_vop_close() argument 144 so = VTOSO(vp); in socket_vop_close() 145 ASSERT(vp->v_type == VSOCK); in socket_vop_close() 147 cleanlocks(vp, ttoproc(curthread)->p_pid, 0); in socket_vop_close() 148 cleanshares(vp, ttoproc(curthread)->p_pid); in socket_vop_close() 150 if (vp->v_stream) in socket_vop_close() 151 strclean(vp); in socket_vop_close() [all …]
|
/illumos-gate/usr/src/uts/common/fs/dcfs/ |
H A D | dc_vnops.c | 112 #define DCHASH(vp) (((uintptr_t)(vp) >> DCSHFT) & (DCTABLESIZE - 1)) argument 114 #define DCHASH(vp) (((uintptr_t)(vp) >> DCSHFT) % DTABLESIZEC) argument 254 dc_close(struct vnode *vp, int flag, int count, offset_t off, in dc_close() argument 257 (void) cleanlocks(vp, ttoproc(curthread)->p_pid, 0); in dc_close() 258 cleanshares(vp, ttoproc(curthread)->p_pid); in dc_close() 264 dc_read(struct vnode *vp, struct uio *uiop, int ioflag, struct cred *cr, in dc_read() argument 267 struct dcnode *dp = VTODC(vp); in dc_read() 290 base = segmap_getmapflt(segkmap, vp, uiop->uio_loffset, n, 1, in dc_read() 309 dc_getattr(struct vnode *vp, struct vattr *vap, int flags, in dc_getattr() argument 312 struct dcnode *dp = VTODC(vp); in dc_getattr() [all …]
|