linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: 江志国 <justinjiang@vivo.com>
To: Matthew Wilcox <willy@infradead.org>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	"linux-mm@kvack.org" <linux-mm@kvack.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	opensource.kernel <opensource.kernel@vivo.com>
Subject: 答复: [PATCH] mm: vmscan: the dirty folio unmap redundantly
Date: Thu, 19 Oct 2023 01:27:02 +0000	[thread overview]
Message-ID: <SEZPR06MB6871E64291D68878E4FD6CF3C7D4A@SEZPR06MB6871.apcprd06.prod.outlook.com> (raw)
In-Reply-To: <ZS/nszOJM0Qzspip@casper.infradead.org>

Hi Matthew Wilcox:

>On Wed, Oct 18, 2023 at 09:30:03AM +0800, Zhiguo Jiang wrote:
>> If the dirty folio is not reclaimed in the shrink process, it do not 
>> need to unmap, which can save shrinking time during traversaling the 
>> dirty folio.
>
>Don't we have to unmap it first in order to make sure that all the dirty bits from the PTEs have been transferred to the folio dirty bit?

Yes, if the PTE has the dirty bit, try_to_unmap will transfer it to the folio dirty bit. But the another condition is that the folio dirty bit has been already saved before try_to_unmap. For this situation and the PGDAT_DIRTY flag is not set, the dirty folio can skip unmap to save the shrink time.

The patch submitted previously did not consider the dirty bit trasfferred by unmap, so the original part can be reserved. Please help to continue the review.


Thanks


-----邮件原件-----
发件人: Matthew Wilcox <willy@infradead.org> 
发送时间: 2023年10月18日 22:12
收件人: 江志国 <justinjiang@vivo.com>
抄送: Andrew Morton <akpm@linux-foundation.org>; linux-mm@kvack.org; linux-kernel@vger.kernel.org; opensource.kernel <opensource.kernel@vivo.com>
主题: Re: [PATCH] mm: vmscan: the dirty folio unmap redundantly

[Some people who received this message don't often get email from willy@infradead.org. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]

On Wed, Oct 18, 2023 at 09:30:03AM +0800, Zhiguo Jiang wrote:
> If the dirty folio is not reclaimed in the shrink process, it do not 
> need to unmap, which can save shrinking time during traversaling the 
> dirty folio.

Don't we have to unmap it first in order to make sure that all the dirty bits from the PTEs have been transferred to the folio dirty bit?


  reply	other threads:[~2023-10-19  1:27 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-18  1:30 Zhiguo Jiang
2023-10-18 14:12 ` Matthew Wilcox
2023-10-19  1:27   ` 江志国 [this message]
2023-10-19 13:03 ` David Hildenbrand
2023-10-19 13:23   ` zhiguojiang

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=SEZPR06MB6871E64291D68878E4FD6CF3C7D4A@SEZPR06MB6871.apcprd06.prod.outlook.com \
    --to=justinjiang@vivo.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=opensource.kernel@vivo.com \
    --cc=willy@infradead.org \
    /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