Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
mm: do not increment pgfault stats when page fault handler retries
If the page fault handler requests a retry, we will count the fault multiple times. This is a relatively harmless problem as the retry paths are not often requested, and the only user-visible problem is that the fault counter will be slightly higher than it should be. Nevertheless, userspace only took one fault, and should not see the fact that the kernel had to retry the fault multiple times. Move page fault accounting into mm_account_fault() and skip incomplete faults which will be accounted upon completion. Link: https://lkml.kernel.org/r/[email protected] Fixes: d065bd8 ("mm: retry page fault when blocking on disk transfer") Signed-off-by: Suren Baghdasaryan <[email protected]> Reviewed-by: Matthew Wilcox (Oracle) <[email protected]> Acked-by: Peter Xu <[email protected]> Cc: Davidlohr Bueso <[email protected]> Cc: Jan Kara <[email protected]> Cc: Johannes Weiner <[email protected]> Cc: Josef Bacik <[email protected]> Cc: Laurent Dufour <[email protected]> Cc: Liam R. Howlett <[email protected]> Cc: Lorenzo Stoakes <[email protected]> Cc: Michal Hocko <[email protected]> Cc: Michel Lespinasse <[email protected]> Cc: Minchan Kim <[email protected]> Cc: Punit Agrawal <[email protected]> Cc: Vlastimil Babka <[email protected]> Signed-off-by: Andrew Morton <[email protected]>
- Loading branch information