lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 31 May 2022 16:40:08 +0100
From:   Jiaxun Yang <jiaxun.yang@...goat.com>
To:     Hongchen Zhang <zhanghongchen@...ngson.cn>,
        Thomas Bogendoerfer <tsbogend@...ha.franken.de>,
        "Matthew Wilcox (Oracle)" <willy@...radead.org>,
        Zhaolong Zhang <zhangzl2013@....com>
Cc:     linux-mips@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] MIPS: fix pmd_mkinvalid



在 2022/5/31 5:36, Hongchen Zhang 写道:
> pmd_mkinvalid should not clear dirty flag,otherwise the pmd
> dirty flag,it's ok to just clear _PAGE_VALID.
Hi Hongcheng,

Sorry, what is meant by "otherwise the pmd dirty flag"? Could you please
elaborate?
In my humble opinion _PAGE_PRESENT must be cleared in mkinvalid as it
nolonger present here. And thus it lose the dirty status.

Thanks
- Jiaxun

> Signed-off-by: Hongchen Zhang <zhanghongchen@...ngson.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;
>   }

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ