···371371 on newly created files, directories, and devices (create, 372372 mkdir, mknod) which will result in the server setting the373373 uid and gid to the default (usually the server uid of the374374- usern who mounted the share). Letting the server (rather than374374+ user who mounted the share). Letting the server (rather than375375 the client) set the uid and gid is the default. This376376 parameter has no effect if the CIFS Unix Extensions are not377377 negotiated.···384384 client (e.g. when the application is doing large sequential385385 reads bigger than page size without rereading the same data) 386386 this can provide better performance than the default387387- behavior which caches reads (reaadahead) and writes 387387+ behavior which caches reads (readahead) and writes 388388 (writebehind) through the local Linux client pagecache 389389 if oplock (caching token) is granted and held. Note that390390 direct allows write operations larger than page size
+1-1
fs/cifs/cifsproto.h
···228228 const struct nls_table *nls_codepage, 229229 int remap_special_chars);230230#endif /* CONFIG_CIFS_EXPERIMENTAL */231231-extern int cifs_convertUCSpath(char *target, const __u16 *source, int maxlen,231231+extern int cifs_convertUCSpath(char *target, const __le16 *source, int maxlen,232232 const struct nls_table * codepage);233233extern int cifsConvertToUCS(__le16 * target, const char *source, int maxlen,234234 const struct nls_table * cp, int mapChars);
···392392 rc = 0;393393 d_add(direntry, NULL);394394 } else {395395- cERROR(1,("Error 0x%x or on cifs_get_inode_info in lookup",rc));395395+ cERROR(1,("Error 0x%x on cifs_get_inode_info in lookup of %s",396396+ rc,full_path));396397 /* BB special case check for Access Denied - watch security 397398 exposure of returning dir info implicitly via different rc 398399 if file exists or not but no access BB */
+15-9
fs/cifs/inode.c
···422422 cifs_sb->mnt_cifs_flags & CIFS_MOUNT_MAP_SPECIAL_CHR);423423424424 if (!rc) {425425- direntry->d_inode->i_nlink--;425425+ if(direntry->d_inode)426426+ direntry->d_inode->i_nlink--;426427 } else if (rc == -ENOENT) {427428 d_drop(direntry);428429 } else if (rc == -ETXTBSY) {···441440 cifs_sb->mnt_cifs_flags & 442441 CIFS_MOUNT_MAP_SPECIAL_CHR);443442 CIFSSMBClose(xid, pTcon, netfid);444444- direntry->d_inode->i_nlink--;443443+ if(direntry->d_inode)444444+ direntry->d_inode->i_nlink--;445445 }446446 } else if (rc == -EACCES) {447447 /* try only if r/o attribute set in local lookup data? */···496494 cifs_sb->mnt_cifs_flags & 497495 CIFS_MOUNT_MAP_SPECIAL_CHR);498496 if (!rc) {499499- direntry->d_inode->i_nlink--;497497+ if(direntry->d_inode)498498+ direntry->d_inode->i_nlink--;500499 } else if (rc == -ETXTBSY) {501500 int oplock = FALSE;502501 __u16 netfid;···517514 cifs_sb->mnt_cifs_flags &518515 CIFS_MOUNT_MAP_SPECIAL_CHR);519516 CIFSSMBClose(xid, pTcon, netfid);520520- direntry->d_inode->i_nlink--;517517+ if(direntry->d_inode)518518+ direntry->d_inode->i_nlink--;521519 }522520 /* BB if rc = -ETXTBUSY goto the rename logic BB */523521 }524522 }525523 }526526- cifsInode = CIFS_I(direntry->d_inode);527527- cifsInode->time = 0; /* will force revalidate to get info when528528- needed */529529- direntry->d_inode->i_ctime = inode->i_ctime = inode->i_mtime =530530- current_fs_time(inode->i_sb);524524+ if(direntry->d_inode) {525525+ cifsInode = CIFS_I(direntry->d_inode);526526+ cifsInode->time = 0; /* will force revalidate to get info527527+ when needed */528528+ direntry->d_inode->i_ctime = current_fs_time(inode->i_sb);529529+ }530530+ inode->i_ctime = inode->i_mtime = current_fs_time(inode->i_sb);531531 cifsInode = CIFS_I(inode);532532 cifsInode->time = 0; /* force revalidate of dir as well */533533
+1
fs/cifs/misc.c
···571571 break;572572 case UNI_LESSTHAN:573573 target[j] = '<';574574+ break;574575 default: 575576 len = cp->uni2char(src_char, &target[j], 576577 NLS_MAX_CHARSET_SIZE);