Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'for-next' of git://git.samba.org/sfrench/cifs-2.6

Pull CIFS fixes from Steve French:
"Misc small cifs fixes"

* 'for-next' of git://git.samba.org/sfrench/cifs-2.6:
cifs: eliminate cifsERROR variable
cifs: don't compare uniqueids in cifs_prime_dcache unless server inode numbers are in use
cifs: fix double-free of "string" in cifs_parse_mount_options

+18 -17
+1 -5
fs/cifs/cifs_debug.h
··· 37 37 #define CIFS_TIMER 0x04 38 38 39 39 extern int cifsFYI; 40 - extern int cifsERROR; 41 40 42 41 /* 43 42 * debug ON ··· 63 64 64 65 /* error event message: e.g., i/o error */ 65 66 #define cifserror(fmt, ...) \ 66 - do { \ 67 - if (cifsERROR) \ 68 - printk(KERN_ERR "CIFS VFS: " fmt "\n", ##__VA_ARGS__); \ 69 - } while (0) 67 + printk(KERN_ERR "CIFS VFS: " fmt "\n", ##__VA_ARGS__); \ 70 68 71 69 #define cERROR(set, fmt, ...) \ 72 70 do { \
-1
fs/cifs/cifsfs.c
··· 54 54 #endif 55 55 56 56 int cifsFYI = 0; 57 - int cifsERROR = 1; 58 57 int traceSMB = 0; 59 58 bool enable_oplocks = true; 60 59 unsigned int linuxExtEnabled = 1;
+2 -7
fs/cifs/connect.c
··· 1624 1624 case Opt_unc: 1625 1625 string = vol->UNC; 1626 1626 vol->UNC = match_strdup(args); 1627 - if (vol->UNC == NULL) { 1628 - kfree(string); 1627 + if (vol->UNC == NULL) 1629 1628 goto out_nomem; 1630 - } 1631 1629 1632 1630 convert_delimiter(vol->UNC, '\\'); 1633 1631 if (vol->UNC[0] != '\\' || vol->UNC[1] != '\\') { 1634 - kfree(string); 1635 1632 printk(KERN_ERR "CIFS: UNC Path does not " 1636 1633 "begin with // or \\\\\n"); 1637 1634 goto cifs_parse_mount_err; ··· 1684 1687 1685 1688 string = vol->prepath; 1686 1689 vol->prepath = match_strdup(args); 1687 - if (vol->prepath == NULL) { 1688 - kfree(string); 1690 + if (vol->prepath == NULL) 1689 1691 goto out_nomem; 1690 - } 1691 1692 /* Compare old prefixpath= option to new one */ 1692 1693 if (!string || strcmp(string, vol->prepath)) 1693 1694 printk(KERN_WARNING "CIFS: the value of the "
+15 -4
fs/cifs/readdir.c
··· 78 78 struct dentry *dentry, *alias; 79 79 struct inode *inode; 80 80 struct super_block *sb = parent->d_inode->i_sb; 81 + struct cifs_sb_info *cifs_sb = CIFS_SB(sb); 81 82 82 83 cFYI(1, "%s: for %s", __func__, name->name); 83 84 ··· 92 91 int err; 93 92 94 93 inode = dentry->d_inode; 95 - /* update inode in place if i_ino didn't change */ 96 - if (inode && CIFS_I(inode)->uniqueid == fattr->cf_uniqueid) { 97 - cifs_fattr_to_inode(inode, fattr); 98 - goto out; 94 + if (inode) { 95 + /* 96 + * If we're generating inode numbers, then we don't 97 + * want to clobber the existing one with the one that 98 + * the readdir code created. 99 + */ 100 + if (!(cifs_sb->mnt_cifs_flags & CIFS_MOUNT_SERVER_INUM)) 101 + fattr->cf_uniqueid = CIFS_I(inode)->uniqueid; 102 + 103 + /* update inode in place if i_ino didn't change */ 104 + if (CIFS_I(inode)->uniqueid == fattr->cf_uniqueid) { 105 + cifs_fattr_to_inode(inode, fattr); 106 + goto out; 107 + } 99 108 } 100 109 err = d_invalidate(dentry); 101 110 dput(dentry);