linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Can we remove the checking of CONFIG_ARCH_HAS_PTE_SPECIAL in __vm_insert_mixed?
@ 2020-09-28 14:37 Hao Lee
  0 siblings, 0 replies; only message in thread
From: Hao Lee @ 2020-09-28 14:37 UTC (permalink / raw)
  To: npiggin; +Cc: dan.j.wiilliams, linux-mm, linux-kernel

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

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2020-09-28 14:37 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-28 14:37 Can we remove the checking of CONFIG_ARCH_HAS_PTE_SPECIAL in __vm_insert_mixed? Hao Lee

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).