Commit 173b6a77 authored by Evgeny Sinelnikov's avatar Evgeny Sinelnikov

Update sources 2.6.30 from 2.6.30.4

Free nativeFileSystem field before allocating a new one commit 6b5600f321f51cd409d05f475128d40fc7241a2d Fix regression with O_EXCL creates and optimize away lookup commit 9d33821d65cdad2af0461f3a6268125cc8a33052
parent ddb696cc
......@@ -2751,6 +2751,7 @@ CIFSTCon(unsigned int xid, struct cifsSesInfo *ses,
strncpy(tcon->treeName, tree, MAX_TREE_SIZE);
/* mostly informational -- no need to fail on error here */
kfree(tcon->nativeFileSystem);
tcon->nativeFileSystem = cifs_strndup_from_ucs(bcc_ptr,
bytes_left, is_unicode,
nls_codepage);
......
......@@ -642,6 +642,15 @@ cifs_lookup(struct inode *parent_dir_inode, struct dentry *direntry,
}
}
/*
* O_EXCL: optimize away the lookup, but don't hash the dentry. Let
* the VFS handle the create.
*/
if (nd->flags & LOOKUP_EXCL) {
d_instantiate(direntry, NULL);
return 0;
}
/* can not grab the rename sem here since it would
deadlock in the cases (beginning of sys_rename itself)
in which we already have the sb rename sem */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment