linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Hao Lee <haolee.swjtu@gmail.com>
To: npiggin@gmail.com
Cc: dan.j.wiilliams@intel.com, linux-mm@kvack.org,
	 linux-kernel@vger.kernel.org
Subject: Can we remove the checking of CONFIG_ARCH_HAS_PTE_SPECIAL in __vm_insert_mixed?
Date: Mon, 28 Sep 2020 22:37:17 +0800	[thread overview]
Message-ID: <CA+PpKPkAmnVhkwgZU84udJ0BEi+Pd4UOBaJJDVmvd+P=Depbng@mail.gmail.com> (raw)

Sorry, the previous email is corrupted. This is a resending.

In the current code, if the architecture supports PTE_SPECIAL,
__vm_insert_mixed() becomes a simple encapsulation of insert_pfn()
because it always calls insert_pfn() and never calls insert_page(). This
behavior is inconsistent with the function's name. As described in commit
423bad600443 ("mm: add vm_insert_mixed"), this function is designed to
supports _both_ raw pfns and pfns with struct page, but in architecture
with PTE_SPECIAL, it treats the latter as the former. So, I think we'd
better remove the checking of CONFIG_ARCH_HAS_PTE_SPECIAL to make the
behavior consistent for all architectures. If my understanding is right,
I can submit a patch to fix this. Thanks.

Regards,
Hao Lee


                 reply	other threads:[~2020-09-28 14:37 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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='CA+PpKPkAmnVhkwgZU84udJ0BEi+Pd4UOBaJJDVmvd+P=Depbng@mail.gmail.com' \
    --to=haolee.swjtu@gmail.com \
    --cc=dan.j.wiilliams@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=npiggin@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox