summaryrefslogtreecommitdiffstats
path: root/fs/cifs/inode.c
diff options
context:
space:
mode:
authorPavel Shilovsky <pshilovsky@samba.org>2012-09-18 16:20:26 -0700
committerSteve French <smfrench@gmail.com>2012-09-24 21:46:26 -0500
commit4b4de76e35518fc0c636f628abca8c1b19ad6689 (patch)
tree18b27673849d55235c216f0cbb811e1aa4b87ae9 /fs/cifs/inode.c
parentcbe6f439f5762c7fb4d2dd9293f5fdbfc4cd68f8 (diff)
downloadlinux-4b4de76e35518fc0c636f628abca8c1b19ad6689.tar.bz2
CIFS: Replace netfid with cifs_fid struct in cifsFileInfo
This is help us to extend the code for future protocols that can use another fid mechanism (as SMB2 that has it divided into two parts: persistent and violatile). Also rename variables and refactor the code around the changes. Reviewed-by: Jeff Layton <jlayton@samba.org> Signed-off-by: Pavel Shilovsky <pshilovsky@samba.org> Signed-off-by: Steve French <smfrench@gmail.com>
Diffstat (limited to 'fs/cifs/inode.c')
-rw-r--r--fs/cifs/inode.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/fs/cifs/inode.c b/fs/cifs/inode.c
index bb39ea475a20..ea7428a82a31 100644
--- a/fs/cifs/inode.c
+++ b/fs/cifs/inode.c
@@ -294,7 +294,7 @@ int cifs_get_file_info_unix(struct file *filp)
struct cifs_tcon *tcon = tlink_tcon(cfile->tlink);
xid = get_xid();
- rc = CIFSSMBUnixQFileInfo(xid, tcon, cfile->netfid, &find_data);
+ rc = CIFSSMBUnixQFileInfo(xid, tcon, cfile->fid.netfid, &find_data);
if (!rc) {
cifs_unix_basic_to_fattr(&fattr, &find_data, cifs_sb);
} else if (rc == -EREMOTE) {
@@ -562,7 +562,7 @@ int cifs_get_file_info(struct file *filp)
struct cifs_tcon *tcon = tlink_tcon(cfile->tlink);
xid = get_xid();
- rc = CIFSSMBQFileInfo(xid, tcon, cfile->netfid, &find_data);
+ rc = CIFSSMBQFileInfo(xid, tcon, cfile->fid.netfid, &find_data);
switch (rc) {
case 0:
cifs_all_info_to_fattr(&fattr, &find_data, cifs_sb, false);
@@ -930,7 +930,7 @@ cifs_set_file_info(struct inode *inode, struct iattr *attrs, unsigned int xid,
*/
open_file = find_writable_file(cifsInode, true);
if (open_file) {
- netfid = open_file->netfid;
+ netfid = open_file->fid.netfid;
netpid = open_file->pid;
pTcon = tlink_tcon(open_file->tlink);
goto set_via_filehandle;
@@ -1887,7 +1887,7 @@ cifs_set_file_size(struct inode *inode, struct iattr *attrs,
*/
open_file = find_writable_file(cifsInode, true);
if (open_file) {
- __u16 nfid = open_file->netfid;
+ __u16 nfid = open_file->fid.netfid;
__u32 npid = open_file->pid;
pTcon = tlink_tcon(open_file->tlink);
rc = CIFSSMBSetFileSize(xid, pTcon, attrs->ia_size, nfid,
@@ -2061,7 +2061,7 @@ cifs_setattr_unix(struct dentry *direntry, struct iattr *attrs)
args->device = 0;
open_file = find_writable_file(cifsInode, true);
if (open_file) {
- u16 nfid = open_file->netfid;
+ u16 nfid = open_file->fid.netfid;
u32 npid = open_file->pid;
pTcon = tlink_tcon(open_file->tlink);
rc = CIFSSMBUnixSetFileInfo(xid, pTcon, args, nfid, npid);