All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mike Kravetz <mike.kravetz@oracle.com>
To: Peng Zhang <zhangpeng362@huawei.com>
Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org,
	willy@infradead.org, akpm@linux-foundation.org,
	vishal.moola@gmail.com, sidhartha.kumar@oracle.com,
	wangkefeng.wang@huawei.com, sunnanyong@huawei.com
Subject: Re: [PATCH v2 2/3] userfaultfd: convert __mcopy_atomic_hugetlb() to use a folio
Date: Wed, 15 Mar 2023 12:53:28 -0700	[thread overview]
Message-ID: <20230315195328.GA3092@monkey> (raw)
In-Reply-To: <20230314131350.924377-3-zhangpeng362@huawei.com>

On 03/14/23 13:13, Peng Zhang wrote:
> From: ZhangPeng <zhangpeng362@huawei.com>
> 
> Change copy_huge_page_from_user() to copy_folio_from_user().

Any reason why you did not change copy_user_huge_page to folios as
well?  All callers are passing &folio->page.

Just my opinion, but it might be better/easier to review if the copy
routines were done in a separate patch.  There is a little more than
folio conversion happening there.

-- 
Mike Kravetz

> Convert hugetlb_mcopy_atomic_pte() and __mcopy_atomic_hugetlb() to use a
> folio.
> 
> Signed-off-by: ZhangPeng <zhangpeng362@huawei.com>
> ---
>  include/linux/hugetlb.h |  4 ++--
>  include/linux/mm.h      |  3 +--
>  mm/hugetlb.c            | 25 ++++++++++++-------------
>  mm/memory.c             | 27 ++++++++++++---------------
>  mm/userfaultfd.c        | 20 +++++++++-----------
>  5 files changed, 36 insertions(+), 43 deletions(-)


  reply	other threads:[~2023-03-15 19:54 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-14 13:13 [PATCH v2 0/3] userfaultfd: convert userfaultfd functions to use folios Peng Zhang
2023-03-14 13:13 ` [PATCH v2 1/3] userfaultfd: convert mcopy_atomic_pte() to use a folio Peng Zhang
2023-03-14 13:13 ` [PATCH v2 2/3] userfaultfd: convert __mcopy_atomic_hugetlb() " Peng Zhang
2023-03-15 19:53   ` Mike Kravetz [this message]
2023-03-16  3:53     ` zhangpeng (AS)
2023-03-14 13:13 ` [PATCH v2 3/3] userfaultfd: convert __mcopy_atomic() " Peng Zhang
2023-03-14 13:23 ` [PATCH v2 0/3] userfaultfd: convert userfaultfd functions to use folios Matthew Wilcox
2023-03-23  3:44   ` zhangpeng (AS)

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230315195328.GA3092@monkey \
    --to=mike.kravetz@oracle.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=sidhartha.kumar@oracle.com \
    --cc=sunnanyong@huawei.com \
    --cc=vishal.moola@gmail.com \
    --cc=wangkefeng.wang@huawei.com \
    --cc=willy@infradead.org \
    --cc=zhangpeng362@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.