linux-mips.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Hongchen Zhang <zhanghongchen@loongson.cn>
To: Thomas Bogendoerfer <tsbogend@alpha.franken.de>,
	"Matthew Wilcox (Oracle)" <willy@infradead.org>,
	Zhaolong Zhang <zhangzl2013@126.com>
Cc: linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org,
	Hongchen Zhang <zhanghongchen@loongson.cn>
Subject: [PATCH] MIPS: fix pmd_mkinvalid
Date: Tue, 31 May 2022 12:36:09 +0800	[thread overview]
Message-ID: <1653971769-14152-1-git-send-email-zhanghongchen@loongson.cn> (raw)

pmd_mkinvalid should not clear dirty flag,otherwise the pmd
dirty flag,it's ok to just clear _PAGE_VALID.

Signed-off-by: Hongchen Zhang <zhanghongchen@loongson.cn>
---
 arch/mips/include/asm/pgtable.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/mips/include/asm/pgtable.h b/arch/mips/include/asm/pgtable.h
index 374c632..d30a186 100644
--- a/arch/mips/include/asm/pgtable.h
+++ b/arch/mips/include/asm/pgtable.h
@@ -698,7 +698,7 @@ static inline pmd_t pmd_modify(pmd_t pmd, pgprot_t newprot)
 
 static inline pmd_t pmd_mkinvalid(pmd_t pmd)
 {
-	pmd_val(pmd) &= ~(_PAGE_PRESENT | _PAGE_VALID | _PAGE_DIRTY);
+	pmd_val(pmd) &= ~_PAGE_VALID;
 
 	return pmd;
 }
-- 
1.8.3.1


             reply	other threads:[~2022-05-31  4:36 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-31  4:36 Hongchen Zhang [this message]
2022-05-31 15:40 ` [PATCH] MIPS: fix pmd_mkinvalid Jiaxun Yang
2022-06-01  0:55   ` Hongchen Zhang
  -- strict thread matches above, loose matches on Subject: below --
2022-07-06  9:07 Hongchen Zhang
2022-07-06 19:23 ` kernel test robot
2022-07-07  8:11 Hongchen Zhang
2022-07-07  9:22 ` Thomas Bogendoerfer
2022-07-07 11:12   ` Hongchen Zhang
2022-07-12 10:01     ` Hongchen Zhang
2022-07-12 11:19       ` Thomas Bogendoerfer
2022-07-12 12:08         ` Hongchen Zhang

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=1653971769-14152-1-git-send-email-zhanghongchen@loongson.cn \
    --to=zhanghongchen@loongson.cn \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mips@vger.kernel.org \
    --cc=tsbogend@alpha.franken.de \
    --cc=willy@infradead.org \
    --cc=zhangzl2013@126.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;
as well as URLs for NNTP newsgroup(s).