Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 257337
b: refs/heads/master
c: dd7dd55
h: refs/heads/master
i:
  257335: 99f6bb4
v: v3
  • Loading branch information
Al Viro committed Jul 20, 2011
1 parent bd334a1 commit 803f700
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: bf6c7f6c7bd0ea779757d35b5fdc9f9157f056b3
refs/heads/master: dd7dd556e45133ef13f2c4bddc0e0b1ac23bc0e4
4 changes: 2 additions & 2 deletions trunk/fs/9p/vfs_inode.c
Original file line number Diff line number Diff line change
Expand Up @@ -633,7 +633,7 @@ v9fs_vfs_create(struct inode *dir, struct dentry *dentry, int mode,
fid = NULL;
v9ses = v9fs_inode2v9ses(dir);
perm = unixmode2p9mode(v9ses, mode);
if (nd && nd->flags & LOOKUP_OPEN)
if (nd)
flags = nd->intent.open.flags;
else
flags = O_RDWR;
Expand All @@ -649,7 +649,7 @@ v9fs_vfs_create(struct inode *dir, struct dentry *dentry, int mode,

v9fs_invalidate_inode_attr(dir);
/* if we are opening a file, assign the open fid to the file */
if (nd && nd->flags & LOOKUP_OPEN) {
if (nd) {
v9inode = V9FS_I(dentry->d_inode);
mutex_lock(&v9inode->v_mutex);
if (v9ses->cache && !v9inode->writeback_fid &&
Expand Down
2 changes: 1 addition & 1 deletion trunk/fs/9p/vfs_inode_dotl.c
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ v9fs_vfs_create_dotl(struct inode *dir, struct dentry *dentry, int omode,
struct posix_acl *pacl = NULL, *dacl = NULL;

v9ses = v9fs_inode2v9ses(dir);
if (nd && nd->flags & LOOKUP_OPEN)
if (nd)
flags = nd->intent.open.flags;
else {
/*
Expand Down
6 changes: 3 additions & 3 deletions trunk/fs/cifs/dir.c
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ cifs_create(struct inode *inode, struct dentry *direntry, int mode,
if (oplockEnabled)
oplock = REQ_OPLOCK;

if (nd && (nd->flags & LOOKUP_OPEN))
if (nd)
oflags = nd->intent.open.file->f_flags;
else
oflags = O_RDONLY | O_CREAT;
Expand Down Expand Up @@ -214,7 +214,7 @@ cifs_create(struct inode *inode, struct dentry *direntry, int mode,
which should be rare for path not covered on files) */
}

if (nd && (nd->flags & LOOKUP_OPEN)) {
if (nd) {
/* if the file is going to stay open, then we
need to set the desired access properly */
desiredAccess = 0;
Expand Down Expand Up @@ -328,7 +328,7 @@ cifs_create(struct inode *inode, struct dentry *direntry, int mode,
else
cFYI(1, "Create worked, get_inode_info failed rc = %d", rc);

if (newinode && nd && (nd->flags & LOOKUP_OPEN)) {
if (newinode && nd) {
struct cifsFileInfo *pfile_info;
struct file *filp;

Expand Down
2 changes: 1 addition & 1 deletion trunk/fs/fuse/dir.c
Original file line number Diff line number Diff line change
Expand Up @@ -576,7 +576,7 @@ static int fuse_mknod(struct inode *dir, struct dentry *entry, int mode,
static int fuse_create(struct inode *dir, struct dentry *entry, int mode,
struct nameidata *nd)
{
if (nd && (nd->flags & LOOKUP_OPEN)) {
if (nd) {
int err = fuse_create_open(dir, entry, mode, nd);
if (err != -ENOSYS)
return err;
Expand Down
6 changes: 3 additions & 3 deletions trunk/fs/nfs/dir.c
Original file line number Diff line number Diff line change
Expand Up @@ -1585,7 +1585,7 @@ static int nfs_open_create(struct inode *dir, struct dentry *dentry, int mode,
attr.ia_mode = mode;
attr.ia_valid = ATTR_MODE;

if (nd && (nd->flags & LOOKUP_OPEN) != 0)
if (nd)
open_flags = nd->intent.open.flags;

ctx = create_nfs_open_context(dentry, open_flags);
Expand All @@ -1596,7 +1596,7 @@ static int nfs_open_create(struct inode *dir, struct dentry *dentry, int mode,
error = NFS_PROTO(dir)->create(dir, dentry, &attr, open_flags, ctx);
if (error != 0)
goto out_put_ctx;
if (nd && (nd->flags & LOOKUP_OPEN) != 0) {
if (nd) {
error = nfs_intent_set_file(nd, ctx);
if (error < 0)
goto out_err;
Expand Down Expand Up @@ -1675,7 +1675,7 @@ static int nfs_create(struct inode *dir, struct dentry *dentry, int mode,
attr.ia_mode = mode;
attr.ia_valid = ATTR_MODE;

if (nd && (nd->flags & LOOKUP_OPEN) != 0)
if (nd)
open_flags = nd->intent.open.flags;

error = NFS_PROTO(dir)->create(dir, dentry, &attr, open_flags, NULL);
Expand Down

0 comments on commit 803f700

Please sign in to comment.