Skip to content

Commit

Permalink
[GFS2] Use zero_user_page() in stuffed_readpage()
Browse files Browse the repository at this point in the history
As suggested by Robert P. J. Day <rpjday@mindspring.com>

Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
Cc: Robert P. J. Day <rpjday@mindspring.com>
  • Loading branch information
Steven Whitehouse committed Jul 9, 2007
1 parent c420121 commit 2840501
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions fs/gfs2/ops_address.c
Original file line number Diff line number Diff line change
Expand Up @@ -208,11 +208,7 @@ static int stuffed_readpage(struct gfs2_inode *ip, struct page *page)
* so we need to supply one here. It doesn't happen often.
*/
if (unlikely(page->index)) {
kaddr = kmap_atomic(page, KM_USER0);
memset(kaddr, 0, PAGE_CACHE_SIZE);
kunmap_atomic(kaddr, KM_USER0);
flush_dcache_page(page);
SetPageUptodate(page);
zero_user_page(page, 0, PAGE_CACHE_SIZE, KM_USER0);
return 0;
}

Expand Down

0 comments on commit 2840501

Please sign in to comment.