diff options
author | Steve French <sfrench@us.ibm.com> | 2005-09-01 00:50:37 -0400 |
---|---|---|
committer | Steve French <sfrench@us.ibm.com> | 2005-09-01 00:50:37 -0400 |
commit | bfa0d75a1eee59f0577e3c1697ff570b77581a35 (patch) | |
tree | c5399d95379f71903c4f3e82160bd7b4d36bb42d /fs/cifs/inode.c | |
parent | 1c9551878c4629ca78dfe12ed23b9dc8d97770cc (diff) |
[CIFS] Add support for legacy servers part 5
Handle small negotiated read sizes (under 4K) and finish up
read and write support.
Signed-off-by: Steve French <sfrench@us.ibm.com>
Diffstat (limited to 'fs/cifs/inode.c')
-rw-r--r-- | fs/cifs/inode.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/fs/cifs/inode.c b/fs/cifs/inode.c index 0485c6d6ecd5..0fbe02ebc033 100644 --- a/fs/cifs/inode.c +++ b/fs/cifs/inode.c | |||
@@ -169,6 +169,10 @@ int cifs_get_inode_info_unix(struct inode **pinode, | |||
169 | if(cifs_sb->mnt_cifs_flags & CIFS_MOUNT_NO_BRL) | 169 | if(cifs_sb->mnt_cifs_flags & CIFS_MOUNT_NO_BRL) |
170 | inode->i_fop->lock = NULL; | 170 | inode->i_fop->lock = NULL; |
171 | inode->i_data.a_ops = &cifs_addr_ops; | 171 | inode->i_data.a_ops = &cifs_addr_ops; |
172 | /* check if server can support readpages */ | ||
173 | if(pTcon->ses->server->maxBuf < | ||
174 | 4096 + MAX_CIFS_HDR_SIZE) | ||
175 | inode->i_data.a_ops->readpages = NULL; | ||
172 | } else if (S_ISDIR(inode->i_mode)) { | 176 | } else if (S_ISDIR(inode->i_mode)) { |
173 | cFYI(1, (" Directory inode")); | 177 | cFYI(1, (" Directory inode")); |
174 | inode->i_op = &cifs_dir_inode_ops; | 178 | inode->i_op = &cifs_dir_inode_ops; |
@@ -384,6 +388,9 @@ int cifs_get_inode_info(struct inode **pinode, | |||
384 | if(cifs_sb->mnt_cifs_flags & CIFS_MOUNT_NO_BRL) | 388 | if(cifs_sb->mnt_cifs_flags & CIFS_MOUNT_NO_BRL) |
385 | inode->i_fop->lock = NULL; | 389 | inode->i_fop->lock = NULL; |
386 | inode->i_data.a_ops = &cifs_addr_ops; | 390 | inode->i_data.a_ops = &cifs_addr_ops; |
391 | if(pTcon->ses->server->maxBuf < | ||
392 | 4096 + MAX_CIFS_HDR_SIZE) | ||
393 | inode->i_data.a_ops->readpages = NULL; | ||
387 | } else if (S_ISDIR(inode->i_mode)) { | 394 | } else if (S_ISDIR(inode->i_mode)) { |
388 | cFYI(1, (" Directory inode ")); | 395 | cFYI(1, (" Directory inode ")); |
389 | inode->i_op = &cifs_dir_inode_ops; | 396 | inode->i_op = &cifs_dir_inode_ops; |