[PATCH v2 07/13] mm/gup: Refactor record_subpages() to find 1st small page

Jason Gunthorpe jgg at nvidia.com
Mon Jan 15 10:38:14 PST 2024


On Wed, Jan 03, 2024 at 05:14:17PM +0800, peterx at redhat.com wrote:
> From: Peter Xu <peterx at redhat.com>
> 
> All the fast-gup functions take a tail page to operate, always need to do
> page mask calculations before feeding that into record_subpages().
> 
> Merge that logic into record_subpages(), so that it will do the nth_page()
> calculation.
> 
> Signed-off-by: Peter Xu <peterx at redhat.com>
> ---
>  mm/gup.c | 25 ++++++++++++++-----------
>  1 file changed, 14 insertions(+), 11 deletions(-)

Reviewed-by: Jason Gunthorpe <jgg at nvidia.com>

Jason



More information about the linux-riscv mailing list