diff options
Diffstat (limited to 'fs/namei.c')
-rw-r--r-- | fs/namei.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/fs/namei.c b/fs/namei.c index 880052cadbcd..94b2f60aec22 100644 --- a/fs/namei.c +++ b/fs/namei.c | |||
@@ -2671,19 +2671,9 @@ static char *page_getlink(struct dentry * dentry, struct page **ppage) | |||
2671 | struct address_space *mapping = dentry->d_inode->i_mapping; | 2671 | struct address_space *mapping = dentry->d_inode->i_mapping; |
2672 | page = read_mapping_page(mapping, 0, NULL); | 2672 | page = read_mapping_page(mapping, 0, NULL); |
2673 | if (IS_ERR(page)) | 2673 | if (IS_ERR(page)) |
2674 | goto sync_fail; | 2674 | return (char*)page; |
2675 | wait_on_page_locked(page); | ||
2676 | if (!PageUptodate(page)) | ||
2677 | goto async_fail; | ||
2678 | *ppage = page; | 2675 | *ppage = page; |
2679 | return kmap(page); | 2676 | return kmap(page); |
2680 | |||
2681 | async_fail: | ||
2682 | page_cache_release(page); | ||
2683 | return ERR_PTR(-EIO); | ||
2684 | |||
2685 | sync_fail: | ||
2686 | return (char*)page; | ||
2687 | } | 2677 | } |
2688 | 2678 | ||
2689 | int page_readlink(struct dentry *dentry, char __user *buffer, int buflen) | 2679 | int page_readlink(struct dentry *dentry, char __user *buffer, int buflen) |