[PATCH] NFS: fix minor bug in new NFS symlink code
The original code confused a zero return code from pagevec_add() as success. Test plan: None. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
parent
cd9ae2b6a7
commit
39cf8a1374
1 changed files with 2 additions and 2 deletions
|
@ -1519,8 +1519,8 @@ static int nfs_symlink(struct inode *dir, struct dentry *dentry, const char *sym
|
||||||
pagevec_init(&lru_pvec, 0);
|
pagevec_init(&lru_pvec, 0);
|
||||||
if (!add_to_page_cache(page, dentry->d_inode->i_mapping, 0,
|
if (!add_to_page_cache(page, dentry->d_inode->i_mapping, 0,
|
||||||
GFP_KERNEL)) {
|
GFP_KERNEL)) {
|
||||||
if (!pagevec_add(&lru_pvec, page))
|
pagevec_add(&lru_pvec, page);
|
||||||
__pagevec_lru_add(&lru_pvec);
|
pagevec_lru_add(&lru_pvec);
|
||||||
SetPageUptodate(page);
|
SetPageUptodate(page);
|
||||||
unlock_page(page);
|
unlock_page(page);
|
||||||
} else
|
} else
|
||||||
|
|
Loading…
Reference in a new issue