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]
Message-ID: <1421022401.19708.40.camel@decadent.org.uk>
Date:	Mon, 12 Jan 2015 00:26:41 +0000
From:	Ben Hutchings <ben@...adent.org.uk>
To:	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Zefan Li <lizefan@...wei.com>, Jiri Slaby <jslaby@...e.cz>
Cc:	linux-kernel@...r.kernel.org, stable@...r.kernel.org,
	kernel-team@...ts.ubuntu.com,
	Steve Capper <steve.capper@...aro.org>,
	Russell King <rmk+kernel@....linux.org.uk>,
	Hou Pengyang <houpengyang@...wei.com>,
	Luis Henriques <luis.henriques@...onical.com>
Subject: Re: [PATCH 3.16.y-ckt 072/168] ARM: 8109/1: mm: Modify pte_write
 and pmd_write logic for LPAE

On Mon, 2014-12-15 at 14:25 +0000, Luis Henriques wrote:
> 3.16.7-ckt3 -stable review patch.  If anyone has any objections, please let me know.
> 
> ------------------
> 
> From: Steven Capper <steve.capper@...aro.org>
> 
> commit ded9477984690d026e46dd75e8157392cea3f13f upstream.
> 
> For LPAE, we have the following means for encoding writable or dirty
> ptes:
>                               L_PTE_DIRTY       L_PTE_RDONLY
>     !pte_dirty && !pte_write        0               1
>     !pte_dirty && pte_write         0               1
>     pte_dirty && !pte_write         1               1
>     pte_dirty && pte_write          1               0
> 
> So we can't distinguish between writeable clean ptes and read only
> ptes. This can cause problems with ptes being incorrectly flagged as
> read only when they are writeable but not dirty.
> 
> This patch renumbers L_PTE_RDONLY from AP[2] to a software bit #58,
> and adds additional logic to set AP[2] whenever the pte is read only
> or not dirty. That way we can distinguish between clean writeable ptes
> and read only ptes.
> 
> HugeTLB pages will use this new logic automatically.
> 
> We need to add some logic to Transparent HugePages to ensure that they
> correctly interpret the revised pgprot permissions (L_PTE_RDONLY has
> moved and no longer matches PMD_SECT_AP2). In the process of revising
> THP, the names of the PMD software bits have been prefixed with L_ to
> make them easier to distinguish from their hardware bit counterparts.
> 
> Signed-off-by: Steve Capper <steve.capper@...aro.org>
> Reviewed-by: Will Deacon <will.deacon@....com>
> Signed-off-by: Russell King <rmk+kernel@....linux.org.uk>
> Cc: Hou Pengyang <houpengyang@...wei.com>
> Signed-off-by: Luis Henriques <luis.henriques@...onical.com>
[...]

This one also looks suitable for 3.4 onwards, except that THP was not
supported before 3.11.

Ben.

-- 
Ben Hutchings
The world is coming to an end.	Please log off.

Download attachment "signature.asc" of type "application/pgp-signature" (812 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ