Lines Matching defs:fmode
200 int fmode, error;
203 fmode = *flagp;
204 if ((fmode & (O_CREAT | O_EXCL | O_DIRECTORY)) == (O_CREAT |
207 else if ((fmode & (O_CREAT | O_DIRECTORY)) == O_CREAT) {
214 if ((fmode & O_EXCL) == 0 && (fmode & O_NOFOLLOW) == 0)
228 if (fmode & O_EXCL)
253 fmode &= ~O_TRUNC;
262 if (fmode & O_EXCL) {
270 fmode &= ~O_CREAT;
275 ((fmode & O_NOFOLLOW) ? NOFOLLOW : FOLLOW) | LOCKLEAF;
276 if (!(fmode & FWRITE))
286 error = vn_open_vnode(vp, fmode, cred, td, fp);
289 *flagp = fmode;
294 *flagp = fmode;
304 vn_open_vnode(struct vnode *vp, int fmode, struct ucred *cred,
315 if (vp->v_type != VDIR && fmode & O_DIRECTORY)
318 if (fmode & (FWRITE | O_TRUNC)) {
323 if (fmode & FREAD)
325 if (fmode & FEXEC)
327 if ((fmode & O_APPEND) && (fmode & FWRITE))
330 if (fmode & O_CREAT)
332 if (fmode & O_VERIFY)
340 if ((fmode & O_CREAT) == 0) {
354 if ((error = VOP_OPEN(vp, fmode, cred, td, fp)) != 0)
357 while ((fmode & (O_EXLOCK | O_SHLOCK)) != 0) {
368 if (fmode & O_EXLOCK)
373 if ((fmode & FNONBLOCK) == 0)
405 } else if ((fmode & FWRITE) != 0) {