summaryrefslogtreecommitdiffstats
path: root/Documentation/filesystems
diff options
context:
space:
mode:
authorKirill A. Shutemov <kirill.shutemov@linux.intel.com>2016-07-26 18:25:20 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2016-07-26 19:19:19 -0400
commitbae473a423f65e480db83c85b5e92254f6dfcb28 (patch)
tree9e09cd8cbcafdcc1a27298700f69f8f86f929392 /Documentation/filesystems
parentdcddffd41d3f1d3bdcc1dce3f1cd142779b6d4c1 (diff)
mm: introduce fault_env
The idea borrowed from Peter's patch from patchset on speculative page faults[1]: Instead of passing around the endless list of function arguments, replace the lot with a single structure so we can change context without endless function signature changes. The changes are mostly mechanical with exception of faultaround code: filemap_map_pages() got reworked a bit. This patch is preparation for the next one. [1] http://lkml.kernel.org/r/20141020222841.302891540@infradead.org Link: http://lkml.kernel.org/r/1466021202-61880-9-git-send-email-kirill.shutemov@linux.intel.com Signed-off-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'Documentation/filesystems')
-rw-r--r--Documentation/filesystems/Locking10
1 files changed, 5 insertions, 5 deletions
diff --git a/Documentation/filesystems/Locking b/Documentation/filesystems/Locking
index dda6e3f8e203..5a7386e38e2d 100644
--- a/Documentation/filesystems/Locking
+++ b/Documentation/filesystems/Locking
@@ -548,13 +548,13 @@ subsequent truncate), and then return with VM_FAULT_LOCKED, and the page
548locked. The VM will unlock the page. 548locked. The VM will unlock the page.
549 549
550 ->map_pages() is called when VM asks to map easy accessible pages. 550 ->map_pages() is called when VM asks to map easy accessible pages.
551Filesystem should find and map pages associated with offsets from "pgoff" 551Filesystem should find and map pages associated with offsets from "start_pgoff"
552till "max_pgoff". ->map_pages() is called with page table locked and must 552till "end_pgoff". ->map_pages() is called with page table locked and must
553not block. If it's not possible to reach a page without blocking, 553not block. If it's not possible to reach a page without blocking,
554filesystem should skip it. Filesystem should use do_set_pte() to setup 554filesystem should skip it. Filesystem should use do_set_pte() to setup
555page table entry. Pointer to entry associated with offset "pgoff" is 555page table entry. Pointer to entry associated with the page is passed in
556passed in "pte" field in vm_fault structure. Pointers to entries for other 556"pte" field in fault_env structure. Pointers to entries for other offsets
557offsets should be calculated relative to "pte". 557should be calculated relative to "pte".
558 558
559 ->page_mkwrite() is called when a previously read-only pte is 559 ->page_mkwrite() is called when a previously read-only pte is
560about to become writeable. The filesystem again must ensure that there are 560about to become writeable. The filesystem again must ensure that there are