linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: David Hildenbrand <dhildenb@redhat.com>
To: Pedro Demarchi Gomes <pedrodemargomes@gmail.com>,
	Andrew Morton <akpm@linux-foundation.org>
Cc: Xu Xin <xu.xin16@zte.com.cn>,
	Chengming Zhou <chengming.zhou@linux.dev>,
	linux-mm@kvack.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 2/3] ksm: perform a range-walk in break_ksm
Date: Wed, 5 Nov 2025 18:52:09 +0100	[thread overview]
Message-ID: <63653e44-3a30-46e6-8a3e-f62d73f3f6a8@redhat.com> (raw)
In-Reply-To: <20251105172756.167009-3-pedrodemargomes@gmail.com>

> +			folio = vm_normal_folio(walk->vma, addr, pte);
> +		} else if (!pte_none(pte)) {
> +			swp_entry_t entry = pte_to_swp_entry(pte);
> +
> +			/*
> +			 * As KSM pages remain KSM pages until freed, no need to wait
> +			 * here for migration to end.
> +			 */
> +			if (is_migration_entry(entry))
> +				folio = pfn_swap_entry_folio(entry);
> +		}
> +		/* return 1 if the page is an normal ksm page or KSM-placed zero page */
> +		found = (folio && folio_test_ksm(folio)) || (pte_present(pte)
> +			&& is_ksm_zero_pte(pte));

Same NIT as for previous patch.

Apart from that LGTM, thanks!

Acked-by: David Hildenbrand (Red Hat) <david@kernel.org>

-- 
Cheers

David



  reply	other threads:[~2025-11-05 17:52 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-05 17:27 [PATCH v3 0/3] ksm: perform a range-walk to jump over holes " Pedro Demarchi Gomes
2025-11-05 17:27 ` [PATCH v3 1/3] Revert "mm/ksm: convert break_ksm() from walk_page_range_vma() to folio_walk" Pedro Demarchi Gomes
2025-11-05 17:51   ` David Hildenbrand
2025-11-05 17:27 ` [PATCH v3 2/3] ksm: perform a range-walk in break_ksm Pedro Demarchi Gomes
2025-11-05 17:52   ` David Hildenbrand [this message]
2025-11-05 17:27 ` [PATCH v3 3/3] ksm: replace function unmerge_ksm_pages with break_ksm Pedro Demarchi Gomes
2025-11-05 17:52   ` David Hildenbrand

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=63653e44-3a30-46e6-8a3e-f62d73f3f6a8@redhat.com \
    --to=dhildenb@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=chengming.zhou@linux.dev \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=pedrodemargomes@gmail.com \
    --cc=xu.xin16@zte.com.cn \
    /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