diff options
author | Mel Gorman <mgorman@suse.de> | 2013-07-03 18:04:45 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-07-03 19:07:40 -0400 |
commit | 26c0c5bf38159673f0ae28c38fc9f90dbeb4d4aa (patch) | |
tree | 1764ae4f720dd9b279a24700a18c1ac7ff9dae1f /Documentation/filesystems/vfs.txt | |
parent | 55878e88c59221c3187e1c24ec3b15eb79c374c0 (diff) |
documentation: update address_space_operations
The documentation for address_space_operations is partially out of date.
Signed-off-by: Mel Gorman <mgorman@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'Documentation/filesystems/vfs.txt')
-rw-r--r-- | Documentation/filesystems/vfs.txt | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/Documentation/filesystems/vfs.txt b/Documentation/filesystems/vfs.txt index 1f0ba30ae47e..fc5d2a1d26c0 100644 --- a/Documentation/filesystems/vfs.txt +++ b/Documentation/filesystems/vfs.txt | |||
@@ -559,7 +559,6 @@ your filesystem. The following members are defined: | |||
559 | struct address_space_operations { | 559 | struct address_space_operations { |
560 | int (*writepage)(struct page *page, struct writeback_control *wbc); | 560 | int (*writepage)(struct page *page, struct writeback_control *wbc); |
561 | int (*readpage)(struct file *, struct page *); | 561 | int (*readpage)(struct file *, struct page *); |
562 | int (*sync_page)(struct page *); | ||
563 | int (*writepages)(struct address_space *, struct writeback_control *); | 562 | int (*writepages)(struct address_space *, struct writeback_control *); |
564 | int (*set_page_dirty)(struct page *page); | 563 | int (*set_page_dirty)(struct page *page); |
565 | int (*readpages)(struct file *filp, struct address_space *mapping, | 564 | int (*readpages)(struct file *filp, struct address_space *mapping, |
@@ -581,6 +580,8 @@ struct address_space_operations { | |||
581 | /* migrate the contents of a page to the specified target */ | 580 | /* migrate the contents of a page to the specified target */ |
582 | int (*migratepage) (struct page *, struct page *); | 581 | int (*migratepage) (struct page *, struct page *); |
583 | int (*launder_page) (struct page *); | 582 | int (*launder_page) (struct page *); |
583 | int (*is_partially_uptodate) (struct page *, read_descriptor_t *, | ||
584 | unsigned long); | ||
584 | int (*error_remove_page) (struct mapping *mapping, struct page *page); | 585 | int (*error_remove_page) (struct mapping *mapping, struct page *page); |
585 | int (*swap_activate)(struct file *); | 586 | int (*swap_activate)(struct file *); |
586 | int (*swap_deactivate)(struct file *); | 587 | int (*swap_deactivate)(struct file *); |
@@ -612,13 +613,6 @@ struct address_space_operations { | |||
612 | In this case, the page will be relocated, relocked and if | 613 | In this case, the page will be relocated, relocked and if |
613 | that all succeeds, ->readpage will be called again. | 614 | that all succeeds, ->readpage will be called again. |
614 | 615 | ||
615 | sync_page: called by the VM to notify the backing store to perform all | ||
616 | queued I/O operations for a page. I/O operations for other pages | ||
617 | associated with this address_space object may also be performed. | ||
618 | |||
619 | This function is optional and is called only for pages with | ||
620 | PG_Writeback set while waiting for the writeback to complete. | ||
621 | |||
622 | writepages: called by the VM to write out pages associated with the | 616 | writepages: called by the VM to write out pages associated with the |
623 | address_space object. If wbc->sync_mode is WBC_SYNC_ALL, then | 617 | address_space object. If wbc->sync_mode is WBC_SYNC_ALL, then |
624 | the writeback_control will specify a range of pages that must be | 618 | the writeback_control will specify a range of pages that must be |
@@ -747,6 +741,11 @@ struct address_space_operations { | |||
747 | prevent redirtying the page, it is kept locked during the whole | 741 | prevent redirtying the page, it is kept locked during the whole |
748 | operation. | 742 | operation. |
749 | 743 | ||
744 | is_partially_uptodate: Called by the VM when reading a file through the | ||
745 | pagecache when the underlying blocksize != pagesize. If the required | ||
746 | block is up to date then the read can complete without needing the IO | ||
747 | to bring the whole page up to date. | ||
748 | |||
750 | error_remove_page: normally set to generic_error_remove_page if truncation | 749 | error_remove_page: normally set to generic_error_remove_page if truncation |
751 | is ok for this address space. Used for memory failure handling. | 750 | is ok for this address space. Used for memory failure handling. |
752 | Setting this implies you deal with pages going away under you, | 751 | Setting this implies you deal with pages going away under you, |