Skip to content

Commit

Permalink
mm: remove file argument from swap_readpage()
Browse files Browse the repository at this point in the history
The file argument resulted from address_space's readpage long time ago.

We don't use it any more.  Let's remove unnecessary argement.

Signed-off-by: Minchan Kim <[email protected]>
Acked-by: Hugh Dickins <[email protected]>
Reviewed-by: Rik van Riel <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Minchan Kim authored and torvalds committed Jun 17, 2009
1 parent 8192da6 commit aca8bf3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion include/linux/swap.h
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ extern void swap_unplug_io_fn(struct backing_dev_info *, struct page *);

#ifdef CONFIG_SWAP
/* linux/mm/page_io.c */
extern int swap_readpage(struct file *, struct page *);
extern int swap_readpage(struct page *);
extern int swap_writepage(struct page *page, struct writeback_control *wbc);
extern void end_swap_bio_read(struct bio *bio, int err);

Expand Down
2 changes: 1 addition & 1 deletion mm/page_io.c
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ int swap_writepage(struct page *page, struct writeback_control *wbc)
return ret;
}

int swap_readpage(struct file *file, struct page *page)
int swap_readpage(struct page *page)
{
struct bio *bio;
int ret = 0;
Expand Down
2 changes: 1 addition & 1 deletion mm/swap_state.c
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,7 @@ struct page *read_swap_cache_async(swp_entry_t entry, gfp_t gfp_mask,
* Initiate read into locked page and return.
*/
lru_cache_add_anon(new_page);
swap_readpage(NULL, new_page);
swap_readpage(new_page);
return new_page;
}
ClearPageSwapBacked(new_page);
Expand Down

0 comments on commit aca8bf3

Please sign in to comment.